best way to escape and create a slug
Posted
by Mac Taylor
on Stack Overflow
See other posts from Stack Overflow
or by Mac Taylor
Published on 2010-04-05T19:22:44Z
Indexed on
2010/04/05
19:33 UTC
Read the original article
Hit count: 400
hey guys
im somehow confused in using proper functions to escape and create a slug
i used this :
$slug_title = mysql_real_escape_string()($mtitle);
but someone told me not to use it and use urlencode()
which one is better for slugs and security
as i can see in SO , it inserts - between words :
http://stackoverflow.com/questions/941270/validating-a-slug-in-django
thanx in advanced
© Stack Overflow or respective owner