运营》关联链接,修改为判断“://”的方式,支持https、迅雷、BT等其他类型的链接。
This commit is contained in:
parent
56a8cd05bc
commit
492957ede1
|
@ -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;
|
||||
|
|
Loading…
Reference in New Issue