3 users online. Create an account or sign in to join them.Users
Turning ampersands in titles into a custom word in the XML handle (instead of 'and')
This is an open discussion with 4 replies, filed under Troubleshooting.
Search
Take a look at /symphony/lib/lang/lang.en.php. You will find so-called "Transliterations" there. These are the (English) defaults.
If you switch the backend to use a different language, then the new language file (provided by the language extension) will be used.
So if you want to keep the backend in English, you will have to edit the language file (after every Symphony update).
I've never tried it but maybe the language framework supports inheritance. Meaning that you'll create a tiny extension that adds a new language but all it actually does is replace that specific behaviour. Take a look at lang_german to see how those kind of extensions are done.
It`ll be better to be able to set custom handle for xml-node in Section in future version of symphony or in extension.
I have just used the lang_german transliterations to be able to handle characters like ®, –, —, …, and the unicode-shy in handles, which I use in my urls. This works great, thanks!
Create an account or sign in to comment.
Hello all, and forgive me for the wierd discussion topic - I found it hard to pin down the issue in one sentence :).
So given some more room for explanation, what I want to do is change how Symphony is changing ampersands in titles (for entries, categories and such) into 'and' in XML element handles.
To give an example, if I have a category named "News & Updates", Symphony will construct the handle to become "news-and-updates".
While this is all fine for a website in english, it translates worse for a site such as mine that's in swedish. For example, my category "Nyheter & Uppdateringar" (News & Updates) becomes 'nyheter-and-uppdateringar'.
While not a big issue, it would be nice if it was possible to change how symphony is translating that ampersand in any of the source files so that '&' becomes 'och' ('and' in swedish) instead.
Is it?
Thanks in advance!