1, the basic principles of data filtering of PHP submission
1 Submit variables into the database, we must use Addslashes () to filter, like our injection problem, a addslashes () is done. In fact, when it comes to variable values, the Intval ()
The main security measures are in the following two areas.
1, to prevent the attacker to obtain the user's session ID.
There is also a more covert approach, where an attacker redirects a user on a hacked site to another site through a Web site
1, delete HTML annotation;2, delete script, link, object, embed, IFRAME, frame, frameset and have on the beginning, including Web page effects: [^;] or expression the label of the attribute;3, delete the annotations in the CSS tutorial (prevent this
MCrypt Simple Introduction
PHP programmers in writing code programs, in addition to ensure the high performance of the code, but also is very important, that is, the security of the program. In addition to the several encryption functions, PHP has
For most cryptographic cryptography, we can use MD5, SHA1 and other methods. Can effectively prevent data disclosure, but these methods apply only to data encryption that does not need to be restored.
For information that needs to be restored, a
Delete the element inside#创建数组 (0,o,2,z,1,i not)$arr =array_merge (Range (0,9), Range (' A ', ' Z '), Range (' A ', ' Z ')); #原数组$arr 2=array ("0", "1", "2", "Z", "z", "I", "I", "O", "O"); #包含要删除字符的数组#进行删除foreach ($arr as $k 1=> $v 1) {foreach ($arr
ThinkPhp source code reading experience, thinkphp source code experience
I may see more header functions in php, as long as they are used for jump. When reading the TP source code today, we found that the header function has a third parameter. If
Use Nginx in windows to replace apache as the server, nginxapache
To be honest, using Nginx in windows is a little inconvenient, but due to project requirements, you don't want to change the system (although you can have a virtual machine), you can
PHP + Mysql (source code) and mysql source code
The source code of a self-written comment system is shared with you, including emotices and comment mechanisms. The user name is random.
Comment on an article
Function subcomment () {$ data ['uid'] =
Php built-in supported labels and attributes, php built-in label attributes
The built-in supported labels and attributes are listed as follows:
Tag Name
Function
Include attributes
Include
Contains external template files (
Methods for converting php variables and arrays (extract and compact), extractcompact
This article describes how to convert php variables and arrays. We will share this with you for your reference. The details are as follows:
In php, we can use
Introduction to PHP database interfaces and technologies
1. Which databases are supported by php (which database interfaces are available)
Adabas D, InterBase, PostgreSQL, dBase, Front base, SQLite, Empress, mSQL, Solid, FilePro (read-only), Direct
Analysis of urlencode () and urldecode () URL encoding functions in php [transfer], urlencodeurldecode
URLEncode: a pointer to the Chinese characters in the url of a Web page. The most common method is to enter Chinese Characters in search engines
Develop and generate instances with two-dimensional codes and parameter instances
How to generate a QR code with Parameters
In the "Account Management" area of the public account platform developer, a function is to "generate a QR code with
Php public platform interaction and interface explanation, php public platform explanation
This article is divided into three parts for your introduction. The specific content is as follows:
1. Interaction between users, servers, and backend servers
ThinkPHP implements Multi-field fuzzy match query, thinkphp Field
The example in this article describes how thinkPHP implements Multi-field fuzzy match query. We will share this with you for your reference. The details are as follows:
Introduction:
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