Full solution of THinKPHP function library

Source: Internet
Author: User
: This article mainly introduces the full solution of the THinKPHP function library. if you are interested in the PHP Tutorial, please refer to it. In ThinkPHP 3.2.3, 46 of the following function systems have been encapsulated. The following are summarized for two purposes:
1. understand the ThinkPHP framework methods.

2. developers do not need to encapsulate their own methods.


Go to the topic:
1 letter function: a total of 16
A cross-origin call (commonly used)
B Behavior: execution Behavior
C config load the configuration file (frequently used)
D: Model instantiation (common)
E exception handling
F file processing
G records and statistics time (microseconds) and memory usage
I form processing (commonly used)
L language: language Pack
M Model database table operations (commonly used)
N. set and obtain statistical data
R cross-origin call
S cache
T template
U url processing (commonly used)
W Widget rendering output
2 single word functions (12)
Controller
Cookie processing
Compile the compile Template
Dump input
Import Warehouse receiving (frequently used)
Layout: Set the layout of the current page
Load
Redirect redirection (commonly used)
Session processing (commonly used)
Tag
Trace with track
Vendor import to third-party library (commonly used)
3 Multiple function inputs (17)
File loading
Load_config supports format conversion when loading the configuration file. only the first-level configuration is supported.
Load_ext_file load dynamic extension files (important)
PHP optimization
Require_cache optimized require_once
In_array_case case-insensitive in_array implementation
File_exists_case case-sensitive file existence judgment
To_guid_string generate unique ID numbers based on various PHP variables
Network
Is_ssl determines whether the SSL protocol is used (important)
Send_http_status send HTTP status (important)
Get_client_ip get the client IP address (important)
XML
Xml_encode XML encoding
Data_to_xml data XML encoding
String Processing
Think_filter SQL security filter
Strip_whitespace removes spaces and comments from the code (important)
Parse_name string naming style conversion
Others
Parse_res_name parse the resource address and import the class library file
Array_map_recursive recursive call
Throw_exception custom exception handling (not recommended, replaced by e)
Yaml_parse_file parses the yaml file and returns an array.
Reference
Http://www.cnblogs.com/asplamapie/p/4108400.html

The above describes the full solution of the THinKPHP function library, including some content. I hope my friends who are interested in the PHP Tutorial can help me.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.