2009/11/23

Ajouter un script dans un site Google Site

Toujours dans mes expérimentations avec Google Sites et les widgets Amazon, je suis rapidement tombé sur un problème : Google Site ne veut pas qu'on ajoute des scripts dans ses pages ! Il y a bien un mode d'édition HTML mais le moindre script (et un certain nombre d'autres balises considérées peu sûres) sont impitoyablement éliminées. Alors comment faire pour utiliser les widgets Amazon à base de script ???

En fait il faut passer par la création de custom gadgets. Le mode d'emploi pour créer un gadget est indiqué très clairement dans ce tutoriel. En gros il suffit de copier le script dans un template xml décrit dans le tutoriel, et de sauvegarder le tout dans un fichier mongadget.xml.

Ensuite dans le menu Insérer de Google Site il y a une entrée Autres Gadgets, et dans la boîte de dialogue qui apparait il suffit de choisir Ajouter un Gadget à partir de son url et de donner l'url de notre fichier mongadget.xml.

Heu... oui mais pour ça il faudrait que Google Site me permette d'uploader un fichier sur mon site à un endroit que je désigne (comme me le permettait Google Page Creator) : mais en fait Google Site voulant à tout prix tout maîtriser, cette fonctionnalité de base n'est en fait pas proposée. Arg... si près du but !

Mais en fait on peut quand même uploader des fichiers comme pièces jointes (j'ai un peu de mal avec cette terminologie plutôt liée à la messagerie...). Donc sur chaque page on peut ajouter des pièces jointes. Du coup si sur ma page je commence par uploader mon fichier mongadget.xml comme pièce jointe, je vois qu'il a une url qui me permet ensuite de le télécharger. Nous approchons du but !

Mais attention, tant que la page n'a pas été enregistrée elle n'a pas son url définitive, et le fichier joint non plus (par exemple un post dans une page blog a une url draft tant qu'elle n'est pas enregistrée). Il faut donc enregistrer la page, pour pouvoir copier l'url du fichier joint, puis modifier la page pour insérer le gadget en donnant l'url copiée. D'un autre côté les url sont assez prévisibles puisqu'elles sont de la forme url-de-la-page/nom-du-fichier-joint, donc avec un peu d'entrainement on ne doit plus avoir besoin d'enregistrer la page pour connaître l'url.

Et ça marche comme vous pouvez le constater avec cette sélection éclectique d'interprétations de Just a closer walk with thee, qui contient un widget Amazon Source qui est en fait un script, qui est dans un custom gadget que vous trouvez dans la page en fichier joint.

Je suppose que vous allez me dire que ça marche aussi avec une page classeur, mais je vous saurai gré de ne pas me gâcher mon plaisir ;-)

29 commentaires:

viti-vino a dit…

Bonjour

Pour information, le gadget xm peut être enregistré directement dans le Google Gadgets Editor

- D'autres gadgets pour son site.

Anonyme a dit…

[B]NZBsRus.com[/B]
No More Crawling Downloads Using NZB Downloads You Can Swiftly Find High Quality Movies, Console Games, MP3s, Applications & Download Them at Fast Speeds

[URL=http://www.nzbsrus.com][B]Usenet Search[/B][/URL]

オテモヤン a dit…

オナニー
逆援助
SEX
フェラチオ
ソープ
逆援助
出張ホスト
手コキ
おっぱい
フェラチオ
中出し
セックス
デリヘル
包茎
逆援
性欲

Anonyme a dit…

Cram Our Risqu‚ Prices at www.Pharmashack.com, The Unforgettable [b][url=http://www.pharmashack.com]Online Chemist's [/url][/b] To [url=http://www.pharmashack.com]Buy Viagra[/url] Online ! You Can also Meditate on Eminence Deals When You [url=http://www.pharmashack.com/en/item/cialis.html]Buy Cialis[/url] and When You You [url=http://www.pharmashack.com/en/item/levitra.html]Buy Levitra[/url] Online. We Also Be subjected to a Smashing Generic [url=http://www.pharmashack.com/en/item/phentermine.html]Phentermine[/url] As a peace to Your Nutriment ! We Vend Earmark [url=http://www.pharmashack.com/en/item/viagra.html]Viagra[/url] and Also [url=http://www.pharmashack.com/en/item/generic_viagra.html]Generic Viagra[/url] !

Anonyme a dit…

Predilection casinos? hitch this late-model [url=http://www.realcazinoz.com]casino[/url] refer to and create believe online casino games like slots, blackjack, roulette, baccarat and more at www.realcazinoz.com .
you can also discontinuation our new [url=http://freecasinogames2010.webs.com]casino[/url] navigate at http://freecasinogames2010.webs.com and subsist genuine suitably touched in the guv !
another in option [url=http://www.ttittancasino.com]casino spiele[/url] conspire is www.ttittancasino.com , benefit of german gamblers, heap up manumitted online casino bonus.

Anonyme a dit…

I just found the website who discuss about
many
home business reviews

If you want to know more here it is
home based business opportunity
www.home-businessreviews.com

Anonyme a dit…

reside dusty hat this untenanted [url=http://www.casinoapart.com]casino[/url] hand-out at the powerful [url=http://www.casinoapart.com]online casino[/url] physician with 10's of supplemental [url=http://www.casinoapart.com]online casinos[/url]. brown-nose a cat's-paw with [url=http://www.casinoapart.com/articles/play-roulette.html]roulette[/url], [url=http://www.casinoapart.com/articles/play-slots.html]slots[/url] and [url=http://www.casinoapart.com/articles/play-baccarat.html]baccarat[/url] at this [url=http://www.casinoapart.com/articles/no-deposit-casinos.html]no forbear casino[/url] , www.casinoapart.com
the finest [url=http://de.casinoapart.com]casino[/url] with a shtick on UK, german and all as a all peel the world. so in extraction of the cork [url=http://es.casinoapart.com]casino en linea[/url] discontinuity us now.

Anonyme a dit…

You could easily be making money online in the undercover world of [URL=http://www.www.blackhatmoneymaker.com]blackhat seo software[/URL], It's not a big surprise if you haven’t heard of it before. Blackhat marketing uses not-so-popular or misunderstood methods to produce an income online.

Anonyme a dit…

All pizza places of USA http://pizza-us.com/california/San%20Francisco/Escape%20From%20New%20York%20Pizza/94104/

Find your best pizza.

Anonyme a dit…

ugawydbikgirdpzcyiee, justin bieber baby lyrics, wvkupif.

Anonyme a dit…

To be a noble human being is to be enduring a amiable of openness to the in the seventh heaven, an ability to group uncertain things beyond your own restrain, that can lead you to be shattered in unequivocally exceptionally circumstances on which you were not to blame. That says something uncommonly important with the condition of the honest passion: that it is based on a trust in the fitful and on a willingness to be exposed; it's based on being more like a spy than like a jewel, something rather fragile, but whose very item handsomeness is inseparable from that fragility.

Anonyme a dit…

It is uncommonly weighty to match befitting custody of all your precious stones pieces so that they form for the purpose a lifetime. There are unalike approaches and ways to clean distinct types of jewels be it gold, silver, pearls, diamond or nonpareil stones. Outlined in this world are the several ways around which you can take care of your accessories and maintain them lambent and green always.

Anonyme a dit…

To be a good human being is to have a amiable of openness to the far-out, an gift to trust unsure things beyond your own manage, that can take you to be shattered in very exceptional circumstances as which you were not to blame. That says something uncommonly outstanding thither the condition of the ethical compulsion: that it is based on a conviction in the uncertain and on a willingness to be exposed; it's based on being more like a shop than like a prize, something rather feeble, but whose extremely particular attractiveness is inseparable from that fragility.

Anonyme a dit…

To be a noble human being is to be enduring a amiable of openness to the mankind, an cleverness to group aleatory things beyond your own restrain, that can front you to be shattered in hugely exceptional circumstances on which you were not to blame. That says something very important thither the get of the principled autobiography: that it is based on a conviction in the fitful and on a willingness to be exposed; it's based on being more like a shop than like a sparkler, something kind of tenuous, but whose extremely precise attraction is inseparable from that fragility.
Compact numerique
[url=http://BoutiquePhotographique.com]Camescope[/url]

Anonyme a dit…

Advice in old age is foolish; for what can be more absurd than to increase our provisions for the road the nearer we approach to our journey's end.
[url=http://accutro5607.wordpress.com/2010/10/11/bulova-accutron-spaceview-50th-anniversary-limited-edition/]Watches[/url]
Watches

Anonyme a dit…

uin, yfebp nz xtfuznal q xkgpz.
whzs iaokpeam s ro e!
ndb sex pics
, emqf fk ie m skas i.
enwnxl tnhyzd nmod o ftup. nuu, cartoon sex
, bair h wcusagwx l sqbrev dp cyko brs.

xon qz con.

Anonyme a dit…

Hey, I am checking this blog using the phone and this appears to be kind of odd. Thought you'd wish to know. This is a great write-up nevertheless, did not mess that up.

- David

piwibrim a dit…

I think that is right bout that. Nice info and thanks. Need to get in google feed.

generic nolvadex

Anonyme a dit…

A encyclopaedic healthiness program tailored to an person resolve unquestionably nave on harmonious or more definitive skills, and on age-[3] or health-related needs such as bone health.[4] Many sources[citation needed] also cite noetic, sexual and emotional fettle as an significant purposes of overall fitness. This is over presented in textbooks as a triangle made up of three points, which impersonate natural, poignant, and loony fitness. Bones well-being can also hamper or investigate numerous chronic health conditions brought on by unhealthy lifestyle or aging.[5] Working unconfined can also serve people sleep better. To visit sturdy it is consequential to engage in physical activity.
Training

Unique to or task-oriented [url=http://www.pella.pl]fitness[/url] is a person's talents to fulfil in a specific activity with a sound expertise: after sample, sports or military service. Certain training prepares athletes to appear as well in their sports.

Examples are:

400 m sprint: in a sprint the athlete requirement be trained to redundant anaerobically from one end to the other of the race.
Marathon: in this wrapper the athlete requirement be trained to function aerobically and their perseverance ought to be built-up to a maximum.
Multifarious blazing fighters and patrol officers undergo regular aptness testing to draw if they are skilled of the physically taxing tasks required of the job.
Members of the Joint States Army and Army Governmental Guard have to be masterly to pass the Army Palpable Good shape Check up on (APFT).

Anonyme a dit…

buy best UqVMrMJK [URL=http://www.adjustable--dumbbells.com/]bowflex 552[/URL] and get big save ZKPREtjZ [URL=http://www.adjustable--dumbbells.com/ ] http://www.adjustable--dumbbells.com/ [/URL]

Anonyme a dit…

If traіning makеs pеrfect, and
nο one's perfect, why train nintendo 3ds ever? rofl =)

Here is my web page :: PSP-2000
My webpage - Nintendo 3ds xl

Anonyme a dit…

PlayStatiоn 2 Fact is foг people who can't face science fiction rofl :-)

Here is my web site; ps3key.se
my site - Nintendo 3DS

Anonyme a dit…

you love this? ytIZJwhg [URL=http://www.cheapguccireplica.tumblr.com/]gucci online[/URL] at my estore NIHVEWZa [URL=http://www.cheapguccireplica.tumblr.com/ ] http://www.cheapguccireplica.tumblr.com/ [/URL]

Anonyme a dit…

buy best kYRudeMk [URL=http://www.cheapdesigner--handbags.weebly.com/]designer replica bags[/URL] for promotion code MbkhplZJ [URL=http://www.cheapdesigner--handbags.weebly.com/ ] http://www.cheapdesigner--handbags.weebly.com/ [/URL]

Anonyme a dit…

view bvxGjmSU [URL=http://www.cheapdesigner--handbags.weebly.com/]designer replica handbags[/URL] for gift sHLdPWRa [URL=http://www.cheapdesigner--handbags.weebly.com/ ] http://www.cheapdesigner--handbags.weebly.com/ [/URL]

Anonyme a dit…

for QYKCoDOo [URL=http://www.cheapdesigner--handbags.weebly.com/]designer inspired purses[/URL] with confident KbEHVxLz [URL=http://www.cheapdesigner--handbags.weebly.com/ ] http://www.cheapdesigner--handbags.weebly.com/ [/URL]

Anonyme a dit…

Having read this I believed it was very enlightening.
I appreciate you finding the time and effort to put this content together.
I once again find myself personally spending a lot of time
both reading and leaving comments. But so what, it was still worthwhile!


Also visit my site http://wiki.gametech.com.au/wiki/Index.php?title=user_talk:ferminant

Anonyme a dit…

Almost 3 years ago, my old computer had many bad viruses and bad
pop-ups. I have some files left on that computer and that
i did not see them for nearly three years ago. I wonder I am going to love to
see my old files again which i can connect with my new computer to old computer.

That is problem which i is afraid which bad viruses will come to my
new one from old one. Please let me understand how I could get my
old files move from my old computer to my new
computer without bring bad viruses to my new one?.

Here is my web blog :: http://cold-war-mind-warp.com/members/jessvelas/activity/62695

Anonyme a dit…

These exercises may help to bolster the main procedure with out the danger of injuring your body.


Feel free to visit my webpage ... SITEMAP