title: PHP Detect how many URLS in the string
body: <p>I'm implementing a contact form for a website, and I'd like to avoid using a captcha because I believe it has a negative effect on user experience.</p>
  
  <p>Instead, I've decided to trial detecting the number of URLs that have been submitted with the message.</p>
  
  <p>I am retrieving the message as a string from the $_POST submission.  I know inbuilt PHP functions such as stristr() can give me confirmation that a substring exists within the message but what I'd like is the count.</p>
  
  <p>Also, in terms of spam detection, would a match on something like "&lt;/a&gt;" be appropriate?</p>
  
  <p>Cheers. </p>