wordpress访问报错:
A TimThumb error has occured
The following error(s) occured:
You may not fetch images from that site. To enable this site in timthumb, you can either add it to $ALLOWED_SITES and set ALLOW_EXTERNAL=true. Or you can set ALLOW_ALL_EXTERNAL_SITES=true, depending on your security needs.
解决方式1
修改主题目录下的timthumb.php
文件:
设置 ALLOW_EXTERNAL=true,
define ('ALLOW_EXTERNAL', true);
然后修改以下位置,增加外链网址:
// If ALLOW_EXTERNAL is true and ALLOW_ALL_EXTERNAL_SITES is false, then external images will only be fetched from these domains and their subdomains.
if(! isset($ALLOWED_SITES)){
$ALLOWED_SITES = array (
'flickr.com',
'staticflickr.com',
'picasa.com',
'img.youtube.com',
'upload.wikimedia.org',
'photobucket.com',
'imgur.com',
'imageshack.us',
'tinypic.com',
);
}
解决方式2
这样允许所有外链网址:
/*
* --- TimThumb CONFIGURATION ---
* To edit the configs it is best to create a file called timthumb-config.php
* and define variables you want to customize in there. It will automatically be
* loaded by timthumb. This will save you having to re-edit these variables
* everytime you download a new version
*/
define ('VERSION', '2.8.14'); // Version of this script
define ('ALLOW_ALL_EXTERNAL_SITES', true);
最新评论
我的是ipv4网络,如何使用直播源啊!
我今天试了,不想啊,我的是新疆昌吉移动的网络。
收不到验证码电报
现在充值29起了