二进制转换为十六进制:怎样把OpenTextFile读出来的字符串再生成ASP代码啊~??

来源:百度文库 编辑:杭州交通信息网 时间:2024/05/05 02:13:38
<html〉〈head〉
〈TITLE〉includedynamic.asp〈/TITLE〉
〈/head〉〈body bgcolor="#FFFFFF"〉
〈%
whichfile="bookscifi.asp"
Call ReadDisplayFile(whichfile)
response.write "〈hr〉"

whichfile="bookhorror.asp"
Call ReadDisplayFile(whichfile)
response.write "〈hr〉"

whichfile="/learn/test/bookmarketing.asp"
Call ReadDisplayFile(whichfile)
response.write "〈hr〉"
%〉

〈/body〉〈/html〉
〈%
SUB ReadDisplayFile(FileToRead)
whichfile=server.mappath(FileToRead)
Set fs = CreateObject("Scripting.FileSystemObject")
Set thisfile = fs.OpenTextFile(whichfile, 1, False)
tempSTR=thisfile.readall
response.write tempSTR
thisfile.Close
set thisfile=nothing
set fs=nothing
END SUB
%〉

例如:bookscifi.asp里面的代码是用来调用的函数

把response.write tempSTR这个读出来的字符串,再生成可执行和可调用变

量的ASP代码来啊`~这就是把这段程序包含在里面,但不是用

<!--#include file="xxxx.asp" -->来进行包含

高手们请帮帮忙!
问题已解决!

唉,对于这个问题的回应实在太慢了~~~

我是一边自己努力,一边等高手帮忙,等了好几天,一点回应都

没有!好在,我还把问题解决了,求人还是不如求自啊~~~唉`!

真厉害!!