Disable translating of a part of my text
Nov 20, 2018 11:29 am by Ellie741
Nov 20, 2018 11:29 am by Ellie741
I'm working on an admin page to create post for a blog. I have a french textarea and an english textarea. So, for those who cannot translate by there own, I created a button "translate with google":
<a id="tr_textefr" href="http://translate.google.fr/#fr/en/" target="_blank">
Traduire avec Google</a>
And my french textarea has a javascript function called onkeyup :
function translate(what){
var button = "tr_" + what;
var textarea = document.getElementById(what);
var google = "http://translate.google.fr/#fr/en/" + textarea.value;
document.getElementById(button).setAttribute('href', google);
}
For exemple, if I write "Voulez-vous coucher avec moi ce soir ?", it will change the href attribute for "http://translate.google.fr/#fr/en/Voulez-vous coucher avec moi ce soir ?". The link will redirect at the translated version of my text (by google translate).
This code works fine by the way. The thing is that I could have sometimes bbcode inside my text: "Voulez-vous coucher avec moi ce soir ?".
So, is there a way with google translate to disable translating of some words or sentences ? For exemple, I don't wanna translate the words between two @ : "Voulez-vous @@coucher@@ avec moi ce soir ?"
Re: Disable translating of a part of my text
Nov 20, 2018 2:41 pm by Edvard
Nov 20, 2018 2:41 pm by Edvard
Hi,
Your question is not related to GTranslate.
We provide full website translation, you can find out more at https://gtranslate.io
Thanks!
Re: Disable translating of a part of my text
Nov 23, 2018 7:19 am by Ellie741
Nov 23, 2018 7:19 am by Ellie741
Hi,
Your question is not related to GTranslate.
We provide full website translation, you can find out more at https://gtranslate.io" rel="nofollow" target="_blank" rel="nofollow" target="_blank
Thanks!
Ohh! Is that so?
I was having problem using Gtranslate. So, i posted my query here, i thought i will get some help here. i apologize for this did. thanks!
Re: Disable translating of a part of my text
Nov 26, 2018 10:35 am by Yana
Nov 26, 2018 10:35 am by Yana
you are welcome
SIMILAR TOPICS
Onloading the plugin quickly flashes up flags and text names | Feb 7, 2019 3:29 pm | Replies: 1 | Post by: brobertson |
Not translating slug while switching language (After update) | Nov 10, 2016 3:53 am | Replies: 5 | Post by: lyhong |
Disable for one Page | Sep 26, 2018 11:00 am | Replies: 3 | Post by: AxolonERP |
Gtranslate changing some numbers to text in calendar | Apr 13, 2018 4:38 pm | Replies: 1 | Post by: pazaz |
Remove <h1>Original Text</h1> | Sep 18, 2015 2:21 pm | Replies: 6 | Post by: adeblath |