Regex tips and tricks
I knew it from the first glance, that regular expressions were very very beautiful. As of today, I feel that I have a pretty good grasp of regular expressions. Pay attention and one day you might be a regex god like me.
I’m sure you all have that buddy that told you that regex is easy and all you need to know is ‘<tag>(.+?)</tag>’. Trust me, that won’t get you very far. I’m gonna start with one of the most common examples, html links aka <a> tags. I’m using PCRE regex (PHP), so you may need to adjust for the regex implementation you are using.
