在php代码中调用帝国cms头部变量temp.header的方法
直接上代码
复制代码
<?php
require("../e/class/connect.php");
if(!defined('InEmpireCMS'))
{
exit();
}
require("../e/class/db_sql.php");
require("../e/class/q_functions.php");
$link=db_connect();
$empire=new mysqlquery();
$headr=$empire->fetch1("select varvalue from {$dbtbpre}enewstempvar where myvar='header' limit 1");
?>
代码如下:
<?php
require("../e/class/connect.php");
if(!defined('InEmpireCMS'))
{
exit();
}
require("../e/class/db_sql.php");
require("../e/class/q_functions.php");
$link=db_connect();
$empire=new mysqlquery();
$headr=$empire->fetch1("select varvalue from {$dbtbpre}enewstempvar where myvar='header' limit 1");
?>
在调用的地方直接
复制代码
<?=stripslashes($headr[0])?>
代码如下:
<?=stripslashes($headr[0])?>