PHP伪原创同义词替代代码⽰意
PHP伪原创同义词替代代码⽰意
很多⽹站后台都是⽀持PHP,虽然⽤同义词百度能够识别,但⾄少⽐原封不动好些,没有AI原创NLP原创度⾼,但也有⼀定的效果。下⾯就是PHP代码实例:
<?php
require_once(dirname(__FILE__).'/config.php');
require_once(DEDEINC."/datalistcp.class.php");
CheckPurview('member_Type');
if(empty($dopost))
{
$dopost = "";
}
//保存更改
if($dopost=="save")
{
$startID = 1;
$endID = $idend;
for(;$startID<=$endID;$startID++)
{
$query = '';
$id = ${'ID_'.$startID};
$find = ${'find_'.$startID};
$replace = ${'replace_'.$startID};
$interconvert = ${'interconvert_'.$startID};
if(!isset($interconvert))
php简单秒杀实例代码$interconvert = 0;
else
$interconvert = 1;
if(isset(${'check_'.$startID}))
{
if($find!='' and $replace!='')
{
$query = "update `#@__str_replace` set `find`='$find',`replace`='$replace',`interconvert`=$interconvert where `id`='$id'";
$dsql->ExecuteNoneQuery($query);
}
}
else
{
$query = "Delete From #@__str_replace where id='$id' ";
$dsql->ExecuteNoneQuery($query);
}
}
//增加新记录
if(isset($check_new) && $find_new!='' && $replace_new!='')
{
if(empty($interconvert_new))
$interconvert_new = 0;
else
$interconvert_new = 1;
$query = "Insert Into `#@__str_replace`(`find`,`replace`,`interconvert`) Values('{$find_new}','{$replace_new}','{$interconvert_new}');"; $dsql->ExecuteNoneQuery($query);
}
header("Content-Type: text/html; charset={$cfg_soft_lang}");
echo "<script> alert('www.shuangxiniao!'); </script>";
}
else if($dopost=="batch_save")
{
$fp = fopen($batch, "r");
if (!$fp)
{
ShowMsg("www.shuangxiniao⽂件不存在!","-1");
exit;
}
//$query = "Delete From #@__str_replace ";
//$dsql->ExecuteNoneQuery($query);
$count = 0;
while (!feof($fp))
{
$bruce=fgets($fp);
$temp = explode($separator, $bruce);
$find_new = $temp[0];
$replace_new = $temp[1];
$interconvert_new = 1;
if($find_new!='' and $replace_new!='')
{
$query = "Insert Into `#@__str_replace`(`find`,`replace`,`interconvert`) Values('{$find_new}','{$replace_new}','{$interconvert_new}');"; $dsql->ExecuteNoneQuery($query);
$count++;
}
}
fclose($fp);
echo "<script> alert('www.shuangxiniao成功导⼊".$count."条同义词!'); </script>";
}
$sql = "Select * From #@__str_replace order by id desc";
$dlist = new DataListCP();
$dlist->SetTemplate(DEDEADMIN."/templets/pr_str_replace.htm");
$dlist->SetSource($sql);
$dlist->display();
function huihuan($inter)
{
if($inter==1)
{
return "checked='1'";
}
else
{
return "";
}
}
>
以上就是PHP伪原创同义词替代代码⽰意
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系QQ:729038198,我们将在24小时内删除。
发表评论