Unlock your potential with a Pro Membership
Here is where you propel your career forward. Come join us today. Learn more.
Explaining the “String Starts With” Strategy
Lab: Doing More With PHP String Processing
Video Runtime: 13:35
It occurred to me that there were strategies I did in the last episode which need further explanation such as:
- How
mb_substr
works - 05:21 Why did I use
mb_substr
instead ofmb_strpos
- 08:40 Refactoring to make the code more clear
- 09:21 How does
function_exists()
work and why/when do you use it - 11:01 Should you use namespacing or
function_exists()
for helper utilities
In this episode, let’s dive into each of these strategies to help you figure out the best approach for you.
If you listen carefully, you can hear the 1s and 0s flowing in your computer.
Episodes
Total Lab Runtime: 01:58:54
- 1 Lab Introductionfree 03:24
- 2 Checking if String Starts With a Character or Substringpro 13:43
- 3 Explaining the "String Starts With" Strategypro 13:35
- 4 Check if String Ends With a Character or Substring - Part 1pro 15:11
- 5 Check if String Ends With a Character or Substring - Part 2pro 12:52
- 6 Has Substringpro 04:27
- 7 Truncate by Characterspro 17:18
- 8 Truncate by Wordspro 14:35
- 9 Converting to Lowercasepro 07:58
- 10 Converting to Uppercasepro 01:30
- 11 Splitting a String into An Arraypro 07:17
- 12 Joining Array Elements into a Stringpro 03:43
- 13 Wrap it Uppro 03:21