1

I’ve already got a ton of content put in by the client, and there’s quite a bit of accented characters (é, à, ...) in the titles, and thus also in the slugs where they get url encoded, which my client considers 'ugly'.

Now I’ve added the limitAutoSlugsToAscii' => true rule to the config, but how can I best rework the url’s for the already existing content? There’s about 1000 entries already in the website so I’d rather not go over them by hand.

Can I just clear the slug column in the database? Or will I have to write a temporary custom controller action that I can trigger to loop over all entries to redo their slug? Or is there another (better) solution?

3

Or will I have to write a temporary custom controller action that I can trigger to loop over all entries to redo their slug?

This one.

The plugin could then just use StringHelper::asciiString($slug); to do the ASCII conversion and re-save it back to the database.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.