6V8 - Production of my Mind

Home page > For your Computer > Greasemonkey > Greasemonkey: Convertisseur de monnaie Yahoo! Finance

Greasemonkey: Convertisseur de monnaie Yahoo! Finance

 
Après le convertisseur que j’avais développé il y a longtemps pour Dashboard, j’avais besoin d’un outil pour m’aider à savoir la valeur des prix étrangers présent sur les sites web que je visite.
13 January 2006, by Mortimer

J’ai donc créé mon premier script pour greasemonkey pour que Firefox face tout cela automatiquement pour moi.

Inline with another style {JPEG} Ce n’est pas le premier du genre. Celui-ci est intéressant en particulier, mais pour l’exercice, je voulais en développer un qui utilise Yahoo! Finance.

1Installation

  1. Installer greasemonkey,
  2. cliquer avec le bouton droit de la souris sur l’icône juste en dessous et sélectionner «install user script...».
greasemonkey - 7.2 kb
504 download(s) since 25 July 2007

2Capture d’écran

Conversion on Ebay

3Configuration

Quand vous chargez une page pour la première fois après avoir installer le script, il vous demandera quelle est votre monnaie. Vous pouvez choisir parmi toutes celles-ci.

Si vous voulez changer cela plus tard, il vous suffit d’aller dans le menu:

tools -> user script commands -> Change currency conversion

4Style

Vous pouvez personnaliser facilement le style de la conversion en ajoutant dans votre fichier chrome/userContent.css (dans votre répertoire profile de Firefox) une déclaration css pour le sélecteur a.GM_CurrencyConvertion.

Par exemple:


a.GM_CurrencyConvertion {
 font-size: 80%;
 text-decoration: none;
 color: inherit;
 margin: .5em;
} !important;

5Mise à jour

Ce script est compatible avec celui de mise à jour automatique. Si vous l’avez installé, alors la mise à jour du convertisseur se fera automatiquement.

6Todo

  1. Localisation
  2. Gérer les symboles (comme $) qui correspondent à plus d’une monnaie.

7Bugs et Souhaits

Utiliser le forum.

8Historique

v0.4

  • J’ai ajouté le support pour beaucoup plus de symbole unicode. Malheureusement, un symbole correspondent parfois à plusieurs monnaies [1]. J’ai sélectionné une monnaie au hasard par symbole, si vous voulez changer cela, vous devez aller dans le fichier .js commenter/décommenter les lignes qu’il faut dans la liste des symboles.

v0.2

  • Correction de la classe des insertions qui n’était pas fixée correctement
  • Correction de l’attente des conversions s’il n’y avait que des symboles sur la page
  • Passage en pseudo objet avec un code un peu plus "propre"
  • ajout de la compatibilité avec le script d’auto-update greasemonkey

9Table des Monnaies

