vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.6 Template Modifications (https://vborg.vbsupport.ru/forumdisplay.php?f=192)
-   -   Miscellaneous Hacks - Google Translate For your site (https://vborg.vbsupport.ru/showthread.php?t=177912)

Q-v-n-s-Q 05-02-2008 10:00 PM

Google Translate For your site
 
Current supported languages!!

Chinese
French
German
Italian
Japanese
Korean
Russian
Spanish

Demo : http://www.h7v.net/

Code:

<!?GOOGLE TRANSLATE?>
<div align="left">

<!? Add English to Chinese (Simplified) BETA ?>

<a target="_blank" rel="nofollow" style="cursor:pointer; cursor:hand;" onclick="window.open('http://www.google.com/translate?u='+encodeURIComponent(location.href)+'&langpair=en%7Czh-CN&hl=en&ie=UTF8'); return false;" title="Google-Translate-Chinese (Simplified) BETA"><img border="0" style="cursor:pointer; cursor:hand;" width="24" align="absbottom" alt="Google-Translate-Chinese (Simplified) BETA" src="/images/translate/chinese_s.png" height="24" title="Google-Translate-Chinese (Simplified) BETA"/> Chinese</a>

<!? END English to Chinese (Simplified) BETA?>

<br/>

<!? Add English to French ?>

<a target="_blank" rel="nofollow" style="cursor:pointer; cursor:hand;" onclick="window.open('http://www.google.com/translate?u='+encodeURIComponent(location.href)+'&langpair=en%7Cfr&hl=en&ie=UTF8'); return false;" title="Google-Translate-English to French "><img border="0" style="cursor:pointer; cursor:hand;" width="24" align="absbottom" alt="Google-Translate-English to French " src="/images/translate/french_s.png" height="24" title="Google-Translate-English to French "/> French</a>

<!? END English to French ?>

<br/>

<!? Add English to German ?>

<a target="_blank" rel="nofollow" style="cursor:pointer; cursor:hand;" onclick="window.open('http://www.google.com/translate?u='+encodeURIComponent(location.href)+'&langpair=en%7Cde&hl=en&ie=UTF8'); return false;" title="Google-Translate-English to German"><img border="0" style="cursor:pointer; cursor:hand;" width="24" align="absbottom" alt="Google-Translate-English to German" src="/images/translate/german_s.png" height="24" title="Google-Translate-English to German"/> German</a>

<!? END English to German ?>

<br/>

<!? Add English to Italian ?>

<a target="_blank" rel="nofollow" style="cursor:pointer; cursor:hand;" onclick="window.open('http://www.google.com/translate?u='+encodeURIComponent(location.href)+'&langpair=en%7Cit&hl=en&ie=UTF8'); return false;" title="Google-Translate-English to Italian"><img border="0" style="cursor:pointer; cursor:hand;" width="24" align="absbottom" alt="Google-Translate-English to Italian" src="/images/translate/italian_s.png" height="24" title="Google-Translate-English to Italian"/> Italian</a>

<!? END English to Italian ?>

<BR/>

<!? Add English to Japanese BETA ?>

<a target="_blank" rel="nofollow" style="cursor:pointer; cursor:hand;" onclick="window.open('http://www.google.com/translate?u='+encodeURIComponent(location.href)+'&langpair=en%7Cja&hl=en&ie=UTF8'); return false;" title="Google-Translate-English to Japanese BETA"><img border="0" style="cursor:pointer; cursor:hand;" width="24" align="absbottom" alt="Google-Translate-English to Japanese BETA" src="/images/translate/japanese_s.png" height="24" title="Google-Translate-English to Japanese BETA"/> Japanese</a>

<!? END English to Japanese BETA ?>

<br/>

<!? Add English to Korean BETA ?>

<a target="_blank" rel="nofollow" style="cursor:pointer; cursor:hand;" onclick="window.open('http://www.google.com/translate?u='+encodeURIComponent(location.href)+'&langpair=en%7Cko&hl=en&ie=UTF8'); return false;" title="Google-Translate-English to Korean BETA"><img border="0" style="cursor:pointer; cursor:hand;" width="24" align="absbottom" alt="Google-Translate-English to Korean BETA" src="/images/translate/korean_s.png" height="24" title="Google-Translate-English to Korean BETA"/> Korean</a>

<!? END English to Korean BETA ?>

<br/>

<!? Add English to Russian BETA ?>

<a target="_blank" rel="nofollow" style="cursor:pointer; cursor:hand;" onclick="window.open('http://www.google.com/translate?u='+encodeURIComponent(location.href)+'&langpair=en%7Cru&hl=en&ie=UTF8'); return false;" title="Google-Translate-English to Russian BETA "><img border="0" style="cursor:pointer; cursor:hand;" width="24" align="absbottom" alt="Google-Translate-English to Russian BETA " src="/images/translate/russian_s.png" height="24" title="Google-Translate-English to Russian BETA "/> Russian</a>

<!? END English to Russian BETA ?>

<br/>

<!? Add English to Spanish ?>

<a target="_blank" rel="nofollow" style="cursor:pointer; cursor:hand;" onclick="window.open('http://www.google.com/translate?u='+encodeURIComponent(location.href)+'&langpair=en%7Ces&hl=en&ie=UTF8'); return false;" title="Google-Translate-English to Spanish "><img border="0" style="cursor:pointer; cursor:hand;" width="24" align="absbottom" alt="Google-Translate-English to Spanish " src="/images/translate/spanish_s.png" height="24" title="Google-Translate-English to Spanish "/> Spanish</a>

<!? END English to Spanish ?>

</div>

Add the code above to where you want to display the google translate buttons!!

redraider 05-03-2008 01:46 PM

Great plugin ...can you make it more SEO friendly like for example this plugin

http://www.nothing2hide.net/wp-plugi...slator-plugin/

"it uses the permalinks by adding the language code at the beginning of all your URI. For example the english version on www.domain.com/mycategory/mypost will be automatically transformed in www.domain.com/en/mycategory/mypost"

nectons 06-03-2008 02:20 PM

Hi all friends. Is there anyone knows how to do this :

http://66.102.9.104/translate_c?hl=e...p%3Ft%3D375898

If you hover the mouse on text it will translate it in the same window... in a popup.. It is very cool.. is there anything please ?

Thanks

Paintball Guns 10-24-2008 05:51 PM

A 3.7 version of this mod would be great. Anyone know of any mod that will offer the forum in various languages like this Wordpress plugin will a blog?

segwayon 10-25-2008 03:17 AM

Quote:

Originally Posted by Paintball Guns (Post 1651938)
A 3.7 version of this mod would be great. Anyone know of any mod that will offer the forum in various languages like this Wordpress plugin will a blog?

Well, this 3.6.8 template modification works well in 3.7.3:

https://vborg.vbsupport.ru/showthread.php?t=166360


All times are GMT. The time now is 01:56 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01148 seconds
  • Memory Usage 1,739KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)bbcode_code_printable
  • (1)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (5)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete