Wampserver has been downloaded and will have time to try to run thinkphp locally.
In the app/lib/action/folder, you can define a controller class for each module, a module can contain multiple action methods, and when requested, resolves the currently requested module and operation from the URL parameter. For example, define the default controller class IndexAciton.class.php:
<?phpclass Indexaction extends action{ ptotect function _initialize () { header ("content-type:text/html; Charset=utf-8 "); } Public Function Index () { $this->display (); } Public Function Imit () { echo 'SAE Service Simulator Functional Testing (the following services can also be run locally):
"; }}
Accessing http://localhost/, the system accesses the default action (index) of the default module (index). Relative input http://localhost/Index/imit, the system accesses the default module (Index) operation Method (Imit). This URL pattern is pathinfo mode, the default format for thinkphp, and other formats can be set in thinkphp/conf/convention.php, such as normal mode, rewrite mode, and compatibility mode.
Just notes, why can not be set to only their own visible, I write a mess are embarrassed to show people ah.
The rewrite mode of the URL request is the support for adding rewrite rules based on the PathInfo mode, which is the addition of the. htaccess file at the portal file's peers, as in Apache:
Rewriteengine Onrewritecond%{request_filename}!-drewritecond%{request_filename}!-fRewriteRule ^ (. *) $ index.php/$1 [Qsa,pt,l]
The only way to do this is to turn on Apache's rewrite function. Locate LoadModule Rewrite_module modules/mod_rewrite.so in the httpd.conf configuration file, remove the previous # and find allowoverride none to allowoverride all. This will work.
http://www.bkjia.com/PHPjc/825530.html www.bkjia.com true http://www.bkjia.com/PHPjc/825530.html techarticle Wampserver has been downloaded and will have time to try to run thinkphp locally. In the app/lib/action/folder, you can define a controller class for each module, and a module can contain multiple ...