If the configuration information in the conf/config. php file is changed, delete the runtime /~ Runtime. php; otherwise, the system information error may occur. for example, after configuring the database information: & lt ;? Ph...
If the configuration information in the conf/config. php file is changed, delete the runtime /~ Runtime. php; otherwise, the system information error may occur.
For example, after configuring the database information:
- If (! Defined ('think _ path') exit ();
- Return array (
- 'Db _ type' => 'mysql', // The database used is mysql.
- 'Db _ host' => 'localhost ',
- 'Db _ name' => 'myapp', // database NAME
- 'Db _ user' => 'root ',
- 'Db _ pwd' => 'yzw', // enter your database connection password
- 'Db _ port' => '123 ',
- 'Db _ prefix' => 'think _ ', // The table name PREFIX, see the http://thinkphp.cn/Article/10
- );
- ?>
Information cannot be flushed until I delete it ~ After runtime. php:
- Public function index (){
- // $ This-> assign ('str', "hello ");
- // $ This-> display ();
- $ Form = D ("Form ");
- $ Result = $ Form-> findAll ();
- Dump ($ result );
- }
The output information is as follows:
- Array (1) {[0] => array (7) {["id"] => string (1) "1" ["title"] => string (18) "This is the test data" ["content"] => string (4) "dfdf" ["create_time"] => string (10) 1212724876 "[" update_time "] => string (1)" 0 "[" status "] => string (1) "1" ["email"] => string (12) "dddd@ddd.com "}}