WHM Accelerated 2 - domain redirections

faemont

Registered
Nov 28, 2013
1
0
1
cPanel Access Level
Root Administrator
Hello everyone,

1st time on the forums, 1st time using WHM Accelerated 2.

I have a problem, i have moodle installed on a folder called moodle2, so if i need to go to my moodle i enter this url:
www./moodle2.
But inside the moodle you can choose more than 1 language so lets say i have 2 languages, english and french...
example.com/moodle2/?lang=fr_ca (french)
example.com/moodle2/?lang=en (english)

I want to add a redireccion for each one so when i enter
example.com/french it redirects me to example.com/moodle2/?lang=fr_ca
and
example.com/english it redirects me to example.com/moodle2/?lang=en

Can anyone help me with this? i will appreciate this a lot.

Thanks in advance for everything...

Bye for now!
 

Rhuan

Active Member
Nov 10, 2010
39
0
56
Brazil
cPanel Access Level
Root Administrator
Hi, I think this will work for you:
Make .htaccess file and put this code...

Code:
RewriteEngine On
RewriteRule ^french$ ?lang=fr_ca [L]
You need mod_rewrite enabled on apache...
 

cPanelMichael

Technical Support Community Manager
Staff member
Apr 11, 2011
47,910
2,233
363
cPanel Access Level
DataCenter Provider
Twitter
Hello :)

Note that you may also want to post to a forum dedicated to Mod_Rewrite rules as you may get more input on that type of forum compared on here where issues are primarily focused on the cPanel software itself.

Thank you.