resource mysql_pconnect ([ string $server = ini_get(“mysql.default_host”) [, string $username = ini_get(“mysql.default_user”) [, string $password = ini_get(“mysql.default_password”) [, int $client_flags ]]]] ) Establishes a persistent connection to a MySQL server. mysql_pconnect() acts very much like mysql_connect() with two major differences. First, when connecting, the function would first try to find a (persistent) link that’s already …
Category Archives: Programming
WP Increasing memory allocated to PHP
Also released with Version 2.5, the WP_MEMORY_LIMIT option allows you to specify the maximum amount of memory that can be consumed by PHP. This setting may be necessary in the event you receive a message such as “Allowed memory size of xxxxxx bytes exhausted”. This setting increases PHP Memory only for WordPress, not other applications. …
ORDER BY using specific order from IN
You can use FIND_IN_SET to do that: SELECT * FROM tablename WHERE id IN (1,10,8,5) ORDER BY FIND_IN_SET(id, ‘1,10,8,5’)
ISO 3166-1 Languages codes
http://en.wikipedia.org/wiki/ISO_3166-1 Officially assigned code elements The following is a complete ISO 3166-1 encoding list of the countries which are assigned official codes. It is listed in alphabetical order by the English short country names officially used by the ISO 3166/MA, which are all from United Nations sources.[7] For example, Macedonia is listed as “Macedonia, the …
ISO 639 Language Codes (Obsolete)
ISO 639 Language Codes (Obsolete) NOTE: This page is obsolete! Please see the Codes for the representation of names of languages maintained by the Library of Congress or the W3C Internationalization Activity for further and up-to-date information about language codes.
php DATE_RFC822
<?php echo(“Result with date():<br />”); echo(date(“l”) . “<br />”); echo(date(“l dS \of F Y h:i:s A”) . “<br />”); echo(“Oct 3,1975 was on a “.date(“l”, mktime(0,0,0,10,3,1975)).”<br />”); echo(date(DATE_RFC822) . “<br />”); echo(date(DATE_ATOM,mktime(0,0,0,10,3,1975)) . “<br /><br />”); echo(“Result with gmdate():<br />”); echo(gmdate(“l”) . “<br />”); echo(gmdate(“l dS \of F Y h:i:s A”) . “<br />”); echo(“Oct …