Take a string such as:
In C#: How do I add "Quotes" around string in a comma delimited list of strings?
and convert it to:
in-c-how-do-i-add-quotes-around-string-in-a-comma-delimited-list-of-strings
Requirements:
- Separate each word by a dash and remove all punctuation (taking into account not all words are separated by spaces.)
- Function takes in a max length, and gets all tokens below that max length. Example:
ToSeoFriendly("hello world hello world", 14)
returns"hello-world"
- All words are converted to lower case.
On a separate note, should there be a minimum length?
In a dynamic URL, these IDs are passed via the query string to a script that ... as the delimiting character because most search engines treat the dash as a ... NET: A Developer's Guide to SEO also covers these three additional methods search engine optimization
C#
Solution in shell:
Solution in Perl:
done.
In python, (if django is installed, even if you are using another framework.)
A better version: