运营》关联链接,修改为判断“://”的方式,支持https、迅雷、BT等其他类型的链接。

This commit is contained in:
明明海海+ 2017-04-13 19:47:27 +08:00
parent 56a8cd05bc
commit 492957ede1
1 changed files with 1 additions and 1 deletions

View File

@ -17,7 +17,7 @@ function build_cache_relatedlink() {
$data = array();
$query = C::t('common_relatedlink')->range();
foreach($query as $link) {
if(substr($link['url'], 0, 7) != 'http://') {
if(!(strpos($link['url'], "://"))) {
$link['url'] = 'http://'.$link['url'];
}
$data[] = $link;