In addition to the variables passing through the PHP program, it can also read variables from the configuration file. This is very convenient to control the overall website style. Below is the content of this message board GB_Config.conf (note that the configuration file is put in In the configs directory), you can increase it yourself, modify that almost all HTML tag properties can be controlled here.
############ Global variable ##########
PageTitle = "Smarty Message Board V1.0" VLINK = "# 000000" Link = "# 000000" ALINK = "# 000000" Text = "# 000000"
########### interface style ###########
### 风一: Green style [GreenStyle] Background = "# fff" # 网 背景 背景 背景BG = "Images / bg2.jpg" #Net background fpageBG = "images / bg2.jpg" # 分页 背景 背景 背景 = "Images / Bg2.jpg "# cell background TableBG =" # 66cc33 "# Table background linecolor =" # 669900 "# 直线 c
### 风格 2: Blue style [Bluestyle] Background = "images / bihaibg.jpg" DAOHANGBG = "Images / DH.GIF" fpagebg = "images / dh.gif" TDBG = "images / title.gif" TableBG = "# 99ccff" linecolor = "# b4c9e7"
The examples of the methods of reference to these variables in the template file are as follows:
Note: Before reference, must have a declaration (load configuration file): <{config_load file = "gb_config.conf" section = "GreenStyle"}> Here I use green style, use other style, modify section can
(Continued)