PHP image processing tutorial (1/3)

1. Generate a simple image.2. Set the image color.3. Draw a straight line on the image.4. Display text on the image.5. Display Chinese characters in the image.6. Open an existing image.7. Obtain Image attributes.The usage of the 8 function

PHP graphic verification code generation and Ajax verification examples (1/2)

There are 3 files:Authcode. php ----- php file generated for the verification codeAuthcode.html ----- front-end display pageDealauthcode. php ----- processing page submitted by ajax to the background to determine whether the verification code is

Php imagecreatefromgif

Php imagecreatefromgifImagecreatefromgif ($ filename)Imagecreatefromgif () returns an image identifier representing the image obtained from the given file name$ Filename is the GIF image name.View instanceFunction LoadGif ($ imgname){/* Attempt to

Php image Chinese verification code

Php image Chinese verification codeSession_start ();$ Vi = new vCodeImage;$ Vi-> SetImage );Class vCodeImage {Var $ mode; // 1: digit mode; 2: Letter mode; 3: DIGIT/letter mode; others: DIGIT/letter optimized modeVar $ v_num; // Number of

PHP: implement the program code to add watermarks to uploaded images

The program that uses PHP to add a watermark to the uploaded image is to create a graph by determining the file type, copy it to the original graph, fill it with and create a rectangle for writing it to imagestring () or determine the watermark type

Configure and integrate Apache php SQL Tcomcat

System requirements:The hardware can start the operating system.Win2k, winxp, or win2003 operating systemPreparations:List of required software: (this configuration includes the following software versions)1. Apache_2.0.47-win32-x86-no_ssl (apache

Php mailbox sends attachment instance program

Class AttachmentMail {Private $ from = 'Yours @ email.com ';Private $ from_name = 'Your Name ';Private $ reply_to = 'Yours @ email.com ';Private $ to = '';Private $ subject = '';Private $ message = '';Private $ attachment = '';Private $

Guide to sending emails via SMTP using PHP

Php does not provide a ready-made smtp function, but provides a mail () function that is not very flexible. This function requires support on server configuration and does not support smtp verification, it is not recommended because it cannot work

PHP sniffing the real flv file address of the youku video!

This is just to capture the contents of the friend network !!!But it's pretty easy to use!Check the code: The code is as follows:Copy code $ Videourl = 'http: // v.youku.com/v_show/id_xmja5mjq0otq0.html ';Function get_content ($ url, $ data ){If

Detailed description of html string filtering functions in php

A custom function The code is as follows:Copy code Function StripHTML ($ string ){$ Pattern = array ("' 'Si "," ' 'Si "," '] *?> 'Si "," '([rn]) [s] +' "," '& (quot | #34);' I ", "'& (amp | #38);' I", "'& (lt | #60);' I", "'& (gt | #62 ); 'I ","'

PHP calculates the number of years, months, and days of time difference.

The effect is as follows:The code is as follows. It must be noted that: 1. A year is defined as 360 days, and a month is 30 days. 2. In the code, 86400 = 24*60*60, represents the total number of seconds in a day. 3. Both of these time periods must

PHP restarts the router to replace the IP address program

When collecting large volumes of data, the "self-protection" of the other server is often triggered, and access is restricted if the request is too frequent. In this case, the access can be restored after a long period of time (ranging from 10

The CPanel panel uses php to automatically back up website files

  The code is as follows:Copy code // PHP script to allow periodic cPanel backups automatically.// Based on script posted by max. hedroom in cpanel.net forums// This script contains passwords. keep access to this file secure! // ********** The

Php calls ckeditor? How to call ckeditor

PHP calls FCKeditorPut FCKeditor in the website root directoryThe PHP file contains the/FCKeditor/ckeditor/"target =" _ blank "> fckeditor. Php file.Insert the following code where the editor needs to be placed on the webpage to call it: The code

Php curl module collects page instances after simulated logon

My homework today is to get product inventory from a website, but this website needs to be logged on. I used fsockopen to pass the entire header, and it was useless. I had to turn to curl for help.The following describes how to enable the curl

PHP is a simple example of uploading images using AJAx.

In the end, we use the FORM in HTML to implement the upload. All right, now I will write what I know and use it for learning. Of course, this is just my own study notes. If there is something wrong, I hope you can give me some advice.First, let's

Php checks and verifies that the IP address is a valid IP address.

Determine whether the IP address is valid  The code is as follows:Copy code If (filter_var ($ ip, FILTER_VALIDATE_IP) {// it's valid} Else {// it's not valid} Determine whether an IPv4 IP address is valid  The code is as follows:Copy code

PHP converts HTML into text.

chr

The most commonly used php function strip_tags The code is as follows:Copy code $ Mystr = Dozens of lines of HTML code are omitted here.SATO;$ Str = strip_tags ($ mystr );// Here, I have converted my HTML to TXT text. Haha, this function is

Total Pages: 12780 1 .... 3571 3572 3573 3574 3575 .... 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.