Fix normalize_uri() function

This will make sure all the double slashes are gone.  Also, the
function description is updated to clarify its purpose.
Fix trailing slash problem

These modules require the target URI to be a directory path. So
if you remove the trailing slash, the web server might return a
301 or 404 instead of 200.

Related to: [SeeRM: #7727]
Fix the forgotten path()
Merge pull request #1397 from wchen-r7/target_uri_fix

normalize_uri fixes (double slashes and trailing slash)