如何实现用表单转登到邮箱系统!!!
我在网页上做了一个这样的表单,我想登录到http://mail.zfrz.com的企业邮箱里面,请各位帮帮忙。
<table width="57%" border="0" align="center" cellpadding="0" cellspacing="0">
<form action="http://mail.zfrz.com/default.asp?usernameshow=<%usernameshow=replace(trim(request("usernameshow")),"'","''")%> & pwshow=<%pwshow=replace(trim(request("pwshow")),"'","''")%>" name="fl" onSubmit="return checkdata()">
<INPUT type="hidden" name="username">
<INPUT type="hidden" name="pwhidden">
<INPUT type="hidden" value="3444" name="picnum">
<INPUT type="hidden" name="aveUser">
<INPUT type="hidden" name="SecEx">
<tr>
<td width="34%" height="30"><div align="center">用户名:</div></td>
<td width="66%" height="30"><input name="usernameshow" type="text" id="usernameshow"></td>
</tr>
<tr>
<td height="30"><div align="center">密码:</div></td>
<td height="30"><input name="pwshow" type="text" id="pwshow"></td>
</tr>
<tr>
<td height="25" colspan="2"> <div align="center">
<INPUT type="checkbox" name="showSecEx">
增强安全性
<INPUT type="checkbox" name="showsaveUser">
记住用户名 </div></td>
</tr>
<tr>
<td height="25" colspan="2"> </td>
</tr>
<tr>
<td height="30" colspan="2"><div align="center">
<input type="submit" name="Submit" value="确 定">
</div></td>
</tr>
</form>
</table>
问题点数:100、回复次数:7Top
1 楼hanpoyangtitan(韩波洋)回复于 2006-03-14 10:09:07 得分 20
<form action="http://mail.zfrz.com/default.asp?usernameshow=<%usernameshow=replace(trim(request("usernameshow")),"'","''")%> & pwshow=<%pwshow=replace(trim(request("pwshow")),"'","''")%>" name="fl" onSubmit="return checkdata()">
中<%usernameshow=replace(trim(request("usernameshow")),"'","''")%>不会输出任何东西。
应该是<%=replace(trim(request("usernameshow")),"'","''")%>
或者<%usernameshow=replace(trim(request("usernameshow")),"'","''"):response.write usernameshow%>
其他的没有什么可看的Top
2 楼litiantian124(小小)回复于 2006-03-14 10:12:47 得分 0
我把上面改成
<form action="http://mail.zfrz.com/default.asp?usernameshow=<%=replace(trim(request("usernameshow")),"'","''")%> & pwshow=<%=replace(trim(request("pwshow")),"'","''")%>" name="fl" onSubmit="return checkdata()">
或者这样:
<form action="http://mail.zfrz.com/default.asp?usernameshow=<%=request("usernameshow")%>& pwshow=<%=request("pwshow")%>" name="fl" onSubmit="return checkdata()">
效果都是一样,不能正确登录,也就是不会通过其的验证过程!
Top
3 楼hanpoyangtitan(韩波洋)回复于 2006-03-14 10:42:07 得分 50
我只是说了一下上面代码中的已点小错误,想要登录必须把
<SCRIPT LANGUAGE=javascript>
<!--
if (top.location !== self.location) {
top.location=self.location;
}
function window_onload() {
usernameshow.focus();
}
function gook() {
if (usernameshow.value == "")
{
alert("用户名不可为空");
usernameshow.focus();
return ;
}
if (pwshow.value == "")
{
alert("密码不可为空");
pwshow.focus();
return ;
}
f1.saveUser.value = showsaveUser.checked;
f1.username.value = usernameshow.value;
f1.SecEx.value = showSecEx.checked;
f1.pwhidden.value = encode(pwshow.value, parseInt(f1.picnum.value));
f1.submit();
}
function encode(datastr, bassnum) {
var tempstr;
var tchar;
var newdata = "";
for (var i = 0; i < datastr.length; i++)
{
tchar = 65535 + bassnum - datastr.charCodeAt(i);
tchar = tchar.toString();
while(tchar.length < 5)
{
tchar = "0" + tchar;
}
newdata = newdata + tchar;
}
return newdata;
}
//-->
</SCRIPT>加上,那个页面不是很复杂,为什么你不用他的源代码呢?Top
4 楼litiantian124(小小)回复于 2006-03-14 10:48:36 得分 0
哪个页面不复杂啊!
但我无法得到邮箱系统的会员信息!(也就是邮箱系统的库信息)
Top
5 楼litiantian124(小小)回复于 2006-03-14 10:50:37 得分 0
这段<script>在上面我已经加了:
<script language="JavaScript">
function checkdata()
{
usernameshow=document.fl.usernameshow.value;
pwshow=document.fl.pwshow.value;
if (usernameshow.length==0)
{
alert("用户名不能为空");
document.fl.usernameshow.focus();
return false;
}
if (pwshow.length==0)
{
alert("密码不能为空");
document.fl.pwshow.focus();
return false;
}
document.f1.saveUser.value = document.fl.showsaveUser.checked;
document.f1.username.value = document.fl.usernameshow.value;
document.f1.SecEx.value =document.fl.showSecEx.checked;
document.f1.pwhidden.value = encode(document.fl.pwshow.value, parseInt(document.f1.picnum.value));
document.f1.submit();
}
function encode(datastr, bassnum) {
var tempstr;
var tchar;
var newdata = "";
for (var i = 0; i < datastr.length; i++)
{
tchar = 65535 + bassnum - datastr.charCodeAt(i);
tchar = tchar.toString();
while(tchar.length < 5)
{
tchar = "0" + tchar;
}
newdata = newdata + tchar;
}
return newdata;
}
</script>Top
6 楼hanpoyangtitan(韩波洋)回复于 2006-03-14 11:18:12 得分 20
用xmlhttp得到对方页面的网页源代码进行分析Top
7 楼flyingsnowy((欧杨)不远万里来看楼主的帖,这是一种什么样的精神病?)回复于 2006-03-14 11:44:19 得分 10
报错了吗。顶一下。Top




