Some Useful PHP functions and features

Some useful but lesser known PHP functions

In this article I am going to cover up some lesser known but Useful PHP Functions which offers some great functionalities. Not all but many of these are usually re coded. Here’s the list of such Useful PHP Functions and features that I have compiled over time. These might also come in handy for you in your day to day coding.

  1. Converting Newline to Break – nltobr
  2. Placeholder replacement – strtr
  3. Die
  4. Parsing Url – parse_url
  5. glob
  6. Magic Constants
  7. str_word_count()
  8. Serialization – json_encode & json_decode

Continue reading