www.gusucode.com > 搜一次CMS电影程序 PHP 1.5源码程序 > js/link.php
<?php include("../include/label.php");; $action=SafeRequest("action","get"); if($action=="add"){ $SiteName=SafeRequest("SiteName","post","filter"); $SiteUrl=SafeRequest("SiteUrl","post","filter"); $SiteLogo=SafeRequest("SiteLogo","post","filter"); $Types=SafeRequest("Types","post","filter"); $SiteDescription=SafeRequest("SiteDescription","post","filter"); $sql="insert s_link (S_Name,S_Url,S_Pic,S_IsVerify,S_IsIndex,S_ClassID,S_Input) values ('".$SiteName."','".$SiteUrl."','".$SiteLogo."',1,1,".$Types.",'".$SiteDescription."')"; if($db->query($sql)){ die("<script>alert('申请成功请等待管理员审核!');window.location='link.php'</script>"); } else{ die("<script>alert('未知错误申请失败!');window.location='link.php'</script>"); } } ob_start(); ?> <!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" /> <style type="text/css">body,td,th { font-size: 12px; } body { margin-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; } .mycode{ float:left; } .mycode ul{ width:100%; list-style-type:none; list-style-image: url(../images/no.gif); } .mycode li{ width:150px; float:left; display:block; line-height:20px; list-style:inside; text-decoration:none; text-align:left; } a { font-size: 12px; } a:link { text-decoration: none; color: #09C; } a:visited { text-decoration: none; color: #09C; } a:hover { text-decoration: underline; color: #09C; } a:active { text-decoration: none; color: #09C; } </style> <title>申请友情链接_{syccms:webname}</title> <script language="javascript"> function check(){ var name=document.getElementById("SiteName").value; var url=document.getElementById("SiteUrl").value; if(name==""){ document.getElementById("info").innerHTML=" 请输入网站名称!"; return false; } else if(url==""){ document.getElementById("info").innerHTML=" 请输入网站地址!"; return false; } else{ form1.submit(); } } </script> </head> <body> <div style="height:30px; width:96%; margin:0 auto; background:url(../images/common/alert_title.jpg); line-height:30px; padding-left:30px; color:#FFF;"><strong> 本站友情链接</strong></div> <div style="width:96%; margin:0 auto; margin-bottom:20px; margin-top:10px;padding-bottom:10px; height:100%;"> <div style="height:15px; width:100%; line-height:15px;"><div style="float:left"><img src="../images/common/link_bg.jpg"></div><div style="float:left"> 合作伙伴</div></div> {syccms:link sort=time order=asc classid=3 hide=true} <div style="float:left; margin-left:25px; height:30px;margin-top:10px;"><a href="[link:url]" target="_blank"><img src="[link:pic]" onerror="src='../images/nopic.gif'" width="90" height="33" border="0"></a></div> {/syccms:link} </div> <div style="clear:left;"></div> <div style="height:15px; width:96%; margin:0 auto; line-height:15px;"><div style="float:left"><img src="../images/common/link_bg.jpg"></div><div style="float:left"> 友情链接</div></div> <div style="width:96%; margin:0 auto; margin-bottom:20px; margin-top:10px; height:100%;" class="mycode"> <ul > {syccms:link sort=time order=asc classid=all hide=true} <li><img src="../images/common/links_10.gif"> <a href="[link:url]" target="_blank">[link:name]</a></li> {/syccms:link} </ul> </div> <div style="clear:left"></div> <div style="height:30px; width:96%; margin:0 auto; background:url(../images/common/alert_title.jpg); line-height:30px; padding-left:30px; color:#FFF;"><strong> 申请友情链接</strong></div> <div style="width:96%; margin:0 auto; margin-top:20px;"> <div style="width:50%; float:left; line-height:20px;"> <ul style="list-style:none;"> <li> <strong>申请步骤:</strong> </li> </ul> <ul style="list-style:none;"> <li> <div>1.请先在贵网站做好的文字友情链接:<br /> 链接文字:{syccms:webname} 链接地址:<a href="{syccms:weburl}" target="_blank">{syccms:weburl}</a></div> </li> </ul> <ul style="list-style:none;"> <li>2.做好链接后,请在右侧填写申请信息。</li> </ul> <ul style="list-style:none;"> <li> <div>3.已经开通我站友情链接,符合本站友情链接要求的网站,经管理员审核后,可以显示在此友情链接页面。</div> </li> </ul> </div> <div style="width:5%; float:left;"> <img src="../images/common/links.gif"> </div> <div style="width:44%; float:left;"> <form name="form1" id="form1" action="?action=add" method="post"> <div style="height:28px; line-height:28px; text-align:left;"> <strong>申请信息</strong></div> <div style="width:100%;line-height:30px;"> 网站名称: <input type="text" name="SiteName" id="SiteName" size="35"></div> <div style="width:100%;line-height:30px;"> 网站地址: <input type="text" name="SiteUrl" id="SiteUrl" size="35"></div> <div style="width:100%;line-height:30px;"> 网站LOGO地址:<input type="text" name="SiteLogo" id="SiteLogo" size="35"></div> <div style="width:100%;line-height:30px;"> 网站说明: <input type="text" name="SiteDescription" id="SiteDescription" size="35" maxlength="100"/></div> <div style="width:100%;line-height:30px;"> 友情链接类型:<input type="radio" id="Types" name="Types" class="radio" value="1" checked="checked"/> 文字<input type="radio" id="Types" name="Types" class="radio" value="2"/> 图片<input type="radio" id="Types" name="Types" class="radio" value="3" /> 合作伙伴</div> <div style="width:100%; height:30px; line-height:30px;"> <input type="image" src="../images/common/btn_link.gif" onclick="check();return false;" > <span id="info" style="color:red;"></span></div> </form> </div> </div> </body> </html> <?php $Mark_Text = ob_get_contents(); $Mark_Text = Common_Mark($Mark_Text,0); ob_end_clean(); echo $Mark_Text; ?>