title: PHP preg_match any text in a url after a specific word already in the url
body: <p>I am using a preg_match to insert a joomla module into a template in any url that contains the word 'category'.</p>
  
  <p>An example url is: xyz.com/page/category/</p>
  
  <p>The code I have that works is:</p>
  
  <pre><code>if(preg_match('/category/',$_SERVER['REQUEST_URI']))
  echo '&lt;jdoc:include type="modules" name="form" style="xhtml" /&gt;';
  </code></pre>
  
  <p>I have realised that I need to insert the module into pages that only appear in the url after 'category'.</p>
  
  <p>eg: xyz.com/page/category/123-page-after-category</p>
  
  <p>I have tried the following but it doesn't work:</p>
  
  <pre><code>if(preg_match('/category/?.*',$_SERVER['REQUEST_URI']))
  </code></pre>