文章推荐系统(二)
系统 推荐 文章
2023-06-13 09:13:43 时间
======APPRE.PHP==========
$strlen=strlen($articlemsg);
if($strlen<50){
echo"<tablealign=centerwidth=100%>";
echo"<tralign=center><td>";
echo"你是不是在灌水呀?为防止部分网友善意的灌水,本站规定你所提交的文章";
echo"</td></tr>";
echo"<tralign=center><td>";
echo"的长度必须大于50个汉字。请你重新提交文章。谢谢";
echo"</td></tr>";
echo"<tr><tdalign=center>";
echo"<ahref=appre.htm>【重新提交文章】</a>  ";
echo"<ahref=index.php>【返回到主页】</a>";
echo"</td></tr>";
echo"</table>";
echo"<tableborder=0cellpadding=5cellspacing=0width=100%bgcolor=00FF00>";
echo"<tr>";
echo"<tdwidth=20%>| <ahref=index.php>返回首页 </a> </td>";
echo"<tdwidth=20%> | <ahref=help.htm>推荐说明</a>
|</td>";
echo"<tdwidth=20%> <ahref=#>搜索文章 </a>
| </td>";
echo"<tdwidth=20%> <ahref=article.php>阅读文章</a>
|</td>";
echo"<tdwidth=20%> <ahref=mailto:webinfro@163.com>联系站长</a>
|</td>";
echo"</tr>";
echo"</table>";
exit;
}
$strlen=strlen($name);
if($strlen<=1){
echo"<tablealign=centerwidth=100%>";
echo"<tralign=center><td>";
echo"请你正确输入你的名字";
echo"</td></tr>";
echo"<tr><tdalign=center>";
echo"【<ahref=appre.htm>重新提交文章</a>】  ";
echo"【<ahref=index.php>返回主页</a>】";
echo"</td></tr>";
echo"</table>";
echo"<tableborder=0cellpadding=5cellspacing=0width=100%bgcolor=00FF00>";
echo"<tr>";
echo"<tdwidth=20%>| <ahref=index.php>返回首页 </a> </td>";
echo"<tdwidth=20%> | <ahref=help.htm>推荐说明</a>
|</td>";
echo"<tdwidth=20%> <ahref=#>搜索文章 </a>
| </td>";
echo"<tdwidth=20%> <ahref=article.php>阅读文章</a>
|</td>";
echo"<tdwidth=20%> <ahref=mailto:webinfro@163.com>联系站长</a>
|</td>";
echo"</tr>";
echo"</table>";
exit;
}
@$conn=mysql_connect("localhost","user","password");
mysql_select_db("bamboo");
$sql="select*fromarticlewherearticlename="$articlename"";
$result=mysql_query($sql,$conn);
if($result){
if(mysql_fetch_object($result)){
echo"<tablealign=centerwidth=100%>";
echo"<tr><tdalign=center>";
echo"你所推荐的文章已经存在了";
echo"</td>";
echo"<tdalign=center>";
echo"<ahref=appre.htm>重新推荐下一篇文章</a>";
echo"</td></tr>";
echo"<tr><tdalign=center>";
echo"如果你确信本站没有你所推荐的文章,请你点<ahref=mailto:webinfro@163.com>这里</a>与此同时Bamboo联系";
echo"</td></tr>";
echo"<tr><tdalign=center>";
echo"【<ahref=appre.htm>重新发表新的文章</a>】";
echo"【<ahref=index.php>返回主页</a>】";
echo"</td></tr>";
echo"</table>";
mysql_close($conn);
echo"<tableborder=0cellpadding=5cellspacing=0width=100%bgcolor=00FF00>";
echo"<tr>";
echo"<tdwidth=20%>| <ahref=index.php>返回首页 </a> </td>";
echo"<tdwidth=20%> | <ahref=help.htm>推荐说明</a>
|</td>";
echo"<tdwidth=20%> <ahref=#>搜索文章 </a>
| </td>";
echo"<tdwidth=20%> <ahref=article.php>阅读文章</a>
|</td>";
echo"<tdwidth=20%> <ahref=mailto:webinfro@163.com>联系站长</a>
|</td>";
echo"</tr>";
echo"</table>";
exit;}
}
$sql="select*fromarticlewherename=$name";
$result=mysql_query($sql,$conn);
if($result){
if(mysql_fetch_object($result)){
echo"<tablewidth=100%align=center>";
echo"<tralign=center>";
echo"<tdalign=center>";
echo"本站数据库记录显示已经有一个和你同名的记录,请你换一个名字重新发表文章";
echo"</td></tr>";
echo"<tr><tdalign=center>";
echo"<ahref=appre.htm>重新发表文章</a>";
echo"<ahref=index.php>返回主页</a>";
echo"</td></tr>";
echo"</table>";
mysql_close($conn);
echo"<tableborder=0cellpadding=5cellspacing=0width=100%bgcolor=00FF00>";
echo"<tr>";
echo"<tdwidth=20%>| <ahref=index.php>返回首页 </a> </td>";
echo"<tdwidth=20%> | <ahref=help.htm>推荐说明</a>
|</td>";
echo"<tdwidth=20%> <ahref=#>搜索文章 </a>
| </td>";
echo"<tdwidth=20%> <ahref=article.php>阅读文章</a>
|</td>";
echo"<tdwidth=20%> <ahref=mailto:webinfro@163.com>联系站长</a>
|</td>";
echo"</tr>";
echo"</table>";
exit;
}
}
echo$webadd1;
$sql="insertintoarticle(name,webname,webadd,weblogo,articlename,articleauthor,articlemsg)values("$name","$webname","$webadd","$weblogo","$articlename"
,"$articleauthor"
,"$articlemsg"
)";
//echomysql_errno().":".mysql_error()."<br>";
if(mysql_query($sql,$conn)){
echo"<tablewidth=100%align=center>";
echo"<tr><tdalign=center>";
echo"谢谢你,斑竹园的发展离不开你的支持。你提交的文章已经接受";
echo"</td></tr>";
echo"<tr><tdalign=center>";
echo"【<ahref=appre.htm>提交另一篇文章</a>】";
echo"【<ahref=index.php>返回主页</a>】";
echo"</td></tr>";
echo"</table>";
mysql_close($conn);
}
else{
echo"<tablewidth=100%align=center>";
echo"<tr><tdalign=center>";
echo"对不起,你提交的文章出现错误,请你重新提交";
echo"</td></tr>";
echo"<tr><tdalign=center>";
echo"【<ahref=appre.htm>重新提交</a>】";
echo"【<ahref=index.php>返回主页</a>】";
echo"</td></tr>";
echo"</table>";
mysql_close($conn);
}
echo"<tableborder=0cellpadding=5cellspacing=0width=100%bgcolor=00FF00>";
echo"<tr>";
echo"<tdwidth=20%>| <ahref=index.php>返回首页 </a> </td>";
echo"<tdwidth=20%> | <ahref=help.htm>推荐说明</a>
|</td>";
echo"<tdwidth=20%> <ahref=#>搜索文章 </a>
| </td>";
echo"<tdwidth=20%> <ahref=article.php>阅读文章</a>
|</td>";
echo"<tdwidth=20%> <ahref=mailto:webinfro@163.com>联系站长</a>
|</td>";
echo"</tr>";
echo"</table>";
?>
$strlen=strlen($articlemsg);
if($strlen<50){
echo"<tablealign=centerwidth=100%>";
echo"<tralign=center><td>";
echo"你是不是在灌水呀?为防止部分网友善意的灌水,本站规定你所提交的文章";
echo"</td></tr>";
echo"<tralign=center><td>";
echo"的长度必须大于50个汉字。请你重新提交文章。谢谢";
echo"</td></tr>";
echo"<tr><tdalign=center>";
echo"<ahref=appre.htm>【重新提交文章】</a>  ";
echo"<ahref=index.php>【返回到主页】</a>";
echo"</td></tr>";
echo"</table>";
echo"<tableborder=0cellpadding=5cellspacing=0width=100%bgcolor=00FF00>";
echo"<tr>";
echo"<tdwidth=20%>| <ahref=index.php>返回首页 </a> </td>";
echo"<tdwidth=20%> | <ahref=help.htm>推荐说明</a>
|</td>";
echo"<tdwidth=20%> <ahref=#>搜索文章 </a>
| </td>";
echo"<tdwidth=20%> <ahref=article.php>阅读文章</a>
|</td>";
echo"<tdwidth=20%> <ahref=mailto:webinfro@163.com>联系站长</a>
|</td>";
echo"</tr>";
echo"</table>";
exit;
}
$strlen=strlen($name);
if($strlen<=1){
echo"<tablealign=centerwidth=100%>";
echo"<tralign=center><td>";
echo"请你正确输入你的名字";
echo"</td></tr>";
echo"<tr><tdalign=center>";
echo"【<ahref=appre.htm>重新提交文章</a>】  ";
echo"【<ahref=index.php>返回主页</a>】";
echo"</td></tr>";
echo"</table>";
echo"<tableborder=0cellpadding=5cellspacing=0width=100%bgcolor=00FF00>";
echo"<tr>";
echo"<tdwidth=20%>| <ahref=index.php>返回首页 </a> </td>";
echo"<tdwidth=20%> | <ahref=help.htm>推荐说明</a>
|</td>";
echo"<tdwidth=20%> <ahref=#>搜索文章 </a>
| </td>";
echo"<tdwidth=20%> <ahref=article.php>阅读文章</a>
|</td>";
echo"<tdwidth=20%> <ahref=mailto:webinfro@163.com>联系站长</a>
|</td>";
echo"</tr>";
echo"</table>";
exit;
}
@$conn=mysql_connect("localhost","user","password");
mysql_select_db("bamboo");
$sql="select*fromarticlewherearticlename="$articlename"";
$result=mysql_query($sql,$conn);
if($result){
if(mysql_fetch_object($result)){
echo"<tablealign=centerwidth=100%>";
echo"<tr><tdalign=center>";
echo"你所推荐的文章已经存在了";
echo"</td>";
echo"<tdalign=center>";
echo"<ahref=appre.htm>重新推荐下一篇文章</a>";
echo"</td></tr>";
echo"<tr><tdalign=center>";
echo"如果你确信本站没有你所推荐的文章,请你点<ahref=mailto:webinfro@163.com>这里</a>与此同时Bamboo联系";
echo"</td></tr>";
echo"<tr><tdalign=center>";
echo"【<ahref=appre.htm>重新发表新的文章</a>】";
echo"【<ahref=index.php>返回主页</a>】";
echo"</td></tr>";
echo"</table>";
mysql_close($conn);
echo"<tableborder=0cellpadding=5cellspacing=0width=100%bgcolor=00FF00>";
echo"<tr>";
echo"<tdwidth=20%>| <ahref=index.php>返回首页 </a> </td>";
echo"<tdwidth=20%> | <ahref=help.htm>推荐说明</a>
|</td>";
echo"<tdwidth=20%> <ahref=#>搜索文章 </a>
| </td>";
echo"<tdwidth=20%> <ahref=article.php>阅读文章</a>
|</td>";
echo"<tdwidth=20%> <ahref=mailto:webinfro@163.com>联系站长</a>
|</td>";
echo"</tr>";
echo"</table>";
exit;}
}
$sql="select*fromarticlewherename=$name";
$result=mysql_query($sql,$conn);
if($result){
if(mysql_fetch_object($result)){
echo"<tablewidth=100%align=center>";
echo"<tralign=center>";
echo"<tdalign=center>";
echo"本站数据库记录显示已经有一个和你同名的记录,请你换一个名字重新发表文章";
echo"</td></tr>";
echo"<tr><tdalign=center>";
echo"<ahref=appre.htm>重新发表文章</a>";
echo"<ahref=index.php>返回主页</a>";
echo"</td></tr>";
echo"</table>";
mysql_close($conn);
echo"<tableborder=0cellpadding=5cellspacing=0width=100%bgcolor=00FF00>";
echo"<tr>";
echo"<tdwidth=20%>| <ahref=index.php>返回首页 </a> </td>";
echo"<tdwidth=20%> | <ahref=help.htm>推荐说明</a>
|</td>";
echo"<tdwidth=20%> <ahref=#>搜索文章 </a>
| </td>";
echo"<tdwidth=20%> <ahref=article.php>阅读文章</a>
|</td>";
echo"<tdwidth=20%> <ahref=mailto:webinfro@163.com>联系站长</a>
|</td>";
echo"</tr>";
echo"</table>";
exit;
}
}
echo$webadd1;
$sql="insertintoarticle(name,webname,webadd,weblogo,articlename,articleauthor,articlemsg)values("$name","$webname","$webadd","$weblogo","$articlename"
,"$articleauthor"
,"$articlemsg"
)";
//echomysql_errno().":".mysql_error()."<br>";
if(mysql_query($sql,$conn)){
echo"<tablewidth=100%align=center>";
echo"<tr><tdalign=center>";
echo"谢谢你,斑竹园的发展离不开你的支持。你提交的文章已经接受";
echo"</td></tr>";
echo"<tr><tdalign=center>";
echo"【<ahref=appre.htm>提交另一篇文章</a>】";
echo"【<ahref=index.php>返回主页</a>】";
echo"</td></tr>";
echo"</table>";
mysql_close($conn);
}
else{
echo"<tablewidth=100%align=center>";
echo"<tr><tdalign=center>";
echo"对不起,你提交的文章出现错误,请你重新提交";
echo"</td></tr>";
echo"<tr><tdalign=center>";
echo"【<ahref=appre.htm>重新提交</a>】";
echo"【<ahref=index.php>返回主页</a>】";
echo"</td></tr>";
echo"</table>";
mysql_close($conn);
}
echo"<tableborder=0cellpadding=5cellspacing=0width=100%bgcolor=00FF00>";
echo"<tr>";
echo"<tdwidth=20%>| <ahref=index.php>返回首页 </a> </td>";
echo"<tdwidth=20%> | <ahref=help.htm>推荐说明</a>
|</td>";
echo"<tdwidth=20%> <ahref=#>搜索文章 </a>
| </td>";
echo"<tdwidth=20%> <ahref=article.php>阅读文章</a>
|</td>";
echo"<tdwidth=20%> <ahref=mailto:webinfro@163.com>联系站长</a>
|</td>";
echo"</tr>";
echo"</table>";
?>
相关文章
- 深入理解推荐系统:如何多种业务场景合并建模
- Mac 系统中使用maven 配置环境变量
- AAAI'22「腾讯」多任务推荐系统中的跨任务知识蒸馏
- 推荐系统(十二)「腾讯」推荐系统中one-hot一定好吗?它忽略了一些信息
- 对比学习技术在推荐系统的应用学习笔记
- 推荐系统模型发展简史
- 推荐系统[八]算法实践总结V0:腾讯音乐全民K歌推荐系统架构及粗排设计
- 【baseline】Kaggle新赛!多目标推荐系统大赛,20+w奖金
- 推荐系统[二]:召回算法超详细讲解[召回模型演化过程、召回模型主流常见算法(DeepMF_TDM_Airbnb Embedding_Item2vec等)、召回路
- Linux系统:为世界提供可靠的动力(linux操作系统的用途)
- 应用深入了解: Linux的强大系统应用.(linux有哪些系统)
- Linux系统如何高效检测端口开启情况(linux看端口)
- Linux分支系统:探索新的可能性(linux的分支)
- 命令掌握Linux系统的Top命令(linux系统top)
- Linux入门及进阶:最新系统内核分析与学习指南(学linux书籍推荐)
- Linux杀毒软件推荐:保护你的系统免受恶意攻击(杀毒linux)
- linux,打造最强大的操作系统(linux最好的系统)
- 探索Linux系统的Git私钥之旅(linuxgit私钥)
- 比较:安卓系统vs Linux系统(安卓系统与linux系统)
- Linux系统入门:最佳的学习教程(linux教程推荐)
- 【Linux: 如何判断系统是64位的?】(linux判断64位)
- 开启Linux之旅:探索最强大的操作系统(linux 系统介绍)
- 注意:Linux 系统中的同名文件!(linux 同名文件)
- 利用Redis实现高效推荐系统(用redis做推荐系统)
- 调整调整Redis连接数,提升系统性能(redis连接数大小如何)