current location:Home > Technical Articles > PHP Framework > ThinkPHP
- Direction:
- All web3.0 Backend Development Web Front-end Database Operation and Maintenance Development Tools PHP Framework Daily Programming WeChat Applet Common Problem Other Tech CMS Tutorial Java System Tutorial Computer Tutorials Hardware Tutorial Mobile Tutorial Software Tutorial Mobile Game Tutorial
- Classify:
-
- How to sum in thinkphp template
- How to implement sum in thinkphp template: 1. Create a Show controller; 2. In the Show controller, create an index method to pass data to the template; 3. Create a digital array and use assign to pass the array to index.html page; 4. Render the page output results through the display method; 5. Use the array_sum function to calculate the sum of the array values and output it on the page.
- ThinkPHP 1474 2022-12-06 10:32:07
-
- What to do if thinkphp create method fails
- Solution to the failure of the thinkphp create method: 1. Write a test method to simulate the data input by the user on the front-end page, with code such as "public function insert2(){...}"; 2. Add a default value to the status field in the database. 1 and save the settings.
- ThinkPHP 1388 2022-12-06 10:21:22
-
- What to do if Chinese garbled characters appear in thinkphp5
- Solution to Chinese garbled characters in thinkphp5: 1. Add "character-set-server = utf8mb4 collation-server = utf8mb4_unicode_ci" to mysqld in my.ini; 2. Indicate the character encoding "header('Content" in the background program PHP code -Type: text/html; charset=utf-8');".
- ThinkPHP 1577 2022-12-06 10:14:51
-
- How to use the add method in thinkphp
- The add method in thinkphp is used to add data to the data table, which is equivalent to the INSERT INTO behavior in SQL. Its usage syntax is such as "if($lastInsId = $Dao->add($data)){...}".
- ThinkPHP 1746 2022-12-06 10:05:35
-
- How to use thinkphp big d method
- The thinkphp big d method is used to instantiate a custom model class. It is an encapsulation of the Model class instantiation by the ThinkPHP framework. It implements the singleton mode and supports cross-project and group calls. Its usage syntax is such as "$User = D( 'User');" means instantiating a custom model of the current project.
- ThinkPHP 1948 2022-12-06 09:55:05
-
- What to do if thinkphp token fails
- Solution to thinkphp token failure: 1. Open the WeChat applet token verification code; 2. Clear the cache area before outputting "echostr", that is, placing the "ob_clean();" code before echo can solve the problem of token failure. .
- ThinkPHP 2076 2022-12-06 09:50:31
-
- How to hide home in thinkphp3.2
- How to hide home in thinkphp3.2: 1. Add "define('BIND_MODULE','Home');" to index.php; 2. Find the "application/commom/conf/config.php" file and add the configuration as "' URL_MODEL'=>2." That's it.
- ThinkPHP 1631 2022-12-06 09:33:24
-
- What should I do if thinkphp5 post cannot get the value?
- thinkphp5 post cannot get a value because TP5 uses the strpos function to find the app/json string in the content-type value of the Header. The solution is to set the content-type value of the Header to app/json.
- ThinkPHP 2174 2022-12-06 09:29:09
-
- How to use thinkphp 3.23 c method
- The c method in thinkphp3.23 is the method used by ThinkPHP to set, obtain, and save configuration parameters. It is used frequently; its usage syntax is such as "C('DB_NAME','thinkphp');" which means setting the DB_NAME configuration parameter. The value is thinkphp.
- ThinkPHP 1837 2022-12-06 09:29:18
-
- What to do if thinkphp eq fails?
- Solution to thinkphp eq failure: 1. Open the corresponding tp file; 2. Check the eq tag; 3. Modify the usage method to "{eq name="$vo.adminrole" value="0"}<td style="text -align: center"></td>{/eq}" is enough.
- ThinkPHP 1591 2022-12-05 11:31:45
-
- How to remove bom in thinkphp
- How to remove BOM in thinkphp: 1. Run Editplus, click "Tools", select "Preferences", and then set the "UTF-8 Identity"; 2. Open the file through ultraedit and select "utf-" in the encoding format of the Save As option. 8No BOM header"; 3. Use the "92wcms.php" program in the directory to remove the BOM.
- ThinkPHP 1215 2022-12-05 11:11:12
-
- thinkphp exp what does it mean
- thinkphp exp is a comprehensive expression to support more complex condition settings. The operating conditions of exp will not be treated as strings. Any syntax supported by SQL can be used, including the use of function and field names; exp is not only used for where conditions, but also Can be used for data updates.
- ThinkPHP 1913 2022-12-05 11:01:58
-
- thinkphp ds what does it mean
- thinkphp ds represents the meaning of slash/; under window, it represents backslash\ or slash/, but for compatibility with writing, it is recommended to use slash/; the use of ds is equivalent to "$info = $file->move(ROOT_PATH . 'public/uploads');".
- ThinkPHP 1888 2022-12-05 10:58:43
-
- How to get request headers in thinkphp5
- How to get the request header in thinkphp5: 1. Get all the information in the request header through the "$info=Request::instance()->header();" method; 2. Use "$accept=Request::instance()- >header('accept');" method obtains the information in a request header.
- ThinkPHP 2362 2022-12-05 10:48:37
-
- How to remove url index in thinkphp
- How to remove url index in thinkphp: 1. Move the .htaccess file to the root directory of the project; 2. Add "'URL_MODEL' => 2," to the project's configuration file; 3. Open Apache's httpd.conf file; 4. Delete the # symbol in front of mod_rewrite.so; 5. Restart Apache.
- ThinkPHP 1464 2022-12-05 10:44:03