rom {$table_prefix}c_article where art_title =''$art_title'' ");//查看标题是否重复
$title_ct=@mysql_fetch_array($title_ct);
$title_ct=$title_ct[0];
if($title_ct>0)
{
$art_title .="{$same_title}{$title_ct}";
}
$art_time=date("Y-m-d");
$art_content=strtr($art_content,$keyword);
$sql="insert into {$table_prefix}c_article(art_title,art_content,art_time,art_author,suid) values(''$art_title'',''$art_content'',''$art_time'',''$art_author'',''$suid'')";//插入采集表
mysql_query($sql);
if(empty($t_catx_id))//如果无分类
{
$sql2="insert into {$t_table}({$t_art_title},{$t_art_content},{$t_art_time},{$t_artx_author}) values(''$art_title'',''$art_content'',''$art_time'',''$art_author'')";
}else
{
$sql2="insert into {$t_table}({$t_art_title},{$t_art_content},{$t_art_time},{$t_artx_author},{$t_catx_id}) values(''$art_title'',''$art_content'',''$art_time'',''$art_author'',''$cat_id'')";
}
mysql_query($sql2);//插入文章表
$jl++;
//数据库处理完毕
}else
{
echo "内容长度不够";
}
//获取文章内容结束
}else
{
echo "主题不符合要求";
}
}else
{
echo "已经存在";
}$rs++;
file_put_contents("bd.txt","采集{$searchStr}到第{$page}第{$rs}条");
echo "<script>location.href=''baidu.php?searchStr=".urlencode($searchStr)."&page=".$page."&rs=".$rs."&jl=".$jl." '';</script>";
exit();
}
?>
<link href="style.css" rel="stylesheet" type="text/css" />
<table width="700" border="0" align="center" cellspacing="1" bgcolor="#CCCCCC">
<tr>
<td height="50" align="center" bgcolor="#00CC00"><h1><a href="http://www.jianlila.com">荐礼啦</a>知道问问采集插件</h1></td>
</tr>
</table>
<table width="700" border="0" align="center" cellspacing="1" bgcolor="#CCCCCC" style="margin-top:6px; margin-bottom:6px;">
<tr>
<td height="30" align="center" bgcolor="#FFFFFF"><a href="cj_config.php">采集设置</a> <a href="uninstall.php" onclick="return confirm(''您确定要卸载采集插件吗'');">卸载采集</a> <a href="cj_view.php">查看采集记录</a> <a href="cj_help.php">采集帮助</a> <a href="baidu.php" target="_blank">知道采集</a> <a href="wenwen.php" target="_blank">问问采集</a></td>
</tr>
</table>
<table width="537" height="45" align="center" style="margin-top:30px;"><tr><td height="39">
<form id="form1" name="form1" method="get" action="baidu.php">
<div id="search">
<input name="searchStr" type="text" id="searchStr" value="<?php echo $searchStr; ?>" size="60" />
<input type="submit" name="searchBtn" id="searchBtn" value="知道偷偷" style="height:25px; line-height:25px;" />
</div>
</form>
</td></tr></table>
问问采集代码:
复制代码 代码如下:
<?php
session_start();
header("content-type:text/html;charset=utf-8");
require("stole_config.php");
require("conn.php");
require("keyword.php");
if(!empty(
php知道与问问的采集插件代码_网学
浏览:
POST[''ask'']))
{
$ask=urlencode(trim(
php知道与问问的采集插件代码_网学
浏览:
POST[''ask'']));//获取表单提交的