CENTOS7 System Library default is no nginx RPM package, so we need to update the next RPM dependent library
(1) Install Nginx using Yum to include Nginx Library, install Nginx Library
#rpm-UVH
A good framework is definitely inseparable from the use of the cache, on the contrary, a non-cached framework is certainly not a good frame, it seems to be a meaning, regardless, we first look at how to use the cache in Yii2.
It's time for us to do
The value of the register_globals can be set to: On or off, and we'll give you a piece of code to describe the differences individually.
Code:
Copy the Code code as follows:
When the next program receives the Register_globals=off, it should use
Laravel PHP Artisan Error
When the following error occurs when you run any command from PHP artisan:
[RuntimeException] Error Output: PHP Catchable fatal error: Argument 2 passed to Illuminate\R outing\UrlGenerator::__construct() must be an
NL2BR ();/\ n to
Addslashes (); Stripslashes ();//Escape special characters when working on a database
Chop ();//Remove the right space of the string
Trim ();//Remove all spaces in the string
LTrim ();//Remove the left space of the
Problem: Open a written php file with a browser, and then find that Chinese characters appear as question marks, the site is not displayed properly
Cause: Garbled problem because the database, browser and PHP files are encoded differently
Workaround:
Now everyone has countless account password, inevitably can't remember; The principle is through the mail server POP service to complete authentication, can also use SMTP, and add SSL has increased security; Avoid setting the user/password trouble,
Project Structure:
Operating effect:
conn.php
Copy the Code code as follows:
$conn = @ mysql_connect ("localhost", "root", "") or Die ("Database link error");mysql_select_db ("form", $conn);mysql_query ("Set names ' GBK '"); Use GBK Chinese
An error occurred during the installation of the LDAP extension package;
Configure:error:Cannot Find Ldap.h
This is a missing configuration file, but using the Yum command to install this configuration,
Use first if you do not know the name of
1. Download Wampserver Installation
2. Open localhost in the browser, display the Welcome page, the installation is successful
To modify the root directory1. Change two locations in Apache configuration file3. Last reboot Wampserver
Modify
/** * Cache Static Page class */class htmlcache{ /** * Open Cache * $filename cache full path * $time cache time Unit is seconds, default 7,200 seconds */ Public Function Cache_start ($filename, $time =7200) { $cachefile
Share a function that is actually in use:
Copy the Code code as follows:
/* More stable than file_get_contents! The $timeout is the time-out, in seconds, and the default is 1s. */function curl_get_contents ($url, $timeout =1) {$curlHandle =
/*** Obtain the MAC address source of the network card; currently support Win/linux system * get the physical (MAC) address of the machine card */ classgetmacaddr{var$return _array=Array();//Returns an array of strings with MAC addressesvar$mac
The following points summarize the characteristics and advantages of choosing PHP as a website development language.
1. Open source
PHP is an open source language (free to download, free to use, free to share), and no developer or user is charged
1, this is a thumbnail class library
It is an open source image Thumbnail class library, can complete a variety of complex image thumbnail generation and reality, very convenient to use.
2. How to use
Here is a simple and practical explanation,
* * Copyright (c) 2016, School of Computer and Control engineering, Yantai University * All rights reserved. * File name: Text.cpp * Author: Changxuan * Public Number: Worldhello * Completion Date: May 18, 2016 * version number: V1.0 * Problem
This example in the WAP station project needs to do an AJAX multi-image upload, combined with JS plugin made a, for your reference, the specific content as follows
/* Ajax Upload image */var num = 0; Click Delete Picture function OnDelete (num)
First, install Zend Studio
The installation process is relatively simple and is not outlined.
Ii. Modification of php.ini file
Under the UPUPW folder directory, locate the \upupw\php5\php.ini configuration file and find the following keyword
You can define a calling method on the page, as follows:
Copy the Code code as follows:
function GetData () {$.getjson ("http://123.123.123.123/?callback=?",{"M": "Data",//Specify PHP file name"Act": "GetData",//Specify the method in PHP file"Name":
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