首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 网站开发 > ASP >

结果和预想的不同

2012-10-10 
结果跟预想的不同INPUT title写入文件 onclick%writefile addurl,map.html,gb2312 % typebutt

结果跟预想的不同
<INPUT title=写入文件 onclick="<% writefile addurl,"map.html","gb2312" %>" type=button value=写入文件>

本意是点这个按钮的时候才运行 writefile 这个函数,但现在页面一打开就运行了,怎么修改?

[解决办法]

HTML code
<INPUT title="写入文件" onclick="fwrite()" type="button" value="写入文件" /><script type="text/javascript">function fwrite(){    if(confirm("确定要写入文件?")){        location.href="?action=write";    }}</script><%if request.querystring("action")="write" then    call writefile(addurl,"map.html","gb2312")end if%> 

热点排行