Mick
Mick

Reputation: 681

Google Translate, translate="no"

I have a Help.htm file for my App which translates reasonably well with Google Translate. I want to mark the menu items as Do Not Translate but none of the HTML tags that i found and tried would work. For the following i used the Google Translate website - it translated where i did not expect! as the following example shows.

Email us at <span class="notranslate">sales at mydomain dot com</span>

Écrivez-nous à <span class="notranslate">ventes à mydomain dot com</span>

I found a couple similar no translate tags but same results. What am I missing here?

Here is a "real life" example, from my help file. I copied this into the Google translate, chose French and clicked on Translate ...

Then from the Options Menu choose one of:
<ul>
    <li><span class="notranslate">Help</span></li>
    <li><span class="notranslate">Browse WWW</span></li>
    <li><span class="notranslate">Load HTML Text</span></li>
    <li><span class="notranslate">Get Connection State</span></li>
</ul>

Here is the :( translation to French ...

Ensuite, dans le menu Options, choisissez l'une des:
<ul>
     <li> <span class = "notranslate"> Aide </ span> </ li>
     <li> <span class = "notranslate"> Parcourir WWW </ span> </ li>
     <li> <span class = "de notranslate"> Load HTML texte </ span> </ li>
     <li> <span class = "de notranslate"> Obtenez Connection État </ span> </ li>

Control K not working consistently for me. Nope, my keyboard is messing up. Time for a new one. Hope you can fix for me :)

Here is mine with <span translate="no">, followed by actual examples from 3 professional HTML websites; none of these work for me ...

Then from the Options Menu choose one of:
<ul>
    <li><span translate="no">Help</span> </li>
    <li><span translate="no">Browse WWW</span></li>
    <li><span translate="no">Load HTML Text</span></li>
    <li><span translate="no">Get Connection State</span></li>
</ul>

<Puis dans le menu Options, choisissez l'une des:
<ul>
     <li> <span translate = "no"> Aide </ span> </ li>
     <li> <span traduire = "no"> Parcourir WWW </ span> </ li>
     <li> <span translate = "no"> Load HTML texte </ span> </ li>
     <li> <span translate = "no"> Obtenez Connection État </ span> </ li>
</ ul>
  1. From the official Google Webmaster Central Blog ...

    Email us at <span class="notranslate">sales at mydomain dot com</span>

    Écrivez-nous à <span class = "notranslate"> ventes à mydomain dot com </span>

  2. From w3schools.com ...

    Don't translate this!

    This can be translated to any language.

    translate = "no"> Ne pas traduire cette!

    Cela peut être traduit en aucune langue.

  3. From w3.org ...

    Using HTML's translate attribute

    Utilisation de HTML translate attribut

I thought at first the above worked but translate in English == translate in French :(

<h1>Using HTML's <span class="kw" translate="no">They Cheated</span> attribute</h1>

<h1> Utilisation de HTML <le span class = "kw" translate = "no"> qu'ils ont triché </ span> attribut </ h1>

Upvotes: 2

Views: 8290

Answers (1)

Mick
Mick

Reputation: 681

I did eventually determine what is the actual problem. It is that the markup will only be recognised as a signal not to translate the text if it is a page of an HTML website that you put through Google Translate. The translator interface at https://translate.google.com doesn't recognise that the pasted text should be interpreted as HTML code.

Upvotes: 3

Related Questions