另外:
注解:本安装只能实现博客内容中包括的图片添加水印,即只有博客内容中的 <img src="">标签引用的图片才会被添加水印,如果你上传了图片但是博客中使用了缩略图,那么只有缩略图添加水印!
wp-content/plugins
目录,然后在 Plugins 页面激活该插件。Setting->Super Image Plugin -> ContentImageDown
菜单下的两个设置均设置为 Yes。注解:按照本方法安装能够实现上传图片源文件和缩略图均添加水印。
首先按照简单安装,第一步操作完毕然后进行如下操作:
打开/wordpress/wp-admin/includes/media.php查找(大约第108行)
// Save the data
$id = wp_insert_attachment($attachment, $file, $post_parent);
在这段代码上面添加如下代码:
// INSERT HERE!!!
if (function_exists("IM_mark"))
{
IM_mark($file,$op="overwrite");
}
如果你要在你上传的图片缩略图和中型图片添加水印请进行如下操作,要求版本Wordpress v2.5.1,打开/wordpress/wp-includes/media.php查找如下代码(大约第230行)
imagedestroy( $newimage );
在这段代码上面添加如下代码:
// INSERT HERE!!!
if (function_exists("IM_mark"))
{
IM_mark($destfilename,$op="overwrite");
}
插件作者:askie 插件下载:Super Image Plugin