Front Entrance file index.php
<?php//+----------------------------------------------------------------------//| thinkphp [WE CAN do IT JUST THINK]//+----------------------------------------------------------------------//| Copyright (c) 2006-2014 http://thinkphp.cn All rights reserved.//+-------------------------------------------------- --------------------// | Licensed (http://www.apache.org/licenses/LICENSE-2.0)//+------------------------------------------------------- ---------------// | author:liu21st <[email protected]>//+--------------------------------------------------------------- -------//Application entry file//Detect PHP Environment if (Version_compare (php_version, ' 5.3.0 ', ' < ') die (' Require PHP > 5.3.0! '); /Open debug mode suggest the development phase to open the deployment phase gaze or set to Falsedefine (' App_debug ', True);//define the Execution folder define (' Runtime_path ', './runtime/');// Define the path of the static page define (' Html_path ', './html/');//define the Application Folder define (' App_path ', './application/');//define the default module define (' Bind_ MODULE ', ' Home ');//define Site root folder define (' Web_path ', DirName (__file__));//import thinkphp import file require'./thinkphp/thinkphp.php ';//Pro ^_^ No matter what code it is, it's so simple.
Background entry file admin.php
<?php//+----------------------------------------------------------------------//| thinkphp [WE CAN do IT JUST THINK]//+----------------------------------------------------------------------//| Copyright (c) 2006-2014 http://thinkphp.cn All rights reserved.//+-------------------------------------------------- --------------------// | Licensed (http://www.apache.org/licenses/LICENSE-2.0)//+------------------------------------------------------- ---------------// | author:liu21st <[email protected]>//+--------------------------------------------------------------- -------//Application entry file//Detect PHP Environment if (Version_compare (php_version, ' 5.3.0 ', ' < ') die (' Require PHP > 5.3.0! '); /Open debug mode suggest the development phase to open the deployment phase gaze or set to Falsedefine (' App_debug ', True);//define the Execution folder define (' Runtime_path ', './runtime/');// Define the path of the static page define (' Html_path ', './html/');//define the Application Folder define (' App_path ', './application/');//define the default module define (' Bind_ MODULE ', ' Admin ');//define Site root folder define (' Web_path ', DirName (__file__));//import thinkphp import file require './thinkphp/thinkphp.php ';//Pro ^_^ No matter what code it is, it's so simple.
This kind of words URL can easily remove the module name, no need to configure the configuration file configuration what default module, what module list,, haha. I've tried it, unless you just have a module, and, assuming there are multiple modules, it's best to configure like me ....
thinkphp3.2 defining multiple modules and setting default modules