<?php

//禁止直接访问
!defined('IN_SYSTEM') && exit('Access Denied');

//生成input_key
$_SESSION['NavInputKey'] = generate_rand_string(50);
//将input_key赋值给模板
$smarty->assign('NavInputKey', $_SESSION['NavInputKey']);

//连接到MYSQL并打开系统数据库
$DataBase->open_db();
//读取导航条信息
$DataBase->sel('nav', "ORDER BY `order` ASC");
//关闭数据库连接
$DataBase->close_dblink();
//将导航条信息赋值给模板
$smarty->assign('HeaderNavList', $DataBase->Result);

?>