[solved] htaccess rewrite breaks javascript

Popular automatic website translation tool

[solved] htaccess rewrite breaks javascript

Postby [email protected] » Fri May 27, 2011 3:17 pm

I'm trying to install gtranslate, everything is fine until I add the line
Code: Select all
RewriteRule ^([a-z]{2}|zh-CN|zh-TW)/(.*)$ /gtranslate/translate.php?lang=$1&url=$2 [L,QSA]

to my htaccess, which results in 404 errors on the URLs to the javascript files.
The 404 page has
Code: Select all
<!-- generated by GTranslate Pro v3.1415 on Fri, 27 May 2011 12:10:50 +0100 visit http://edo.webmaster.am/gtranslate -->
so it is definitely a result of gtranslate.

any help greatly appreciated

[email protected]
Posts: 5
Joined: Thu May 05, 2011 6:07 pm

Re: [solved] htaccess rewrite breaks javascript

Postby Edvard » Tue May 31, 2011 11:52 am

You can also make it to exclude js folder by this rewrite condition before every gtranslate rewrite rule:

RewriteCond %{REQUEST_URI} !^/js

Edvard Ananyan - GTranslate Team

Please leave your feedback on your CMS plugin directory. It is very important for us!
Google Translate Joomla
Google Translate WordPress
Google Translate Drupal
Site Admin
Posts: 4316
Joined: Mon Jun 28, 2010 1:54 pm
Location: Yerevan, Armenia

  • Related Topics
    Last post

Who is online

Users browsing this forum: No registered users and 0 guests