您好,欢迎光临! 推荐您使用Chrome浏览器访问本站。

为自己的WordPress blog添加版权信息

打开主题下的 functions.php 文件,在最后添加如下代码,将内容修改成你想要的样子。

代码如下:

<pre>function feed_copyright($content) {
     if(is_single() or is_feed()) {
          $content.= "<p class='crinfo'>";
          $content.= '&raquo; 版权所有:<a title="owoer" href="http://www.iswz.net/">Themeidea</a> &raquo; <a rel="bookmark" title="'.get_the_title().'" href="'.get_permalink().'">《'.get_the_title().'》</a><br />';
          $content.= '&raquo; 本文链接:<a rel="bookmark" title="'.get_the_title().'" href="'.get_permalink().'">'.get_permalink().'</a><br />';
          $content.= '&raquo; 站长声明:除特别标注,本站所有文章均为原创. 互联分享,尊重版权,转载注明出处';
          $content.= "</p><br />";
     }
     return $content;
}
add_filter ('the_content', 'feed_copyright');

您可能也喜欢