Good nigh, Im trying to create virtual subfolders for user's browser language.
So i have the following folder structure:
www/
Core/
Classes/
Autoloader.Class.php
Smarty.Class.php
Database.Class.php
LoadingOrder.json
Libraries/
Smarty.Class.BC.php
Smarty.Class.php
SmartyModules/
..
Modules/
Autoloader.Module.php
Wall.Module.php
Account.Module.php
LoadingOrder.json
Engine.php
Initialize.php
Templates/
Default/
css/
main.css
style.css
ErrorHandler.css
images/
javascript/
jquery.js
Main.tpl
User.tpl
ErrorHandler.tpl
.htaccess
index.php
user.php
ErrorHandler.php
The thing i need, is to create multilingual website.
For example:
User want to go to his/her page: http://site.domain/user
The thing i want to implement, is that based on his browser language, it will redirect him tohttp://site.domain/en/user
- if he speaks English,http://site.domain/ru/user
- if he speaks Russian,http://site.domain/pt/user
- if he speaks Portugese.
The thing is, these language subfolders should be only virtual, and the all their requests should be made to only user.php, which is one in the root directory.
I've been googleing, and found that on http://battle.net - there is kind of system like this.
So is it possible to create system like this via htaccess, or its purely php?