


Simple trick to extract substrings from a string
Sometimes we need to extract a substring from a long string. PHP provides a powerful function called substr() that allows you to extract a substring from a long string. It takes three parameters: the string to be worked on, a starting index and an optional length. The starting index can be specified as either a [...]
Quick drop down list with 250 countries
Country lists is one of the most common elements in a web form. For example- you have a registration form, but no country drop down list in it ! So, it looks like an incomplete form and there should be a country name drop-down to get the user country name. You may need to write [...]
Quickway to find max and min value from an array
There are various ways to find max and min value from an array. However, today I am going to show a Quick way to find the max and min value from an array. Hope you like it. First we take a list of numbers in an array. Then sort array list using PHP sort() function. [...]