上一页 返回教程首页 下一页
名称
友情链接浏览器
实例
教程
第一步:拷贝下面的代码到你的html文件的<head>和</head>之间;
<SCRIPT language=JavaScript> <!-- function go_to_station(){ if (document.stationform.stationselect.options[0].selected){ window.location.href = "http://202.98.107.86/xutao/";} else if (document.stationform.stationselect.options[1].selected) { window.location.href = "http://member.netease.com/~xwtao/";} else if (document.stationform.stationselect.options[2].selected) { window.location.href = "http://chaofan.bentium.net/";} else if (document.stationform.stationselect.options[3].selected) { window.location.href = "http://laosong.yeah.net/";} else if (document.stationform.stationselect.options[4].selected) { window.location.href = "http://ipismusic.yeah.net/";} else if (document.stationform.stationselect.options[5].selected) { window.location.href = "http://digest.topcool.net";} else if (document.stationform.stationselect.options[6].selected) { window.location.href = "http://msbnet.yeah.net/";} else if (document.stationform.stationselect.options[7].selected) { window.location.href = "http://www.hiddenfbi.com/";} return true; } //This is were you load the Discription and the Author function textValue(){ if (document.stationform.stationselect.options[0].selected){ document.stationform.disc.value = "爱情故事,photoshop" document.stationform.author.value = "【徐涛】";} else if (document.stationform.stationselect.options[1].selected) { document.stationform.disc.value = "每日推荐一张CD,一个好站,一个MP3" document.stationform.author.value = "【天虹】";} else if (document.stationform.stationselect.options[2].selected) { document.stationform.disc.value = "有独有的Java和,VB教程" document.stationform.author.value = "【笨男孩】";} else if (document.stationform.stationselect.options[3].selected) { document.stationform.disc.value = "缘分天空,情感交流的好地方" document.stationform.author.value = "【laosong】";} else if (document.stationform.stationselect.options[4].selected) { document.stationform.disc.value = "现有歌词2681首" document.stationform.author.value = "【ipis】";} else if (document.stationform.stationselect.options[5].selected) { document.stationform.disc.value = "网上原创请您推荐妙文佳作" document.stationform.author.value = "【koki】";} else if (document.stationform.stationselect.options[6].selected) { document.stationform.disc.value = "电脑图形设计,flash在线教材大全" document.stationform.author.value = "【MSB】";} else if (document.stationform.stationselect.options[7].selected) { document.stationform.disc.value = "如果是mm这边进,姐妹们说悄悄话了" document.stationform.author.value = "【hiddenfbi】";} return true; } //--> </SCRIPT>
第二步:拷贝下面的代码到你的html文件的<body>和</body>之间;
<TABLE><FORM name=stationform> <TR> <TD><SELECT class=yk9 multiple name=stationselect onchange=textValue() size=8> <OPTION>徐涛有约</OPTION> <OPTION>听涛阁</OPTION> <OPTION>超凡时速</OPTION> <OPTION>红牌楼</OPTION> <OPTION>蟑螂音乐歌词库</OPTION> <OPTION>网文观止</OPTION> <OPTION>MSB图形世界</OPTION> <OPTION>准我自我</OPTION></SELECT> <TD>站长大名<BR><TEXTAREA class=yk9 cols=40 name=author rows=1></TEXTAREA> <BR>站点主题<BR><TEXTAREA class=yk9 cols=40 name=disc rows=3 wrap=physical></TEXTAREA><p><INPUT class=yk9 name=stationbutton onclick=go_to_station() type="button" value="立刻去看看"></p> </TD> </TR> </FORM> </TABLE>
说明:将第一段代码中的"链接地址"和"站长名称""站点简介"改为你自己的友情连接内容,将第二段代码中的站点名称修改为相对应的站点。