CodeIgniter Forums
Help me config url - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20)
+--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23)
+--- Thread: Help me config url (/showthread.php?tid=6726)



Help me config url - El Forum - 03-09-2008

[eluser]Le Bang[/eluser]
In file application/config/config.php

at line:

$config['permitted_uri_chars'] = 'a-z 0-9~%.:_-';

character types limiter its medicine URL. At my country as well as many another countries had use another Unicode characters. string example (Xin chào tất cả các bạn)..
I have to make how to let it accept those string type.


Help me config url - El Forum - 03-09-2008

[eluser]Avatar[/eluser]
place a backtick before any added chars on to the originals that you want to be excepted, only way I could make it work
Code:
$config['permitted_uri_chars'] = 'a-z 0-9~%.:_-`!@=+;';//this will allow you to accept these extra chars in the url
note you may also need to modify your charset in config to that proper encoding:
Code:
$config['charset'] = "UTF-8";//change to your encoding
I would try something along those lines, Also If they don't store in DB correctly try to change these DB settings to the proper encoding:
Code:
$db['default']['char_set'] = "utf8";
$db['default']['dbcollat'] = "utf8_general_ci";
//$db['default']['char_set'] = "latin1";
//$db['default']['dbcollat'] = "latin1_swedish_ci";



Help me config url - El Forum - 03-09-2008

[eluser]Le Bang[/eluser]
http://mysite.com/index.php/news/124/Tin_tức_sự_kiện

Which pose Perform the duties of it accepted without give mistake to error:

The URI you submitted has disallowed characters.

Database irrelevant this circumstance


Help me config url - El Forum - 03-10-2008

[eluser]Avatar[/eluser]
yes, you are correct about db. I will look around some for you. As I can see this to pose a problem for me later in the future with Cyrillic characters. What I think you may have to do it somehow add the hex version of these characters into the uri allowed list or extend the uri class. This is a very interesting problem.


Help me config url - El Forum - 03-10-2008

[eluser]Le Bang[/eluser]
a problem too. on URL. when get segment string type have some white space but URI library auto replace to "_" => Isn't become

A example:
build a search page. then keyword input sending type GET on URL


Help me config url - El Forum - 03-10-2008

[eluser]Le Bang[/eluser]
I see this type handling URL very beautiful, I am very liked. But think again founded it Un- Offer.


Help me config url - El Forum - 03-10-2008

[eluser]Le Bang[/eluser]
problem with decided Vietnamese. even though untowardly give very much.: D

Code:
$config['permitted_uri_chars'] = 'a-z 0-9~%.:_()-áàảãạăắằẳẵặâấầẩẫậéèẻẽẹêếềểễệóòỏõọơớờởỡợôốồổỗộúùủũụưứừửữựíìỉĩịýỳỷỹỵđÁÀẢÃẠĂẮẰẲẴẶÂẤẦẨẪẬÉÈẺẼẸÊẾỀỂỄỆÓÒỎÕỌƠỚỜỞỠỢÔỐỒỔỖỘÚÙỦŨỤƯỨỪỬỮỰÍÌỈĨỊÝỲỶỸỴĐ';



Help me config url - El Forum - 08-27-2008

[eluser]Berserk[/eluser]
lolz Big Grin