debug
This commit is contained in:
@@ -21,6 +21,7 @@ class Site extends TagLib
|
||||
|
||||
'forgelist' => ['attr' => 'count,diff_key,cache_life,d_key,d_val', 'close' => 1],
|
||||
'helper' => ['attr' => 'func', 'close' => 0],
|
||||
'getval' => ['attr' => 'code', 'close' => 0],
|
||||
];
|
||||
|
||||
private function customBuildVar($mixedArgs)
|
||||
@@ -33,9 +34,32 @@ class Site extends TagLib
|
||||
}
|
||||
|
||||
/**
|
||||
* 小说详情URL生成器
|
||||
* 内容替换
|
||||
*
|
||||
* @param array $n_id
|
||||
* @param array
|
||||
* @return string
|
||||
*/
|
||||
public function tagGetVal($tag)
|
||||
{
|
||||
$strCode = $tag['code'];
|
||||
|
||||
if (empty($strCode)) {
|
||||
return ''; // 或返回默认值
|
||||
}
|
||||
|
||||
$strParse = <<<EOD
|
||||
<?php
|
||||
\$strUrl = app(\\app\\services\\SiteContext::class)->getConverterVal("{$strCode}");
|
||||
echo \$strUrl;
|
||||
?>
|
||||
EOD;
|
||||
return $strParse;
|
||||
}
|
||||
|
||||
/**
|
||||
* 视图反向控制器(注释函数)
|
||||
*
|
||||
* @param array $func
|
||||
* @return string
|
||||
*/
|
||||
public function tagHelper($tag)
|
||||
|
||||
Reference in New Issue
Block a user