jjacquay712 Posted May 7, 2009 Share Posted May 7, 2009 Hey guys, i suck at regex and was wondering if you could help me out. All i need is a simple url finder that matches the url that starts with http:// or https:// and stops when it finds a space. I searched the entire internets and couldent find anything like this. Thanks for the help, John Quote Link to comment https://forums.phpfreaks.com/topic/157173-solved-simple-regex-help/ Share on other sites More sharing options...
nrg_alpha Posted May 7, 2009 Share Posted May 7, 2009 #^https?://[^\s]+# With regards to searching the internet for these kind of solutions, you might be better off learning regex itself instead. That way, you will be able to forumlate your own regex solutions instead of fishing for solutions (which may not be exactly what you are looking for). You can have a look at these links: regex tutorial webblogtoolscollection mastering regular expressions php freaks resources php freaks tutorials Quote Link to comment https://forums.phpfreaks.com/topic/157173-solved-simple-regex-help/#findComment-828197 Share on other sites More sharing options...
jjacquay712 Posted May 7, 2009 Author Share Posted May 7, 2009 thanks for the help, i have tried to learn regex many times but i cant seem to remember the sytax. Quote Link to comment https://forums.phpfreaks.com/topic/157173-solved-simple-regex-help/#findComment-828202 Share on other sites More sharing options...
nrg_alpha Posted May 7, 2009 Share Posted May 7, 2009 thanks for the help, i have tried to learn regex many times but i cant seem to remember the syntax. Repetition is the mother of all skill. It's like anything else.. it takes time and constant exposure. Regex itself is not hard per say.. it's more or less 'the rules of engagement'. But once you start to get on the ball, you'll see that it's not all that bad. Just have to keep reading up on it, and trying things out. Otherwise, you're doomed to always asking people for solutions... and what happens if no one helps out? Kind of like 'give a man a fish, and he can eat for a day.. teach a man to fish, and he can eat for a lifetime.' sort of thing. By learning it, you don't become reliant on others. Just takes some time and effort (which is well worth it IMO). Quote Link to comment https://forums.phpfreaks.com/topic/157173-solved-simple-regex-help/#findComment-828204 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.