PHP类: SEO必备的伪原创工具 (文章重写)

伪原创工具是一种基于SEO理论的网络文章编辑软件的统称,主要功能是把从网上复制来的文章进行“原创”操作。

让复制来的文章瞬间变的看起来像原创一样,然后达到让搜索引擎认为是“原创”从而提高网站收录率,和收录数量。
专门针对谷歌、百度、雅虎等大型搜索引擎收录设计,通过伪原创工具生成的文章,会更好的被搜索引擎收录和索引到。

方法一:  在线工具

这个就不多说了,直接谷歌一下就可以,实在不行就 点击这里,我帮你搜!

方法二: PHP 类
说白了,方法很简单,就是单词替换而已,只是词库才是重点,没有词库,一切都是浮云啊!

PHP Spintax Class

<?PHP
/**
 * Spintax - A helper class to process Spintax strings.
 * @name Spintax
 * @author Jason Davis - http://www.codedevelopr.com/
 */
class Spintax
{
    public function process($text)
    {
        return preg_replace_callback(
            '/\{(((?>[^\{\}]+)|(?R))*)\}/x',
            array($this, 'replace'),
            $text
        );
    }

    public function replace($text)
    {
        $text = $this->process($text[1]);
        $parts = explode('|', $text);
        return $parts[array_rand($parts)];
    }
}
?>

PHP Spintax Example Usage

<?PHP
$spintax = new Spintax();
$string = '{Hello|Howdy|Hola} to you, {Mr.|Mrs.|Ms.} {Smith|Williams|Davis}!';
echo $spintax->process($string);
?>

Spintax string: {Hello|Howdy|Hola} to you, {Mr.|Mrs.|Ms.}{Smith|Williams|Davis}!

Spintax Output: Howdy to you, Mrs.Davis!

当然,对于上面的方式,个人赶紧有点费时,下面有一个提供词库的类:

index.php

<meta http-equiv="content-type" content="text/html; charset=utf-8" />

<?php
/**
 * Ikeepstudying : PHP伪原创类
 * Author: ikeepstudying
 * Create at: 2016-03-11 10:49
 */
class Ikeepstudying
{
    private $replaced = array();
    public $synonyms = array();
	
    //construct
    function __construct()
    {
        $this->synonyms = require(dirname(__FILE__).'/dict-en.php');
    }
	
    //replace
    function replace($text)
    {
        foreach($this->synonyms as $key => $val) {
            if(preg_match("/".$key."/", $text) && !in_array($key, $this->replaced)) {
                $text = str_replace($key, (is_array($val)?$val[array_rand($val)]:$val), $text);
                array_push($this->replaced, $val);
            }
        }
		
        return $text;
    }
}


$spinner = new Ikeepstudying();

$text = '

WordPress has a mechanism for saving, updating, and retrieving individual, named pieces of data (options) in the WordPress database. 

';

echo '<h2>Dict</h2><pre>'; print_r($spinner->synonyms); echo '</pre>';
echo '<h2>Orginal</h2> WordPress has a mechanism for saving, updating, and retrieving individual, named pieces of data (options) in the WordPress database.';
echo '<h2>New Content (after every refresh, it may be differnt words)</h2>'.$spinner->replace($text);

dict-en.php

<?php

return array
(
    'mechanism'  => array("mechanistic","medal","medallion","meddle","meddler","meddling","media"),
    'saving'     =>  array("saving clause",'savings and loan association','savoir-faire','savorless'),
    'individual' =>  array("individualism", "individualist", "individualistic",'individuality','individualize','individually','indivisible'),
);

替换中文的道理是一样的! 效果看这里:http://sources.ikeepstudying.com/spinner/

总结: 有词库才是硬道理!

 

本文:PHP类: SEO必备的伪原创工具,文章重写改写工具整理

Loading

Add a Comment

Your email address will not be published. Required fields are marked *

Time limit is exhausted. Please reload CAPTCHA.