PHP TipsIn 2002, I had to convert my website Sev Wide Web from ASP to PHP. While the process was initially painful, it turned out to be a blessing in disguise (no offense, Microsoft) as PHP is one of the more robust, well supported and community based server side languages around. Display currency in correct format
Making your HTML readable when using PHP
Converting ASCII line returns to HTML line breaks
Post form results to same PHP page
Parsing HTML form results
Looping through an associative array
Searching through an array
Displaying filesize in kilobytes
Commenting large sections of code
Single quotes versus double quotes
Starting your php code
Check your server configuration using phpinfo
Long running PHP scripts
Generate current page name
Large sections of HTML in PHP script
Commenting ends of brackets
Using double quotes with variables
Encoding form variables in a URL
Convert HTML into text
Redirect a URL using PHP
Disabling automatic session IDs in URLs
Measuring time to execute PHP script
Protect your subdirectories
Disabling code for local testing
|