How To Enable PEAR Packages In Plesk

By default, Plesk will install PEAR and a lot of packages, but block any access to it for PHP scripts. It’s fairly easy to enable this, though.

First of all, you need to edit the VirtualHost of whatever domain you’re trying to enable this for. Seeing as Plesk would just overwrite your httpd.conf with the next change you make in the controlpanel, you need to use a seperate vhost.conf file.

The file to edit can be found in the following directory:

/var/www/vhosts/<my domain>/conf/vhost.conf Continue reading "How To Enable PEAR Packages In Plesk"

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 former Yugoslav Republic of” due to the Macedonia naming dispute, and Taiwan is listed as “Taiwan, Province of China” due to its political status within the UN.

Click on the button in the header to sort each column. For more information on each country and the assignment of its code elements, see the corresponding table in ISO 3166-1 alpha-2. Continue reading “ISO 3166-1 Languages 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 3,1975 was on a “.gmdate(“l”, mktime(0,0,0,10,3,1975)).”<br />”);
echo(gmdate(DATE_RFC822) . “<br />”);
echo(gmdate(DATE_ATOM,mktime(0,0,0,10,3,1975)) . “<br />”);
?>

thanks http://www.w3schools.com/PHP/func_date_date.asp