直接保存URL图像或网页到服务器本地的类(11)


<META NAME="Generator" CONTENT="EditPlus">
<META NAME="Author" CONTENT="V37">
<META NAME="Keywords" CONTENT="">
<META NAME="Description" CONTENT="">
<SCRIPT LANGUAGE="JavaScript">
<!--
/*function runCode() 
{
var code=event.srcElement.parentElement.children[0].value;
var newwin=window.open('','',''); 
newwin.opener = null 
newwin.document.write(code);
newwin.document.close();
}
function setsmiley(what) 

document.PostForm.comment.value += " "+what; 
document.PostForm.comment.focus(); 
} */
    function runCode(num) //运行代码HTML
        {
         // var code=event.srcElement.parentElement.children[0].value;
         if(num==1){var code=window.form2.code.innerText;}
         if(num==0){var code=window.form2.content.innerText;}
         var newwin=window.open('','','');
         newwin.opener = null
         newwin.document.write(code);
         newwin.document.close();
        }
//-->
</SCRIPT>
</HEAD>
<BODY>
<%
dim imgUp        '传输对象
dim GetStrUrl    '要获取的图像或网页URL
dim iSaveName    '要保存的名字
dim iSavePath    '要保存的虚拟路径
dim iSaveMode    '保存的模式 1 为图像 0 为任意文件
    iSavePath=trim(request.form("SavePath"))
    iSaveName=trim(request.form("SaveName"))
    GetStrUrl=trim(request.form("GetStrUrl"))
    iSaveMode=trim(request.form("SaveMode"))
if GetStrUrl<>"" then
    CALL saveUpload(GetStrUrl,iSavePath,iSaveName,iSaveMode)
    call tform()
else
    call tform()
end if
%>
</BODY>
</HTML>