Welcome Guest, Not a member yet? Register   Sign In
Use utf-8 fonts in url?

I can't understand what goes wrong with utf-8 font in url :/ how did you solve this problem?
[Image: N8jPdBS.png] Thanks in advance

Check your setting for $config['permitted_uri_chars']. The default only allows English letters, numbers and a few others.

In that case it is not possible to add every single characters in that string. what could be another option? this way seems to be black-hat but can we apply a white-hat approach, i am not sure if i am speaking right about black hat or white hat Big Grin but i think you get the point

You can always leave that config setting blank like the notes say, which will allow all chars. It does open more security risks though. But I believe the proper way would be to urlencode non-ascii chars in the url.

i think urlencode will also not gonna work, cause latest browsers decode it right in the addressbar :[

Yeah, but that's how it's supposed to work! The HTTP specs state that urls should only contain ascii characters, or url encoded chars. This isn't a CI limitation. CI is using the STANDARD. Browsers set to use that language will properly decode it in the url and show it properly - others will see the urlencoded string, which is proper.

You might want to read up on the RFC standard here: https://tools.ietf.org/html/rfc3986#page-11

The following page details some of the standards and proposals related to handling of multilingual URLs:

It also includes details about how some browsers will translate non-ASCII characters in different parts of the URL.

In the end, you may need to find a RegEx which permits the characters for your language in the permitted portions of the URL.

$config['permitted_uri_chars'] = 'a-z 0-9~%.:_\-\p{L}';


at the end, for international characters

Theme © iAndrew 2016 - Forum software by © MyBB