Check if a String represents a Valid Timezone with PHP
Sometimes you want to check if a string represents a valid timezone. Using PHP versions greater than 5.2, timezone_identifiers_list() could be a solution. Take a look in the following function:…
Sometimes you want to check if a string represents a valid timezone. Using PHP versions greater than 5.2, timezone_identifiers_list() could be a solution. Take a look in the following function:…
Browser (and browser version) detection is an "all time classic" development requirement. jQuery.browser WAS an excellent solution, but it was removed in jQuery 1.9. Actually, it would be better to…
What is the JavaScript Equivalent of PHP print_r() function? In other words, how you can "print" a javascript object in a way that's readable by humans? Code You could use…
PHP shuffle randomizes (shuffles) the order of the elements in an array. You may use this function to create a simple banner rotator. Define your banners Create $banners array with…
Sometimes, you want to create a list of available time zones to prompt your user to select his/her time zone. Fortunately, PHP offers timezone_identifiers_list (PHP 5 >= 5.2.0). You can…