PHP Regular Expressions Tutorial

In this video tutorial we learn the basics of PHP regular expressions. However, knowing even these regex basics will let you match most of online content. Make sure to watch next video, which will be a practical example of using regular expressions to parse out movie information from web site.

Hey guys, I’m now using Patreon to share improved and updated video lesson material. For a small fee you can access all the downloadable files from this lesson (source code, icons & graphics, cheat sheets) and everything else included in the video from the Patreon page. Additionally, you will get access to ALL Clever Techie videos in HD format with no ads. Thank you so much for supporting Clever Techie 🙂

Download this video’s files here:

This download (Patreon unlock) includes:
(PHP Regex cheat sheet, PHP Regex test string)
( You also get access to ALL source code and any downloadable content of ALL Clever Techie videos, as well as access to ALL videos in HD 1080p quality format with all video ads removed! )

“““““““““““““““““““““““““““““““““““““““““““““““ is hosted with SiteGround and recommended by Clever Techie
as #1 web hosting company: ( 60% off ) #1 Hosting Company ( 63% off ) #2 Hosting Company #3 Hosting Company
HostGator ( 60% off ) coupon: CLEVERTECHIE

If you guys decide to sign up with SiteGround or any of the 3 hosts, I would really appreciate if you supported Clever Techie and signed up with my affiliate links that you see here. You get a massive 60% discount, there are no extra costs for you, and you will motivate me to create more videos as well. I could also end up working on Clever Techie full time with enough of your support, if that happens, then I’ll be making about 3 new videos every single week!

Clever Techie’s number one pick for web hosting is SiteGround’s (GrowBig) plan for 12 months. The cost is $71.40 + $15.95 domain registration (with 60% off clever techie affiliate link discount). I really appreciate your support everyone, every subscription counts as motivational fuel for creating more videos 🙂


( Website ) – PHP, JavaScript, WordPress, CSS, and HTML tutorials in video and text format with cool looking graphics and diagrams.

( YouTube Channel )

( Google Plus ) – clever techie video tutorials.

( Facebook )

( Twitter )


"How do I sell my house fast?" Home Buyers • HitHome Solutions LLC • We Buy Houses Des Moines Iowa says:

Informative. Really like your tutorials.

blue bird says:

vertical bar

TOA Hamidi says:

thanks for the video bro
||||| this character is PIPE LINE but in regex is OR

JCL Trading Company says:

Awesome tutorial ..

Nathan Scherneck says:

Pipe character

Naila Kanwal says:

Really useful. Thank you.

Oren Rot says:

Where is the next video ?

Patrick Gassenbauer says:

Great video, thank you!! Since I am not a programmer but have used RegEx in Ms Word: what common programs support RegEx?

Bikos133 says:

Hello! The description links appear to be broken! Can you check em? Thanks! Great Tutorial and pretty website!

Sergii Pud says:

Thank you for this great video!
Helped a lot with understanding.

Medoo says:

Guys, how to match for Non English Unicode characters ?

Ndalama Cassius Maluleke says:

This deserves more likes and more views.
Reg Expressions can be a pain to beginners and stack overflow cant explain like you do.
Awesome man.

Clean and understandable thanks for the effort. I loved it.


awesome tutorial in no time I had the basics of regex thanks Clever Techie

Michael Taylor says:

Thanks for the cheat sheet!

Nazmi Mohamad says:

Thanks for the cheat sheet. & the video of course.

Alex says:

Nice cheat sheet background image, is it a mirror of your room with your cat? 🙂

kok hong hean says:

very useful. Thank you.

Oren Rot says:

well explained !!!

ahtesh maxx says:

how did you learn php & web development

Bikos133 says:

Test String:

abcdefghijklmnopqrstuvwxyz ABCDEFGHIJKLMNOPQRSTUVWXYZ
0123456789 _+-.,!@#$%^&*();/|<>“‘
Hello World!
12345 -98.7 3.131 .6180 9,000 +42
555.123.4567 +1-(800)-555-2468

 Write a comment


Do you like our videos?
Do you want to see more like that?

Please click below to support us on Facebook!