Common php classes

Chart Library The following class library allows you to easily create complex charts and images. Of course, they need the support of the GD library. PChart-A database that allows you to create statistical charts. Libchart-This is also a simple

Simple code for php to read html and extract strings

Copy codeThe Code is as follows:$ Title = 'foot home ';$ Hello = 'jb51. net! ';$ File = file_get_contents ('HTTP: // www.baidu.com ');$ File = iconv ("gbk // IGNORE", "UTF-8", $ file );// Echo $ file;Echo strpos ($ file, ' ');Echo substr ($ file,

5 Image Processing for learning and practicing Ajax + PHP

First:  Create a Form in Sample6_1.php:Copy codeThe Code is as follows:// Display the upload status and Image // Enctype needs to be defined for file uploading. set target to uploadframe for image display.Enctype = "multipart/form-data" target =

Common functions in PHP collection programs

Copy codeThe Code is as follows:// Obtain the current Script URLFunction get_php_url (){If (! Empty ($ _ SERVER ["REQUEST_URI"]){$ ScriptName = $ _ SERVER ["REQUEST_URI"];$ Nowurl = $ scriptName;}Else{$ ScriptName = $ _ SERVER ["PHP_SELF"];If (empty

PHP CKEditor Image Upload implementation code

It took me one afternoon to write a script code for processing uploaded files using a PHP script. I didn't do more security processing and hoped it would be useful to everyone.First, add the following code to your config. js file:Copy codeThe Code

Super simple php + mysql message source code

3 files in totalIncDB. php database connectionIndex. php HomepageInsetToDB. php database operationsCreate a table in the database lguestbookCopy codeThe Code is as follows:Create table 'intd '('Id' int (11) not null auto_increment,'Name' varchar (255

PHP object-oriented implementation code

1. Simple Object CreationCopy codeThe Code is as follows:// Class scope final: this field will be blocked from being overwritten by subclass// The scope of the method abstract: declared in the parent class, implemented in the subclass// Definition

PHP image processing class implementation code

Copy codeThe Code is as follows:/*** Author: yagas* Email: yagas60@21cn.com*/Class Image{/** Class protection variable */Protected $ th_width = 100;Protected $ th_height = 50;Protected $ quality = 85; // Image qualityProtected $ transparent = 50; //

Php Remote Vulnerability Analysis page 1/6

Almost all cgi programs have such bugs, but the specific expressions are different.I. involved dangerous functions (include (), require () and include_once (), require_once ()〕Include () & require () Statement: includes and runs the specified

Php Folder deletion and php cache clearing

Copy codeThe Code is as follows:Header ('content-type: text/html; charset = UTF-8 ');Function delFile ($ fpath ){$ Filesize = array ();$ Filepath = iconv ('gb2312', 'utf-8', $ fpath );If (is_dir ($ fpath )){If ($ dh = opendir ($ fpath )){While ($

Differences between $ _ SERVER [PHP_SELF] and $ _ SERVER [SCRIPT_NAME] in php

"PHP_SELF"The file name of the script being executed, which is related to document root. For example, using $ _ SERVER ['php _ SELF '] in a script with a URL address of http://www.jb51.net/test.php/foo.bar will get the result of/test. PHP/foo. bar.

Frename PHP flexible File naming function frename

To solve this problem, some methods are to rename the new file with a timestamp, and some are to increment the serial number. To solve the problem, I recently compiled a frename function, you can use custom rules to obtain the new names of uploaded

PHP multi-dimensional array sorting implementation code

Array_multisort(PHP 4, PHP 5)Array_multisort -- sorts multiple arrays or multi-dimensional arrays.DescriptionBool array_multisort (array ar1 [, mixed arg [, mixed... [, array...])If the call succeeds, TRUE is returned. If the call fails, FALSE is

Php global variable range analysis

Copy codeThe Code is as follows:$ A = 1;Include 'B. inc ';?> The variable $ a will take effect in the included file B. inc. However, in user-defined functions, a local function range will be introduced. By default, any variable used in a function is

Seven advantages of PHP

Although ASP is a good technology, in the long term, I believe that PHP will provide technical support in the future.DomainThere will be extraordinary performance. I think there are seven reasons why PHP is better than ASP:  1. speed, speed, and

Php adodb connects to mssql to solve the garbled Problem

Zhou haihan/WenADO can use statements such as new COM ("ADODB. Connection", NULL, CP_UTF8) // 65001 to achieve correct conversion. However, ADO's support for php lacks documentation. There is an open-source adodb with rich documentation.For

PhpMyAdmin installation and problem summary

1/The mcrypt extension cannot be loaded. Check the PHP configuration;2. The configuration file now requires a top secret phrase password (blowfish_secret );3/#2003-the server does not respond.The latest phpMyAdmin version has been updated to 2.11.5.1

PHP string tips

Note the use of escape characters \, \ ", \ $Use octal or hexadecimal characters to represent \ xf6Echo "H \ xf6me"; // check whether such text encoding is supported--------------------- Output result ----------------------------------------H e------

AspNetAjaxPager and Asp. Net General Ajax pagination controls without refreshing, support for Symmetric Multi-Data Binding

This control can be applied to the GridView, Repeater, DataGrid, DataList... almost all.. net data binding controls are paginated, and all data binding components can use stored procedures or SQL statements directly. This control has no interference!

Explanation of PHP dangerous functions

You can use-disable-cli during compilation. Once PHP in CLI mode is compiled and generated, it may be attacked.Use this program to create a WEB Shell backdoor process or execute arbitrary code through PHP!Phpinfo ()Function Description: outputs

Total Pages: 12780 1 .... 5799 5800 5801 5802 5803 .... 12780 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.