0

Possible Duplicates:
Best methods to parse HTML with PHP
PHP Linkify Links In Content

I want to parse html to find links, but i want not only to find links like http://www.aaa.com, but also links like www.apple.com or just apple.com. I dont wand to find a tags. I want to find links in user input text.

Community
  • 1
  • 1
Taras Lukavyi
  • 1,339
  • 2
  • 14
  • 29

1 Answers1

1

Read here in preg_match Manual Page.

The expression I would use:

/https?:\/?\/?[^\ ]+/i