最近经常登陆邮箱,虽然浏览器能够记住登陆的用户名和密码,但是每次还要手动打开浏览器,感觉有些许麻烦,所以写了一个自动登录到我的yahoo邮箱的一个简单页面,在这里和大家一同分享一下。
以yahoo邮箱为例:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>我的yahoo邮箱自动登录了</title>
<style type="text/css">
<!--
body {
background-image: url(file:///D|/My%20Documents/My%0Pictures/bz6.jpg);
}
-->
</style> </head>
<body>
<form id="loginform" name="loginform" method="post" action="https://edit.bjs.yahoo.com/config/login">
<div align="center">
<table width="342" height="119" border="1">
<tr>
<td width="87" height="41">用户名:</td>
<td width="239"><input type="text" value="[email protected]" name="login" class="inp" id="emailinput" /></td>
</tr>
<tr>
<td>密码:</td>
<td><label>
<input type="text" value="******" name="passwd" id="passinput"/>
</label></td>
</tr>
<tr>
<td><input name=".intl" value="cn" type="hidden" /></td>
<input value="ym" name=".src" type="hidden" />
<input type="hidden" name=".cnrid" value="ymhp_20000" />
<input type=hidden name=".challenge" value="G0d5u3x80ekFdiR8Y96wOT1A2Csp">
<td><input type=hidden name=.done value="http://mail.cn.yahoo.com/ycn_setcookie_inset.html?.done=http%3A%2F%2Fmail.cn.yahoo.com%2Finset.html%3Frr%3D1357079689" </td>
</tr>
</table>
</div>
</form>
<div align="center">
<script>
loginform.submit();
</script>
</div>
</body>
</html>
其中红色部分自己动手加了一个图片,位于D|/MyDocuments/MyPictures 位置,table内写的是自己的yahoo邮箱的用户名和密码,其中大家要注意控件的名称要和yahoo登录界面的一致,同时form的action位置 为action="https://edit.bjs.yahoo.com/config/login" 也是yahoo登陆后跳转的地址。在做其他邮箱的自动登录时,要求一样。
保存为html页面后,双击便能跳转到自己的收件箱位置。
自己DIY一个简单的邮箱登陆页面
猜你喜欢
转载自wzhiju.iteye.com/blog/777163
今日推荐
周排行