Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Fixed #700 -- urlify.js now uses hyphens instead of underscores

git-svn-id: http://code.djangoproject.com/svn/django/trunk@1017 bcc190cf-cafb-0310-a4f2-bffc1f526a37
  • Loading branch information...
commit c6f375fd1124562cde131c9785e7d7f6771ef7f2 1 parent e7c870c
@adrianholovaty adrianholovaty authored
Showing with 1 addition and 1 deletion.
  1. +1 −1  django/contrib/admin/media/js/urlify.js
View
2  django/contrib/admin/media/js/urlify.js
@@ -9,7 +9,7 @@ function URLify(s, num_chars) {
s = s.replace(r, '');
s = s.replace(/[^\w\s-]/g, ''); // remove unneeded chars
s = s.replace(/^\s+|\s+$/g, ''); // trim leading/trailing spaces
- s = s.replace(/\s+/g, '_'); // convert spaces to underscores
+ s = s.replace(/\s+/g, '-'); // convert spaces to hyphens
s = s.toLowerCase(); // convert to lowercase
return s.substring(0, num_chars);// trim to first num_chars chars
}
Please sign in to comment.
Something went wrong with that request. Please try again.