Loading AUTHORS +1 −0 Original line number Diff line number Diff line Loading @@ -106,6 +106,7 @@ answer newbie questions, and generally made Django that much better: Swaroop C H <http://www.swaroopch.info> Aaron Swartz <http://www.aaronsw.com/> Tom Tobin Tom Insam Joe Topjian <http://joe.terrarum.net/geek/code/python/django/> Malcolm Tredinnick Amit Upadhyay Loading django/contrib/admin/media/js/urlify.js +2 −2 Original line number Diff line number Diff line Loading @@ -9,7 +9,7 @@ function URLify(s, num_chars) { s = s.replace(r, ''); s = s.replace(/[^-A-Z0-9\s]/gi, ''); // remove unneeded chars s = s.replace(/^\s+|\s+$/g, ''); // trim leading/trailing spaces s = s.replace(/\s+/g, '-'); // convert spaces to hyphens 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 } django/template/defaultfilters.py +1 −1 Original line number Diff line number Diff line Loading @@ -66,7 +66,7 @@ def make_list(value): def slugify(value): "Converts to lowercase, removes non-alpha chars and converts spaces to hyphens" value = re.sub('[^\w\s-]', '', value).strip().lower() return re.sub('\s+', '-', value) return re.sub('[-\s]+', '-', value) def stringformat(value, arg): """ Loading Loading
AUTHORS +1 −0 Original line number Diff line number Diff line Loading @@ -106,6 +106,7 @@ answer newbie questions, and generally made Django that much better: Swaroop C H <http://www.swaroopch.info> Aaron Swartz <http://www.aaronsw.com/> Tom Tobin Tom Insam Joe Topjian <http://joe.terrarum.net/geek/code/python/django/> Malcolm Tredinnick Amit Upadhyay Loading
django/contrib/admin/media/js/urlify.js +2 −2 Original line number Diff line number Diff line Loading @@ -9,7 +9,7 @@ function URLify(s, num_chars) { s = s.replace(r, ''); s = s.replace(/[^-A-Z0-9\s]/gi, ''); // remove unneeded chars s = s.replace(/^\s+|\s+$/g, ''); // trim leading/trailing spaces s = s.replace(/\s+/g, '-'); // convert spaces to hyphens 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 }
django/template/defaultfilters.py +1 −1 Original line number Diff line number Diff line Loading @@ -66,7 +66,7 @@ def make_list(value): def slugify(value): "Converts to lowercase, removes non-alpha chars and converts spaces to hyphens" value = re.sub('[^\w\s-]', '', value).strip().lower() return re.sub('\s+', '-', value) return re.sub('[-\s]+', '-', value) def stringformat(value, arg): """ Loading