[BBCode] Google translate

Mods, snippets and styles postet and supported by the users
Forum rules
As the forum title says this is for User Contributions
Post a support request in this forum and you will be banned!
Locked
User avatar
Terr0r
BBCoder V
BBCoder V
Posts: 339
Joined: 04 May 2011, 00:47
BBCodes: 100
Location: The Netherlands
Contact:

[BBCode] Google translate

Post by Terr0r »

Google translate BBCode
Written by Terr0r

BBCode usage

Code: Select all

[ggtranslate][/ggtranslate]
HTML replacement

Code: Select all

<div id="google_translate_element"></div><script>
function googleTranslateElementInit() {
  new google.translate.TranslateElement({
    pageLanguage: 'en',
    multilanguagePage: true,
    layout: google.translate.TranslateElement.InlineLayout.SIMPLE
  }, 'google_translate_element');
}
</script><script src="//translate.google.com/translate_a/element.js?cb=googleTranslateElementInit"></script>
Help line

Code: Select all

Google Translate :[ggtranslate][/ggtranslate]
Example

Code: Select all

[ggtranslate][/ggtranslate]
Demo

Screenshot
ggtranslate.png
Link
Enjoy! :thumb: :coffee:

Greets Terr0r
Last edited by Terr0r on 14 Dec 2011, 18:07, edited 3 times in total.
If you can't fix it with ducktape you ain't using enough
For my MODS and BBCodes or other things that I have made take a look here
User avatar
Tigerman75
BBCoder III
BBCoder III
Posts: 109
Joined: 31 Oct 2011, 14:14
BBCodes: 10
Favourite MOD: Top Staticts
Location: Italy
Contact:

Google translate BBCode

Post by Tigerman75 »

Thanks Terror
To speak with you use the google translator
http://www.graphicforum.altervista.org/ and http://www.bbcodeitalia.com/forum/
User avatar
Solidjeuh
BBCoder IV
BBCoder IV
Posts: 257
Joined: 16 Oct 2011, 02:15
BBCodes: 7
Favourite MOD: Top stats
Location: Aalst / Belgium
Contact:

[BBCode] Google translate

Post by Solidjeuh »

Terr0r wrote:Google translate BBCode
Written by Terr0r

Code: Select all

<div id="google_translate_element"></div><script>
function googleTranslateElementInit() {
  new google.translate.TranslateElement({
    pageLanguage: 'en',
    multilanguagePage: true,
    layout: google.translate.TranslateElement.InlineLayout.SIMPLE
  }, 'google_translate_element');
}
</script><script src="//translate.google.com/translate_a/element.js?cb=googleTranslateElementInit"></script>
Very nice .. written ... SIMPLE :D

Code: Select all

<div id="google_translate_element"></div><script>
function googleTranslateElementInit() {
  new google.translate.TranslateElement({
    pageLanguage: 'en',
    multilanguagePage: true,
    layout: google.translate.TranslateElement.InlineLayout.HORIZONTAL
  }, 'google_translate_element');
}
</script><script src="//translate.google.com/translate_a/element.js?cb=googleTranslateElementInit"></script>
http://xenforo.com/community/threads/ad ... -xf.12422/
Wij promoten UW muziek in ons forum & delen alles via Sociale media!
Mail uw single + hoesje + info naar: info@muziekpromo.net of Solidjeuh@textradio.be
===============
Onze Website: https://www.muziekpromo.net
User avatar
doktornotor
BBCoder IV
BBCoder IV
Posts: 167
Joined: 14 Sep 2011, 23:20
BBCodes: 30
Favourite MOD: Thanks for Posts
Contact:

[BBCode] Google translate

Post by doktornotor »

Well, you cannot invent anything in this area, http://translate.google.com/translate_tools ;)

This would make more sense somewhere in page header, above breadcrumbs or so, rather than making it a bbcode.
Support requests via PM go straight to /dev/null!
User avatar
Arnevb
BBCoder III
BBCoder III
Posts: 98
Joined: 08 Oct 2011, 18:23
BBCodes: 8
Location: Belgium
Contact:

[BBCode] Google translate

Post by Arnevb »

So all he did is making up the other fields:
[ggtranslate][/ggtranslate]? :O

"Written By Terr0r"... What? You didn't wrote that? Google did?
User avatar
doktornotor
BBCoder IV
BBCoder IV
Posts: 167
Joined: 14 Sep 2011, 23:20
BBCodes: 30
Favourite MOD: Thanks for Posts
Contact:

[BBCode] Google translate

Post by doktornotor »

:lol: :roll:

Well, to make something productive out of this, this is what I put on my forum.

On prosilver, this should fit next to the navlinks stuff, i.e.

Open: overall_header.html
Find:

Code: Select all

<li class="rightside"><a href="#" onclick="fontsizeup(); return false;" onkeypress="return fontsizeup(event);" class="fontsize" title="{L_CHANGE_FONT_SIZE}">{L_CHANGE_FONT_SIZE}</a></li>
Add before:

Code: Select all

<li class="rightside"><span id="google_translate_element"></span></li>
<script type="text/javascript">
// <![CDATA[
function googleTranslateElementInit() {
	new google.translate.TranslateElement({
		pageLanguage: 'en',
		autoDisplay: false,
		gaTrack: true,
		gaId: 'UA-XXXXXXXX-Y',
		layout: google.translate.TranslateElement.InlineLayout.SIMPLE
	}, 'google_translate_element');
}
// ]]>
</script>
<script type="text/javascript" src="//translate.google.com/translate_a/element.js?cb=googleTranslateElementInit"></script>
Best place for subsilver2 seems to be right above <!-- INCLUDE breadcrumbs.html --> in overall_header.html.

Code: Select all

<div><span style="float: {S_CONTENT_FLOW_BEGIN};" id="google_translate_element"></span></div>
<script type="text/javascript">
// <![CDATA[
function googleTranslateElementInit() {
	new google.translate.TranslateElement({
		pageLanguage: 'en',
		autoDisplay: false,
		gaTrack: true,
		gaId: 'UA-XXXXXXXX-Y',
		layout: google.translate.TranslateElement.InlineLayout.SIMPLE
	}, 'google_translate_element');
}
// ]]>
</script>
<script type="text/javascript" src="//translate.google.com/translate_a/element.js?cb=googleTranslateElementInit"></script>
P.S. If you are using GA, replace the UA-XXXXXXXX-Y as needed, if not, remove that line and change the previous one to gaTrack: false.
Support requests via PM go straight to /dev/null!
Locked