Change the configuration modification method of Apache Port _php Tutorial

How to change the Apache port: Locate the httpd.conf file under the Conf directory in the Apache installation directory. Open it, find "Listen", followed by the Listen number is the port number, the default state is "Listen 80". As mentioned in the

The function of removing HTML tags from a string under PHP _php tutorial

When a guest comments and posts, we do not want visitors to use the HTML tag in the message and post, so when the guest submits the message and the post, I have to delete the HTML tag, the following function is to implement this function function

PHP Ajax garbled _php Tutorial

While Ajax supports UTF8 OK, first add a header to the PHP page ("content-type:text/html; Charset=utf-8″); The code that tells the page this implementation is UTF-8 Then the content to be output with $test = Iconv (' GBK ', ' utf-8′, $test); turn

PHP 8 Common Tips for developing _php tutorials

The PHP batch gets the value of the checkbox 1. Naming 2. Use When the plan is part of a SQL instruction: if the field that participates in the control is numeric, the if (! empty ($_post[' checkbox '))) { $expr = Join (",", $_post[' checkbox

PHP filtering dangerous HTML code _php tutorial

Here is the program code: Copy CodeThe code is as follows: function uhtml ($STR) { $farr = Array ( "/\s+/",//filter Extra blanks Filter

PHP MySQL Programming advanced tips _php Tutorial

The author has made the following attempts. $data _time= "1998-12-31 23:59:59"; $connect _id=mysql_connect (' localhost '); $query _id=mysql_query ("Select Date_add (' $data _time ', INTERVAL 1 year)", $connect _id); $data _time=mysql_result

PHP Live display Output _php tutorial

Real-time display output Ob_end_flush ();//Close cache echo str_repeat ("", 256); You need to send 256 bytes before IE Set_time_limit (0); for ($i =0; $i echo "Now Index is:". $i. " "; Flush (); Sleep (1); }

PHP Integrated FCK function Code _php Tutorial

Copy CodeThe code is as follows: Defines a function to call FCKeditor function Call_fck ($input _name, $input _value, $w = ' 780 ', $h = ' 580 ') { Include_once ' fckeditor/fckeditor.php '; $fcked = new FCKeditor ($input _name); $fcked->basepath = '

PHP formatting tool beautify PHP small bug_php tutorial

Beautify php, good php formatting tools http://www.bierkandt.org/beautify/ Http://pear.php.net/package/PHP_Beautifier/download Recently in the group to new people, their code is not too standard time to see really uncomfortable This tool is very

PHP day before or after date _php tutorial

Copy CodeThe code is as follows: Date_default_timezone_set (' PRC '); Default time zone echo "Today:", Date ("Y-m-d", Time ()), " "; echo "Today:", Date ("Y-m-d", Strtotime ("June 2008")), " "; echo "Yesterday:", Date ("Y-m-d", Strtotime ("-1 Day"))

Smarty reserved variable problem _php Tutorial

The following are examples of accessing page request variables such as get,post,cookies,server,enviroment and session variables. For example {$smarty. server.server_name} Gets the server variable, {$smarty. Env.path} Gets the system environment

PHP Common function Tips _php tutorial

1. Return the file name extension function GetFormat ($file) { $ext =STRRCHR ($file, "."); $format =strtolower ($ext); return $format; } 2. Formatting variables $num = 1; printf ("%04d", $num); ?> 3.php REDIRECT Web page For example Redirect to

PHP Injection Point Construction Code _php tutorial

Save the following as Test.asp Copy CodeThe code is as follows: $mysql _server_name = "localhost"; $mysql _username = "root"; $mysql _password = "password"; $mysql _database = "PHPZR"; //?? ݿ?? $conn =mysql_connect ($mysql _server_name, $mysql

PHP mysql index problem _php tutorial

Obviously this is a problem that all friends who use MySQL will encounter. Recall the original MySQL GUI tool that was mentioned in configuring the environment, yes, that's it, you can find it in http://www.mysql.com. Because Sunec is only a

User's original PHP template class Code _php tutorial

Copy CodeThe code is as follows: Class Lightpage_template { var $Tpl _header; var $Tpl _footer; var $Tpl _parsing; var $Tpl _template; var $Tpl _dirname; var $Tpl _parse_string; var $Tpl _parse_array; var $Tpl _result; function __construct () {

PHP via post or get to pass the value _php tutorial

Careful friends must have noticed that the last time a PHP page passed the parameters of the topic there is a program: I used the post for the method, but why not use the Get method? Let's take a look at the difference between post and

PHP page passing parameter Instance code _php tutorial

First, we show you how to query data by table only son values. Task Objective: Enter the department name in the form and inquire the personnel information of the corresponding department. Create the search.php file first. The first step is to

Solve the problem of MySQL Chinese output becoming question mark _php Tutorial

So I joined in the program: mysql_query ("SET NAMES GB2312"); the problem is solved. is mainly a coding problem. Note that the insertion position of this code should be inserted before the code that displays the data, otherwise it will be

Simple example Ajax with PHP code implementation login effect Code _php tutorial

HTML section: function Postrequest (strURL) { var xmlHttp; if (window. XMLHttpRequest) {//For Mozilla, Safari, ... var xmlHttp = new XMLHttpRequest (); } else if (window. ActiveXObject) {//For Internet Explorer var xmlHttp = new

PHP code for generating random numbers or strings _php tutorial

$len represents the length, the code is as follows: Copy CodeThe code is as follows: /** * Generate random string * * generates a random string of a specified length and returns it to the user * * @access Public * @param int $len The number of bits

Total Pages: 5208 1 .... 4828 4829 4830 4831 4832 .... 5208 Go to: GO

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.