URI/address; non English/standard characters.

Hi my humble serve-eh--friends!

I was wondering how to make Apache show non English/standard in the URI location bar.

Example 1: the address http://www.example.com/x z y becomes http://www.example.com/x%20z%20y.

-- How do you remove the %20 and make Apache show ordinary spaces?

Example 2: the address http://www.example.com/å becomes http://www.example.com/%E5.

-- How do you remove the %E5 and make Apache show å?

I know you can make colons (:) show in the URI, and that some web-services have support for non-English characters in their domain name. Surly what I am asking for cant be to much to ask for? If you ask me.
LVL 3
numbers1to9Asked:
Who is Participating?
 
Guy Hengel [angelIII / a3]Billing EngineerCommented:
1. - 4. yes, you understood that correctly.

>How come some domain names can support non-English characters?
can you show an example?
and yes, since short time, accented characters for example should be allowed in domain names.

>And if I have understood both of you correctly there is no way to bypass this, because the "problem" is on the user agent (the browser) not Apache?
yes

>What about rewriting "%20" to "(space)" is that possibly? Could it be done with "a simply" (read hours of hours of work time) htaccess rewrite???
in htaccess, you will not get %20, but "(space)" indeed, as htaccess will "urldecode" automatically for you.

0
 
paradoxengineCommented:
IIRC, domain names can only have standard english characters, and Apache will answer only URL encoded queries (actually the user's browser will encode the query automatically).
0
 
numbers1to9Author Commented:
Hmm... I don't think I like your answer... Are you saying it can not be done? If your saying that then I DEFINITIVELY do not like your answer. Please try again... Don't make me cry.

0
Cloud Class® Course: Ruby Fundamentals

This course will introduce you to Ruby, as well as teach you about classes, methods, variables, data structures, loops, enumerable methods, and finishing touches.

 
numbers1to9Author Commented:
Seriously, there must be a way to do this? No? What about just rewriting the %E5 to, maybe "(swe-a)", or space to "(space)". That should surly be possible? Yes?

5 more shiny shiny points for the lucky one that could nail this question!


0
 
Guy Hengel [angelIII / a3]Billing EngineerCommented:
the <space> to %20 is indeed the web browser that does this, long before even the request reaches your apache server.
any application has to be aware of that, and act upon that.
in php, for example, you have the function urldecode:
http://www.php.net/urldecode
that would return the space back from the %20.
0
 
numbers1to9Author Commented:
angellll: do you mean:

1. the user writes e.g. "<space>" somewhere in the address bar.
2. the character is converted by the browser to %20.
3. the urldecode can be used to transform the %20 to "<space>" so that PHP can interprets the character correctly?
4. In the address bar it would still be "%20".

Have I understood you correctly?

NOT SO IMPORTANT ================================
How come some domain names can support non-English characters? (I read a little about it, and if I remember correctly, they use some new DNS stuff -- nothing that could be [ab]used for what I am thinking about?

IMPORTANT ======================================
And if I have understood both of you correctly there is no way to bypass this, because the "problem" is on the user agent (the browser) not Apache?
================================================

ALSO IMPORTANT ==================================
What about rewriting "%20" to "(space)" is that possibly? Could it be done with "a simply" (read hours of hours of work time) htaccess rewrite???

0
 
numbers1to9Author Commented:
I see... Well, guess I have to dust of the old htaccess file and lose my hair prematurely...

Say... You don't happen to have a working example around--say, for Apache 2++? That would be swell... Just... You know--Gold. Super. Yeah... Good. Mmmmm... Yes.... Oh-yes...

REGARDING NON-ENGLISH DOMAIN NAMES =================================
I do not have any examples out of the blue. I have only seen one site (a friends site) using a non-English character, but that was a very long time ago. And I don't remember if I actually saw the working address or if my friend told me about it. For that matter, I do not remember if that was my friend, or if I even actually talked to a real person.

Although, I recently stumbled upon a ISP that had such a service (it was there I read a little bit more about non-English characters in the domain name). If you want I can try to dig up something (a working example, or the ISP site).

0
 
Guy Hengel [angelIII / a3]Billing EngineerCommented:
I don't use htaccess actually, so I have not samples...

in regards to the other issue, you might find this one interesting:
http://www.idnnow.com/index.jsp
0
 
numbers1to9Author Commented:
>I don't use htaccess actually, so I have not samples...
Well, thank you anyway.

>in regards to the other issue, you might find this one interesting:
http://www.idnnow.com/index.jsp

Thanks!

0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.