Okay,
I am creating dynamic links for an application based on what the user enters for the title of the page.
e.g. ; "My Home Page" should look like this "my-home-page" .
Easy enough... however, I ran into a little issue.
If the user adds a SPACE after the last word the link now looks like "my-home-page-", with the hyphen at the end.
What's the best way to prevent this?
Thx.