『大咖网盟』

收益高、结算快、超稳定,直营无中间商差价

『1866资源网』

全网最早的资源,实力雄厚,速度超快,超稳定

『78免费网盘』

永久免费的多媒体转码与云分发平台,无限存储

『209资源网』

全网唯一一家全亚洲服务器加速播放,速度超快

『推荐模板服务商』

海洋CMS官方推荐可信赖模板制作服务商家

让海洋CMS的导演和演员数据支持斜杠/分隔符

admin 2018-8-25 638

编辑 /include/common.func.php 文件第1386行,找到
function getKeywordsList($key,$span){
    if($key=='')return $key;
    $keyWordsStr="";
    $keystr=str_replace(",",",",$key);
    if (strpos($keystr,",")>0){$keyWordsArray=explode(",",$keystr);}else{$keyWordsArray=explode(" ",$keystr);}
    for($kli=0;$kli<count($keyWordsArray);$kli++){
        $keyWordsStr.="<a href='/".$GLOBALS['cfg_cmspath']."search.php?searchword=".urlencode($keyWordsArray[$kli])."'>".$keyWordsArray[$kli]."</a>".$span;
    }
    return $keyWordsStr;
}

function getJqList($key,$span){
    if($key=='')return $key;
    $keyWordsStr="";
    $keystr=str_replace(",",",",$key);
    if (strpos($keystr,",")>0){$keyWordsArray=explode(",",$keystr);}else{$keyWordsArray=explode(" ",$keystr);}
    for($kli=0;$kli<count($keyWordsArray);$kli++){
        $keyWordsStr.="<a href='/".$GLOBALS['cfg_cmspath']."search.php?searchtype=5&jq=".urlencode($keyWordsArray[$kli])."'>".$keyWordsArray[$kli]."</a>".$span;
    }
    return $keyWordsStr;
}
修改为
function getKeywordsList($key,$span){
    if($key=='')return $key;
    $keyWordsStr="";
    $keystr=str_replace(",",",",$key);
    $keystr=str_replace(" / ",",",$key);
    if (strpos($keystr,",")>0){$keyWordsArray=explode(",",$keystr);}else{$keyWordsArray=explode(" ",$keystr);}
    for($kli=0;$kli<count($keyWordsArray);$kli++){
        $keyWordsStr.="<a href='/".$GLOBALS['cfg_cmspath']."search.php?searchword=".urlencode($keyWordsArray[$kli])."'>".$keyWordsArray[$kli]."</a>".$span;
    }
    return $keyWordsStr;
}

function getJqList($key,$span){
    if($key=='')return $key;
    $keyWordsStr="";
    $keystr=str_replace(",",",",$key);
    if (strpos($keystr,",")>0){$keyWordsArray=explode(",",$keystr);}else{$keyWordsArray=explode(" ",$keystr);}
    for($kli=0;$kli<count($keyWordsArray);$kli++){
        $keyWordsStr.=" / <a href='/".$GLOBALS['cfg_cmspath']."search.php?searchtype=5&jq=".urlencode($keyWordsArray[$kli])."'>".$keyWordsArray[$kli]."</a>".$span;
    }
    return $keyWordsStr;
}
此时已经实际将斜杠转换成SeaCMS默认的空格分隔符效果。

如果要像豆瓣那样中间有不带超链接的斜杠分隔,继续修改:
编辑 /include/mkhtml.func.php 文件第507行,找到
$content=str_replace("{playpage:actor}",getKeywordsList($v_actor," "),$content);
$content=str_replace("{playpage:director}",getKeywordsList($row['v_director']," "),$content);
修改为:
$content=str_replace("{playpage:actor}",getKeywordsList($v_actor," / "),$content);
$content=str_replace("{playpage:director}",getKeywordsList($row['v_director']," / "),$content);




原文:https://www.2dan.cc/seacms/xiegang-fengefu.html
最新回复 (0)
返回
发新帖