Django

Code

Ticket #5044 (closed: fixed)

Opened 1 year ago

Last modified 1 year ago

Update urlify.js with missing characters

Reported by: dall Assigned to: nobody
Milestone: Component: django.contrib.admin
Version: SVN Keywords: sprintsept14
Cc: Triage Stage: Ready for checkin
Has patch: 1 Needs documentation: 0
Needs tests: 0 Patch needs improvement: 0

Description

my (latvian) language, characters like - āšžčļņī, needs to be converted to aszclni, not to disaper.

Attachments

5044.diff (0.8 kB) - added by arien on 12/12/07 13:59:31.
LATVIAN_MAP for urlify.js

Change History

08/03/07 15:33:03 changed by Collin Grady <cgrady@the-magi.us>

  • owner changed from jacob to adrian.
  • needs_better_patch changed.
  • component changed from Uncategorized to Admin interface.
  • needs_tests changed.
  • needs_docs changed.

09/14/07 13:44:44 changed by Dimitris Glezos <dimitris@glezos.com>

Currently (latest SVN copy) āšžčļņī is converted to "szc".

09/14/07 13:58:34 changed by Dimitris Glezos <dimitris@glezos.com>

This ticket requires someone familiar with the Latvian alphabet to write a patch similar to those on ticket #4365 for source:django/trunk/django/contrib/admin/media/js/urlify.js.

(follow-up: ↓ 5 ) 09/14/07 16:14:15 changed by webjunkie

  • keywords set to sprintsept14.
  • stage changed from Unreviewed to Design decision needed.

Good question.. How do we handle foreign-language slugs in Django?

(in reply to: ↑ 4 ; follow-up: ↓ 7 ) 09/16/07 03:11:03 changed by ubernostrum

Replying to webjunkie:

Good question.. How do we handle foreign-language slugs in Django?

Look at the JavaScript? file linked in the comment above yours.

09/16/07 20:04:45 changed by anonymous

The slugify filter would also need to be updated, since the JS isn't the only method for populating slugs

(in reply to: ↑ 5 ; follow-up: ↓ 8 ) 09/17/07 15:22:27 changed by webjunkie

Replying to ubernostrum:

Replying to webjunkie:

Good question.. How do we handle foreign-language slugs in Django?

Look at the JavaScript? file linked in the comment above yours.

It was more of a rhetorical question if we really handle them correct in every case. For example, German is not handled right.

(in reply to: ↑ 7 ) 09/17/07 15:44:48 changed by glezos

Replying to webjunkie:

It was more of a rhetorical question if we really handle them correct in every case. For example, German is not handled right.

With test cases (at least for the slugify part) to make sure conversions are OK I guess.

12/01/07 16:40:48 changed by jacob

  • summary changed from utf-8 characters in SlugField (prepopulate_from) to Update urlify.js with missing characters.
  • stage changed from Design decision needed to Accepted.

As Dimitris said, someone needs to update urlify.js with the appropriate characters. I'm changing the title to reflect that.

12/12/07 13:59:31 changed by arien

  • attachment 5044.diff added.

LATVIAN_MAP for urlify.js

12/12/07 14:19:17 changed by arien

  • has_patch set to 1.
  • stage changed from Accepted to Ready for checkin.

The patch adds characters from the Latvian alphabet. This should be good to go.

(There is a larger issue here, though: slugifying nicely is dependent on language. For example, 'ü' in German should be converted to 'ue', but in Dutch, French or Spanish it should be converted to 'u', as it is now. See #2176 for a request to change the way characters with umlauts are handled from a German perspective.)

12/12/07 14:20:31 changed by arien

That should be #2716 for handling characters with umlauts.

12/17/07 03:15:02 changed by mtredinnick

  • status changed from new to closed.
  • resolution set to fixed.

(In [6933]) Fixed #5044 -- Added Latvian character map for Javascript slug generation. Patch from arien.


Add/Change #5044 (Update urlify.js with missing characters)




Change Properties
Action