I have made an worldwide website where languages can be found such as this :

world wide web.sitename.com/es/spanishpage.html

All lang folders are virtual, in order to make 100s versions with similar quantity of PHP pages. To do this i personally use rewrite rules to produce the web pages, something such as this :

RewriteRule ^germanpage\.html$ /page.php?lang=de [L]

Now let me use real domains. How do i do this please ? I believe I must create physical folders (p/, /fr/ ...) for domain names, however the way i rewrite the web pages?

I am talking about, sitename.p/ would go to myserver.com/p/ . It really works, but it is a clear folder. How do i redirect all of the web site to my pages situated at myserver.com/page.php?lang=p please ?

Thanks for you personally help ! I am really lost.

nb. have no idea whether it's iportant, however the website is running on the devoted server.

you should use soft links rather than creating physical folders. Click here to find out more about Symbolic link

Visit root folder at the domain (let if you have index.php inside your root folder) myserver.com

now execute following instructions

ln -s es
ln -s de
ln -s fr

if you access http://myserver.com/fr/index.php file that'll be performed is http://myserver.com/index.php

The solution I discovered consist in setting all of the domain names underneath the server root, after which to put it simply redirects with no virtual folders.

so for mydomain.com/p/germanpage.html

This rule :

RewriteRule ^de/germanpage\.html$ page.php?lang=de

Becomes :

RewriteRule ^germanpage\.html$ page.php?lang=de

There must an simpler solution (because now i can not have .p/contact.html and .fr/contact.html) but a minimum of it really works.