Table des monnaies disponibles
enter this code Currency
USDU.S. Dollar
CADCanadian Dollar
EUREuro
AFAAfghanistan Afghani
ALLAlbanian Lek
DZDAlgerian Dinar
ARSArgentine Peso
AWGAruba Florin
AUDAustralian Dollar
BSDBahamian Dollar
BHDBahraini Dinar
BDTBangladesh Taka
BBDBarbados Dollar
BYRBelarus Ruble
BZDBelize Dollar
BMDBermuda Dollar
BTNBhutan Ngultrum
BOBBolivian Boliviano
BWPBotswana Pula
BRLBrazilian Real
GBPBritish Pound
BNDBrunei Dollar
BGNBulgarian Lev
BIFBurundi Franc
KHRCambodia Riel
CVECape Verde Escudo
KYDCayman Islands Dollar
XOFCFA Franc
XAFCFA Franc
CLPChilean Peso
CNYChinese Yuan
COPColombian Peso
KMFComoros Franc
CRCCosta Rica Colon
HRKCroatian Kuna
CUPCuban Peso
CYPCyprus Pound
CZKCzech Koruna
DKKDanish Krone
DJFDijibouti Franc
DOPDominican Peso
XCDEast Caribbean Dollar
ECSEcuador Sucre
EGPEgyptian Pound
SVCEl Salvador Colon
ERNEritrea Nakfa
EEKEstonian Kroon
ETBEthiopian Birr
FKPFalkland Islands Pound
FJDFiji Dollar
GMDGambian Dalasi
GHCGhanian Cedi
GIPGibraltar Pound
XAUGold ounce
GTQGuatemala Quetzal
GNFGuinea Franc
GYDGuyana Dollar
HTGHaiti Gourde
HNLHonduras Lempira
HKDHong Kong Dollar
HUFHungarian Forint
ISKIceland Krona
INRIndian Rupee
IDRIndonesian Rupiah
IRRIran Rial
IQDIraqi Dinar
ILSIsraeli Shekel
JMDJamaican Dollar
JPYJapanese Yen
JODJordanian Dinar
KZTKazakhstan Tenge
KESKenyan Shilling
KRWKorean Won
KWDKuwaiti Dinar
LAKLao Kip
LVLLatvian Lat
LBPLebanese Pound
LSLLesotho Loti
LRDLiberian Dollar
LYDLibyan Dinar
LTLLithuanian Lita
MOPMacau Pataca
MKDMacedonian Denar
MGFMalagasy Franc
MWKMalawi Kwacha
MYRMalaysian Ringgit
MVRMaldives Rufiyaa
MTLMaltese Lira
MROMauritania Ougulya
MURMauritius Rupee
MXNMexican Peso
MDLMoldovan Leu
MNTMongolian Tugrik
MADMoroccan Dirham
MZMMozambique Metical
MMKMyanmar Kyat
NADNamibian Dollar
NPRNepalese Rupee
ANGNeth Antilles Guilder
NZDNew Zealand Dollar
NIONicaragua Cordoba
NGNNigerian Naira
KPWNorth Korean Won
NOKNorwegian Krone
OMROmani Rial
XPFPacific Franc
PKRPakistani Rupee
XPDPalladium Ounce
PABPanama Balboa
PGKPapua New Guinea Kina
PYGParaguayan Guarani
PENPeruvian Nuevo Sol
PHPPhilippine Peso
XPTPlatinum Ounce
PLNPolish Zloty
QARQatar Rial
ROLRomanian Leu
RUBRussian Rouble
RWFRwanda Franc
WSTSamoa Tala
STDSao Tome Dobra
SARSaudi Arabian Riyal
SCRSeychelles Rupee
SLLSierra Leone Leone
XAGSilver Ounce
SGDSingapore Dollar
SKKSlovak Koruna
SITSlovenian Tolar
SBDSolomon Islands Dollar
SOSSomali Shilling
ZARSouth African Rand
LKRSri Lanka Rupee
SHPSt Helena Pound
SDDSudanese Dinar
SRGSurinam Guilder
SZLSwaziland Lilageni
SEKSwedish Krona
CHFSwiss Franc
SYPSyrian Pound
TWDTaiwan Dollar
TZSTanzanian Shilling
THBThai Baht
TOPTonga Pa’anga
TTDTrinidad and Tobago Dollar
TNDTunisian Dinar
TRLTurkish Lira
AEDUAE Dirham
UGXUgandan Shilling
UAHUkraine Hryvnia
UYUUruguayan New Peso
VUVVanuatu Vatu
VEBVenezuelan Bolivar
VNDVietnam Dong
YERYemen Riyal
YUMYugoslav Dinar
ZMKZambian Kwacha
ZWDZimbabwe Dollar
Date of online publication: 13 January 2006
last-update: 14 February 2006
All the versions of this article:
Forum messages 3
visits:
8522

Creative Commons Attribution NonCommercial ShareAlike 2.5  License

notes

[1] Chilean Peso vs Cuban Peso, vs... par exemple

Make a Donation

No donation has been made for this project yet. Why not be the first one?.

Donation don't have to be big to make a difference. I already received donations ranging from 0.50£ to 10£ and all of them made me happy. Think of it, if the thousand users of these tools made a small donation, it would not make a big difference to them, but it would to me.

You will probably enjoy using what you download from this website and if so, you can decide to make a donation. Making a donation is optional but will help to develop new tools and support the existing code.

All the software, scripts and other tools distributed on this web site are distributed under open source licenses and are available to download for free. Making the code free and available to all doesn't means it's of lower quality. The tools provided here are fully functional and their author invested some of his personal time to develop them and provide support to their users.

Think about it.

 

Reply to this article

3 Forum messages

 

The most read articles

Photos On Flickr

 
©
Pierre Andrews
York, uk
| Site Map | Site created with SPIP 1.9.2d [11132] | RSS | template by IZO, Mortimer. |
created published documented and claimed
created published documented and claimed
created published documented and claimed
created published documented and claimed
created published documented and claimed