After reading this tutorial, you should have a good handle on the different string functions available to you in PHP. You should be able to decide when each function is appropriate to use and be able to perform a variety of tasks using a combination of the presented functions.
One thing to keep in mind while developing PHP applications is that the string functions presented here will normally be your most efficient method, performance wise, of solving a task if they provide the functionality needed. Obviously, if there is a built in function to PHP it will out perform a user defined function built around these functions. But, the important thing to realize is that the functions from this tutorial will consistently out perform their regular expression counterparts. Because of this, you should try and utilize string functions where possible. There are many situations where it is not possible to reasonably solve a problem with these functions. In those cases, use the more appropriate function.
| DISCLAIMER: The content provided in this article is not warranted or guaranteed by Developer Shed, Inc. The content provided is intended for entertainment and/or educational purposes in order to introduce to the reader key ideas, concepts, and/or product reviews. As such it is incumbent upon the reader to employ real-world tactics for security and implementation of best practices. We are not liable for any negative consequences that may result from implementing any information covered in our articles or tutorials. If this is a hardware review, it is not recommended to open and/or modify your hardware. |