Jeffery Vaska has “10 Tips That Every PHP Newbie Should Know“, a nice collection of tips for a newbie venturing into PHP. Tips like MySQL Connection Class, Dealing with Magic Quotes etc can be found there.
Feb
18
10 PHP Tips for noobs
Jan
26
PHP function for Javascript redirect
The following code is basically JS, but has been made into a PHP function so that it could be invoked with different parameters as per our needs.
<?php
function js_redirect($url, $seconds=5) {
echo "<script language=\"JavaScript\">\n";
echo "<!-- hide code from displaying on browsers with JS turned off\n\n";
echo "function redirect() {\n";
echo "window.location = \"" . $url . "\";\n";
echo "}\n\n";
echo "timer = setTimeout('redirect()', '" . ($seconds*1000) . "');\n\n";
echo "-->\n";
echo "</script>\n";
return true;
}
js_redirect(http://blogulate.com,1); //Redirects to blogulate.com in 1 second.
?>
Eg Usage :
js_redirect(http://google.com,5); //Redirects to Google after 5 seconds.
Jan
26
Spellify : automatic input field spell check

Spellify automatically checks for spelling errors on user entered text in input text fields. Spellify is powered by the Googleâ„¢ spell checker. You can see a demo at te homepage and also download the latest version there. Spellify not only works for text fields, but also on text areas.

