Forum Archive - Install only in subdir

Install only in subdir
Oct 27, 2011 6:09 pm by Flow
Hi! I just bought the pro version an have a little (I hope) question :) I have an online shop at maindomain.com this shop is already multilanguage, translated by hand. So this should stay like this. It also uses a subdir for each language. I have a blog though, installed in /blog, on which I'd like to use gtranslate. Each language should have his own domain. How can I install gtranslate to work only on this blog, and leave my shop alone? If I put the redirect stuff in .htaccess in my main directory, I'm getting loop errors. Hope you can help! Thanks in advance!
Re: Install only in subdir
Oct 28, 2011 8:53 am by linboyz
you can use this code: <span class="notranslate"></span> This will refrain from translating the content you wished to remain. Hope it helps! (:
Re: Install only in subdir
Oct 28, 2011 4:48 pm by Edvard
Hi, You need to use this rewrite rules instead: # gtranslate config RewriteCond %{REQUEST_URI} ^/blog RewriteRule ^([a-z]{2}|zh-CN|zh-TW)/([a-z]{2}|zh-CN|zh-TW)/(.*)$ /$1/$3 [R=301,L] RewriteCond %{REQUEST_URI} ^/blog RewriteRule ^([a-z]{2}|zh-CN|zh-TW)/([a-z]{2}|zh-CN|zh-TW)$ /$1/ [R=301,L] RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_URI} ^/blog RewriteRule ^([a-z]{2}|zh-CN|zh-TW)/(.*)$ /gtranslate/translate.php?lang=$1&url=$2&force_no_api=1 [L,QSA] RewriteCond %{REQUEST_URI} ^/blog RewriteRule ^([a-z]{2}|zh-CN|zh-TW)$ /gtranslate/translate.php?lang=$1&force_no_api=1 [L,QSA] So it will work only for blog directory.
Re: Install only in subdir
Oct 30, 2011 5:08 pm by Flow
Thanks! With the new .htaccess code my shop works again. I'm still having trouble getting gtranslate to work in my blog though. The widget is there, the buttons are there, but I get 404 pages. I think it might be because it's putting the language code like this: maindomain.com/de/blog and not /blog/de
Re: Install only in subdir
Oct 31, 2011 1:31 pm by Edvard
Make sure that you have installed it in your www root, not inside blog directory. Please check the troubleshooting for more info.
Re: Install only in subdir
Oct 31, 2011 6:32 pm by Flow
I have installed in root. I think it is because my shop also uses maindoman.com/XX for other languages. Is it be possible to make the URL like maindomain.com/blog/XX ? That would work I guess.
Re: Install only in subdir
Nov 1, 2011 12:34 pm by Edvard
When you go to domain.com/gtranslate/translate.php?lang=ru&url=blog/&force_no_api=1 what happens?
Re: Install only in subdir
Nov 1, 2011 6:46 pm by Flow
Then it works! I get my blog in Russian. Exccept for some headings and the menu :) I also sent you a private mail with URL so yo can check it out
Re: Install only in subdir
Nov 1, 2011 9:10 pm by Edvard
Then you have something wrong in your .htaccess file. Can you post your .htaccess file located in www root folder?
Re: Install only in subdir
Nov 2, 2011 8:02 am by Flow
I sent it to you in a private mail. Thanks!
Re: Install only in subdir
Nov 10, 2011 7:01 pm by Flow
Edvard, Thanks for the great service. With the new .htaccess things are working perfectly now!
Re: Install only in subdir
Nov 10, 2011 7:30 pm by Edvard
Good to hear that!
Re: Install only in subdir
Nov 25, 2011 5:03 pm by Flow
Hi Edvard, I discovered that the edit page (with ?language_edit=1) is no longer password protected. I can access it in any browser and start editing. Do you have any idea what this could be? My config file seems to be fine. thanks
Re: Install only in subdir
Nov 26, 2011 11:28 pm by Edvard
Please check gtranslate/edit_translation.php file. Is it the original file from the product package?
Re: Install only in subdir
Dec 2, 2011 11:37 am by Flow
Yep, it's the same. Just to be sure I copied it again. Maybe it has to do with the .htaccess you sent me to make things work at my site. Please see your private mail to see the .htaccess info. Thanks!
Re: Install only in subdir
Dec 4, 2011 5:25 pm by Flow
Hi Edvard, Any news about this? I'd love to start translating but don't dare to put the site online like this. Thanks :)
Re: Install only in subdir
Dec 5, 2011 7:26 pm by Edvard
OK, I'll check that for you. Hope you already sent the access info.
Re: Install only in subdir
Dec 6, 2011 11:41 am by Flow
Yep, it's in your private mail.
Re: Install only in subdir
Dec 6, 2011 2:11 pm by Edvard
I cannot find access info. Please send FTP login/password.
Re: Install only in subdir
Dec 6, 2011 3:21 pm by Flow
Oh sorry I read too fast and thought you meant the .htaccess file. It's in your mailbox.
Re: Install only in subdir
Dec 9, 2011 10:35 am by Flow
Any news? :)
Re: Install only in subdir
Dec 12, 2011 4:20 pm by Flow
Hi Edvard, I'd be really grateful if you could have a look at this.... Thanks.. - F.
Re: Install only in subdir
Dec 12, 2011 10:08 pm by Edvard
Hi, I cannot confirm that you are able to edit translations if you don't know the password in gtranslate/config.php file. It asks the password only once then you can make changes. However if you access it with a different browser or close the current browser and access it again it will ask for the password again.
Password protection and slugs translation
Dec 14, 2011 9:46 am by Flow
Hmm, ok I think we are making progress :) The thing is, I thought it would ask for a password immediately. But it only asks for the password if I try to save a translation. Is this normal behavior? Because it does not do that on your site, where it ask for a password immediately when you type /?language_edit=1 after the URL, which i think is a much better way. Also, something I'm wondering about.. it's probably impossible to also translate slugs, right? Thanks :)
Re: Install only in subdir
Dec 14, 2011 7:30 pm by Edvard
Yes, it is normal. Not sure I understand you about the slugs, could you describe what you want to be translated on your site more in details?
Re: Install only in subdir
Dec 15, 2011 11:25 am by Flow
Thanks! With slugs, I mean SEO friendly URL's like: https://gtranslate.io/gtranslate-best-t ... ion-plugin ;) I think it won't be possible, but it would be awesome if these could also be translated.
Re: Install only in subdir
Dec 17, 2011 3:53 pm by Edvard
We are planning to add the URL translation feature in future.

SIMILAR TOPICS

Love the plug-in, please help us install it.Jan 13, 2015 5:45 pmReplies: 1Post by: joseph
CONNOT INSTALL THE ZIP YOU SENT MENov 4, 2014 1:04 pmReplies: 4Post by: argana-belleza
Enterprise Install please on my siteOct 25, 2013 10:22 amReplies: 3Post by: spanishproperty
Drupal 7 multi site installJul 15, 2013 3:37 pmReplies: 4Post by: DF30000
Local install problemJul 10, 2013 9:51 amReplies: 11Post by: toshko4

Try GTranslate with a free 15 day trial