MediaWiki discusión:Gadget-traductor-google.js

Contenido de la página no disponible en otros idiomas.
De Wikipedia, la enciclopedia libre

GoogleTrans Gadget update due to mediawiki v1.17 update and for IE9 support[editar]

Hi there,

Sorry about the English.

When mediaWiki v1.17 comes on board no Javascript will be able to use document.write(...), which the running version of GoogleTrans Gadget does.

I've put an updated version of GoogleTrans for the eswiki in my account. You can reference it by the Javascript:

importScript("Usuario:Endo999/GoogleTrans.js");

This version also works for ie9 (which the current version running on eswiki now won't!).

There are numerous other improvements.

As I recall we had some problems with the eswiki using importScript and you had to directly call the script with importScriptURI(). This may have to be done again, but perhaps not.

Please contact me on my enwiki account if you wish anything else done. The new version in the eswiki will not need the SHIFT key used to bring up a popup, except if you explicitly ask for this in the tab script.

Usuario:Endo999/GoogleTrans.js is the sole file and code needed for the gadget. No other code in the actual gadget file is needed other than

importScript("Usuario:Endo999/GoogleTrans.js");

importscript is no longer supported[editar]

Hi there,

importScript(); is no longer supported so the GoogleTrans gadget is no longer loading on eswiki.

https://www.mediawiki.org/wiki/Thread:Talk:ResourceLoader/JavaScript_Deprecations/importScript(),_importStylesheet()

has a discussion on this issue.

the ptwiki has a working googletrans gadget with the line in the gadget:

  1. Redirecionamento MediaWiki:Gadget-traductor-google.js

but I was not able to make this work on the eswiki vector.js file.

You could put the full code for the gadget at:

User:Endo999/GoogleTrans.js

into the actual gadget file.

You can contact me on the enwiki under Endo999 if you wish further communication.