URL Redirect with Pro version

Popular automatic website translation tool

URL Redirect with Pro version

Postby Playalosarcos » Wed Jun 15, 2011 3:14 am

I have installed the pro version and with Gtranslate everything is working perfectly. However I have a very troublesome problem.

When you change the language of the site and are looking at for example : http://www.playalosarcos.com/es/index.php everything works fantastic except the links to external features of the site. When you click on a link that goes to an external resource it is adding the /es to the link which will obviously mark an error because it does not exist. How can i keep gtranslate from adding the /es to the external links?

In specific what i am talking about is when you click on the button to use the Live chat. In English it opens perfectly as it should:

http://www.playalosarcos.com/livezilla/ ... xB&hg=Pw__

but when viewing in Spanish it opens:

http://www.playalosarcos.com/es/livezil ... xB&hg=Pw__

which does not exist and marks an error.

Any ideas??

The code I have used to install that button is this:

<a href="javascript:void(window.open('http://www.playalosarcos.com/livezilla/chat.php?intgroup=UExB&amp;hg=Pw__','','width=590,height=610,left=0,top=0,resizable=yes,menubar=no,location=no,status=yes,scrollbars=yes'))"><img src="http://www.playalosarcos.com/livezilla/image.php?id=01&amp;type=inlay&amp;hg=Pw__&amp;intgroup=UExB" width="120" height="30" border="0" alt="LiveZilla Live Help" /></a>

Thanks!!
Playalosarcos
 
Posts: 12
Joined: Fri Apr 08, 2011 7:59 pm

Re: URL Redirect with Pro version

Postby hosteris » Tue Jul 05, 2011 8:47 pm

Bien, creo me entenderás en español.
Sólo agrega esto a tu .htaccess:

RewriteRule ^([a-z]{2}|zh-CN|zh-TW)/livezilla/(.*)$ /lvezilla/$2 [R=301,L]

Saludos.
hosteris
 
Posts: 12
Joined: Fri Jul 01, 2011 10:37 am
Location: México

Re: URL Redirect with Pro version

Postby Edvard » Thu Jul 07, 2011 2:43 pm

You can add class="nturl" to <a> tag to force it to not add the language code into URL. It shouldn't add the language code into the URL if the URL points to other site.

Not sure about the Chat, I was able to see it in both languages.
Regards,

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
Edvard
Site Admin
 
Posts: 4183
Joined: Mon Jun 28, 2010 1:54 pm
Location: Yerevan, Armenia

Re: URL Redirect with Pro version

Postby [email protected] » Sat Jul 23, 2011 3:33 pm

I can't underdtand how class="nturl" works.
Help me to write php code with class="nturl"please.

I want use URL "http://lokhnin.com/uk/post" but not javascript:doGTranslate('ru|uk')

Code #1:
<a href="<?php echo home_url( '/' ); echo "uk"; echo $_SERVER["REQUEST_URI"]; ?>" title="Ukrainian" class="gflag" style="background-position:-100px -400px;"><img src="http://lokhnin.com/wp-content/plugins/gtranslate/blank.png" height="32" width="32" alt="Ukrainian" /></a>

URL #1 (main page):
http://lokhnin.com/uk/uk/

URL #2 (twice "/uk/uk/"):
http://lokhnin.com/uk/uk/browse/persona ... l-literacy


I've tried use this code <?php echo 'http://lokhnin.com/'; echo "uk"; echo $_SERVER["REQUEST_URI"]; ?> code, but a've got the same result.
I've tried use class="nturl", but a've got the same result, code:

<a class="nturl" href="<?php echo 'http://lokhnin.com/'; echo "uk"; echo $_SERVER["REQUEST_URI"]; ?> " title="Ukrainian" class="gflag" style="background-position:-100px -400px;"><img src="http://lokhnin.com/wp-content/plugins/gtranslate/blank.png" height="32" width="32" alt="Ukrainian" /></a>
[email protected]
 
Posts: 7
Joined: Sat Jul 23, 2011 3:18 pm


Re: URL Redirect with Pro version

Postby Edvard » Sun Jul 24, 2011 12:42 am

Since you already have class="gflag" you need to replace it with class="gflag nturl"
Regards,

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
Edvard
Site Admin
 
Posts: 4183
Joined: Mon Jun 28, 2010 1:54 pm
Location: Yerevan, Armenia


  • Related Topics
    Replies
    Views
    Last post

Who is online

Users browsing this forum: No registered users and 1 guest

2GLux
cron