Web Program/Asp Lecture27 파일 읽고 쓰기 Set fso = CreateObject("Scripting.FileSystemObject") Set objFile = fso.OpenTextFile(strFileName, 1) s = objFile.ReadAll set fso = nothing Set objFs = Server.CreateObject("Scripting.FileSystemObject") Set f = objFs.CreateTextFile(strFilename, true) f.Write strKeyData set objFs = nothing 2008. 9. 8. Base64 encode/decode OPTION EXPLICIT const BASE_64_MAP_INIT = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/" dim nl " zero based arrays dim Base64EncMap(63) dim Base64DecMap(127) " must be called before using anything else PUBLIC SUB initCodecs() " init vars nl = "" & chr(13) & chr(10) " setup base 64 dim max, idx max = len(BASE_64_MAP_INIT) for idx = 0 to max - 1 " one based string Base64EncMap(.. 2008. 9. 8. xml 데이타 recordset으로 받기 ' Constants file included above.' Declare our variables... always good practice.Dim rstXML ' ADO recordset' Create our recordset objectSet rstXML = Server.CreateObject("ADODB.Recordset")' Open the previously saved results of the query.rstXML.Open Server.MapPath("db_xml.xml") ' Now we've got a recordset containing the data we' previously saved to the XML file... to illustrate' I'll print out the.. 2008. 9. 8. 이미지 binary로 보여주기 ' image.asp 화일내용 이 코드를 이미지 asp로 작업을 하시구요. 이미지테그에 이런식으로 작업하시면 이미지가 그대로 뿌려집니다. 2008. 9. 8. 이전 1 2 3 4 5 6 7 다음