title: Code Igniter url segment illegal characters replace with '-'
body: <p>In code igniter I need to replace illegal characters of 4th segment with '-', for example </p>
  
  <p><a href="http://example.com/groups/index/26/this-is-a-test" rel="nofollow noreferrer">http://example.com/groups/index/26/this-is-a-test</a> </p>
  
  <p>works fine and </p>
  
  <p><a href="http://example.com/groups/index/26/this-is-a-test" rel="nofollow noreferrer">http://example.com/groups/index/26/this-is-a-test</a>!!! </p>
  
  <p>this not working and show 'The URI you submitted has disallowed characters." error message. I need to replace ! or any other disallowed characters with '-'. Can you please give me a solution for this?</p>