ExtJS: Utiliser plusieurs fois Ext.OnReady

Utilisant depuis peu le framework Javascript très complet d’ExtJS (3.2.1) au boulot, dans une application PHP assez complexe (basée sur le Zend Framework), une des premières questions qui est arrivée dans l’équipe a été: « Est-il possible de faire des appels multiples à la fonction Ext.OnReady? »

La réponse n’a pas été si simple à trouver. Sur différents forums, les avis étaient partagés (Certains déconseillaient de multiplier les appels à Ext.OnReady, mais n’expliquaient jamais pourquoi).

Finalement, j’ai trouvé ce document, dans lequel il est écrit que la fonction Ext.OnReady enregistre seulement les méthodes à exécuter lorsque les éléments DOM de la page sont chargés.  Ces fonctions sont donc empilées dans l’ordre dans lequel vous les appelez. Question: En faisant appel plusieurs fois à Ext.OnReady, toutes les fonctions seront-elles ajoutées à la même pile?

Réponse: oui.

J’ai testé une page dans laquelle 100 appels (soyons fous) à la fonction Ext.OnReady étaient effectués, chacun de ces appels gérant un objet. Aucun problème signalé, et la page semblait aussi rapide que celle chargeant les 100 objets dans une unique fonction Ext.OnReady.

Cela peut être bon à savoir si vous comptez utilisez ExtJS dans des applications MVC à modules multiples. :)

Les gains des cyclistes du tour de France 2010

Tour de France 2010

Combien gagnent les coureurs du tour de France? Les récompenses sont-elles à la hauteur des efforts concédés?

Voici les chiffres de 2010 (source: Wikipédia).

Les gains gagnés par les premiers du classement général sont beaucoup plus importants que les gains du classement pour les points ou pour les grimpeurs. Nous pouvons voir aussi que le 1er du classement général gagne 9 fois le prix du 5e! Donc cette année, les 5 minutes 27 d’avance de Contador sur Van Den Broeck lui rapportent 400 000€. pas mal!

Encore mieux: ses 8 secondes d’avance sur Shleck lui rapportent 250 000€, soit 31 250€ la seconde… On comprends pourquoi ils s’arrachent sur les sprints!

Voici les chiffres:

Classement Général

  1. 450 000€
  2. 200 000€
  3. 100 000€
  4. 70 000€
  5. 50 000€
  6. 23 000€
  7. 11 500€
  8. 7 600€

Classement Points

  1. 25 000€
  2. 15 000€
  3. 10 000€
  4. 4 000€
  5. 3 500€
  6. 3 000€
  7. 2 500€
  8. 2 000€

Classement Grimpeurs

Idem que pour les points

Classement Jeunes

  1. 20 000€
  2. 15 000€
  3. 10 000€
  4. 5  000€

Classement par équipe

  1. 50 000€
  2. 30 000€
  3. 20 000€
  4. 12 000€
  5. 8 000€

Prix spécial du coureur le plus combatif: 20 000€

Les pires publicités interdites

Via facebook, on m’a partagé un lien assez sympa qui montre les publicités bannies ces dernières années. Certaines sont vraiment très trash! Voici un extrait (soft):

Publicité Slim Fast

Publicité WWF

Publicité Lavazza

Voir l’ensemble des pubs ici.

Categories: General, Sexy Tags: , , ,

Comment dire « Je t’aime » en russe

Russie

Pour dire je t’aime en russe:
Я тебя люблю (Prononciation: Ya tebya Lioubliou).

Conjugaison du verbe aimer. (Любить)
Présent:

Français Russe
J’aime Я люблю (Ya liubliu)
Tu aimes Ты любишь (Ty liubish’)
Il, elle aime он, она, оно любит (On, ona, ono liubit)
Nous aimons My любим (My liubim)
Vous aimez вы любите (Vy liubite)
Ils aiment они любют (oni liubyut)
Categories: Cours de russe Tags: , ,

Comment supprimer son compte Facebook

Voici la super adresse (Que j’ai eu du mal à trouver) pour effacer définitivement son compte Facebook:

http://www.facebook.com/help/contact.php?show_form=delete_account

Les explications en détails ici:

http://www.commentcamarche.net/faq/18274-supprimer-son-compte-facebook

Categories: General Tags:

Cinéma: Les meilleurs répliques de film

Gladiator

Gladiator
Gladiator

Maximus: [removes helmet and turns around to face Commodus] My name is Maximus Decimus Meridius, commander of the Armies of the North, General of the Felix Legions, loyal servant to the true emperor, Marcus Aurelius. Father to a murdered son, husband to a murdered wife. And I will have my vengeance, in this life or the next.

Maximus: What we do in life echoes in eternity.

Maximus: At my signal, unleash hell.

Juba: And now we are Free. I will see you again… but not yet… Not yet!

Robins des Bois, Prince des Voleurs

Robin des Bois, Prince des Voleurs
Robin des Bois, Prince des Voleurs

Marian: How is it, that a once-arrogant young nobleman has found contentment, living rough with the salt of the earth?
Robin Hood: I’ve seen knights in armor panic at the first hint of battle. And I’ve seen the lowliest, unarmed squire pull a spear from his own body, to defend a dying horse. Nobility is not a birthright. It’s defined by one’s actions.

Azeem: Is she worth it?
Robin Hood: Worth dying for.

Azeem: Why did you cut me free, Christian?
Robin Hood: Whatever blood is in your veins, no man deserves to die in there.

Azeem: A wise man once said: « There are no perfect men in the world; only perfect intentions. »

[after Robin defeats Little John, and asks for his father's medallion back]
Little John: Give me your name first.
Robin Hood: Robin of Locksley.
[the camera shifts to Will Scarlet, whose face suddenly clouds over]
Little John: Well, Robin of Locksley, you’ve got balls of solid rock.

The Matrix

Matrix
Matrix

Agent Smith: I’d like to share a revelation that I’ve had during my time here. It came to me when I tried to classify your species and I realized that you’re not actually mammals. Every mammal on this planet instinctively develops a natural equilibrium with the surrounding environment but you humans do not. You move to an area and you multiply and multiply until every natural resource is consumed and the only way you can survive is to spread to another area. There is another organism on this planet that follows the same pattern. Do you know what it is? A virus. Human beings are a disease, a cancer of this planet. You’re a plague and we are the cure.

Cypher: I know what you’re thinking, ’cause right now I’m thinking the same thing. Actually, I’ve been thinking it ever since I got here: Why oh why didn’t I take the BLUE pill?

Tank: So what do you need? Besides a miracle.
Neo: Guns. Lots of guns.

American History X

American History X
American History X

Danny Vinyard: So I guess this is where I tell you what I learned – my conclusion, right? Well, my conclusion is: Hate is baggage. Life’s too short to be pissed off all the time. It’s just not worth it. Derek says it’s always good to end a paper with a quote. He says someone else has already said it best. So if you can’t top it, steal from them and go out strong. So I picked a guy I thought you’d like. ‘We are not enemies, but friends. We must not be enemies. Though passion may have strained, it must not break our bonds of affection. The mystic chords of memory will swell when again touched, as surely they will be, by the better angels of our nature.’

Eternal Sunshine of the Spotless Mind

Eternal Sunshine of the Spotless Mind
Eternal Sunshine of the Spotless Mind

Clementine: I wish you’d stayed.
Joel: I wish I’d stayed, too. NOW I wish I’d stayed. I wish I’d done a lot of things. I wish I’d… I wish I’d stayed… I do.

Fight Club

Fight Club
Fight Club

Narrator: This is your life and it’s ending one minute at a time.

Tyler Durden: You’re not your job. You’re not how much money you have in the bank. You’re not the car you drive. You’re not the contents of your wallet. You’re not your fucking khakis. You’re the all-singing, all-dancing crap of the world.

Tyler Durden: Welcome to Fight Club. The first rule of Fight Club is: you do not talk about Fight Club. The second rule of Fight Club is: you DO NOT talk about Fight Club! Third rule of Fight Club: if someone yells « stop! », goes limp, or taps out, the fight is over. Fourth rule: only two guys to a fight. Fifth rule: one fight at a time, fellas. Sixth rule: the fights are bare knuckle. No shirt, no shoes, no weapons. Seventh rule: fights will go on as long as they have to. And the eighth and final rule: if this is your first time at Fight Club, you have to fight.

Trainspotting

Trainspotting
Trainspotting

Mark « Rent-boy » Renton: I don’t feel the sickness yet, but it’s in the post. That’s for sure. I’m in the junkie limbo at the moment. Too ill to sleep. Too tired to stay awake, but the sickness is on its way. Sweat, chills, nausea. Pain and craving. A need like nothing else I’ve ever known will soon take hold of me. It’s on its way.

Mark « Rent-boy » Renton: We would have injected vitamin C if only they had made it illegal!

Mark « Rent-boy » Renton: [narrating] Choose Life. Choose a job. Choose a career. Choose a family. Choose a fucking big television, choose washing machines, cars, compact disc players and electrical tin openers. Choose good health, low cholesterol, and dental insurance. Choose fixed interest mortgage repayments. Choose a starter home. Choose your friends. Choose leisurewear and matching luggage. Choose a three-piece suit on hire purchase in a range of fucking fabrics. Choose DIY and wondering who the fuck you are on Sunday morning. Choose sitting on that couch watching mind-numbing, spirit-crushing game shows, stuffing fucking junk food into your mouth. Choose rotting away at the end of it all, pissing your last in a miserable home, nothing more than an embarrassment to the selfish, fucked up brats you spawned to replace yourselves. Choose your future. Choose life… But why would I want to do a thing like that? I chose not to choose life. I chose somethin’ else. And the reasons? There are no reasons. Who needs reasons when you’ve got heroin?

Mark « Rent-boy » Renton: Now I’ve justified this to myself in all sorts of ways. It wasn’t a big deal, just a minor betrayal. Or we’d outgrown each other, you know, that sort of thing. But let’s face it, I ripped them off – my so called mates. But Begbie, I couldn’t give a shit about him. And Sick Boy, well he’d done the same to me, if he’d only thought of it first. And Spud, well okay, I felt sorry for Spud – he never hurt anybody. So why did I do it? I could offer a million answers – all false. The truth is that I’m a bad person. But, that’s gonna change – I’m going to change. This is the last of that sort of thing. Now I’m cleaning up and I’m moving on, going straight and choosing life. I’m looking forward to it already. I’m gonna be just like you. The job, the family, the fucking big television. The washing machine, the car, the compact disc and electric tin opener, good health, low cholesterol, dental insurance, mortgage, starter home, leisure wear, luggage, three piece suite, DIY, game shows, junk food, children, walks in the park, nine to five, good at golf, washing the car, choice of sweaters, family Christmas, indexed pension, tax exemption, clearing gutters, getting by, looking ahead, the day you die.

21 Grammes

21 Grammes
21 Grammes

Paul Rivers: How many lives do we live? How many times do we die? They say we all lose 21 grams… at the exact moment of our death. Everyone. And how much fits into 21 grams? How much is lost? When do we lose 21 grams? How much goes with them? How much is gained? How much is gained? Twenty-one grams. The weight of a stack of five nickels. The weight of a hummingbird. A chocolate bar. How much did 21 grams weigh?

Requiem for a dream

Requiem for a Dream
Requiem for a Dream

Harry Goldfarb: [on the phone] Marion… I’ve been thinking about you so much… are you okay?
Marion: When are you coming home?
Harry Goldfarb: Soon.
Marion: When?
Harry Goldfarb: Soon… you holding out alright?
Marion: Harry… can you come today?
Harry Goldfarb: Yeah…
[starts to cry]
Harry Goldfarb: I’ll come… I’ll come today. You just wait for me, alright?
Marion: Harry…
Harry Goldfarb: I’m coming back, Marion.
Marion: Yeah.
Harry Goldfarb: I’m really sorry, Marion…
Marion: I know.

Les Tontons Fligueurs

Les Tontons Flingueurs

Les Tontons Flingueurs

Raoul Volfoni:Non mais t’as déjà vu ça ? en pleine paix, y chante et pis crac, un bourre-pif, mais il est complètement fou ce mec ! Mais moi les dingues j’les soigne, j’m'en vais lui faire une ordonnance, et une sévère, j’vais lui montrer qui c’est Raoul. Au 4 coins d’Paris qu’on va l’retrouver éparpillé par petits bouts façon puzzle… Moi quand on m’en fait trop j’correctionne plus, j’dynamite… j’disperse… et j’ventile…

Fernand Naudine:Les cons, ça ose tout. C’est même à ça qu’on les reconnaît.

Paul Volfoni: Vous avez beau dire, y’a pas seulement que de la pomme, y’a aut’chose. Ça serait pas dès fois de la betterave, hein ?
Fernand Naudin:Si, y’en a aussi.

Categories: Cinema Tags: , ,

Apprendre le russe – Conjugaison du verbe faire / fabriquer (делать)

Russie

Conjugaison du verbe faire / fabriquer. (делать)
Présent:

Français Russe
Je fais Я делаю (Ya delayu)
Tu fais Ты делаешь (Ty delaesh’)
Il, elle fait он, она, оно делает (On, ona, ono delaet)
Nous faisons My делаем (My delaem)
Vous faites вы делаете (Vy delaete)
Ils font они делают (oni delayut)

Apprendre le russe – Conjugaison du verbe pouvoir / être capable

Russie

Aujourd’hui, conjugaison du verbe pouvoir. (мочь)

Présent:

Français Russe
Je peux Я могу́ (Ya mogu)
Tu peux Ты мо́жешь (Ty mozhesh’)
Il, elle peut он, она, оно мо́жет ( on, ona, ono mozhet’)
Nous pouvons My мо́жем ( My mozhem)
Vous pouvez вы мо́жете (Vy mozhete)
Ils peuvent они мо́гут (oni mogut)

Exemple: Je peux conduire une voiture = Ya mogu vodit’ mashinou

Le nouveau maillot de l’équipe de France!

Suite à un changement de sponsor du à la contre-performance de l’équipe de France pour la coupe du monde 2010, voici le nouveau maillot de notre équipe nationale:

Maillot de l'équipe de France 2010

Maillot de l'équipe de France 2010

J’ai trouvé l’image sur une photo de profil Facebook, je trouve ça très bon :)

Le facebook de l’équipe de France

http://uppix.net/e/d/7/f06e30eb43335487892d30ab8d5c5.jpg
Facebook Equipe de France

Apprendre le russe – Conjugaison du verbe « Penser » (думать)

Russie

Aujourd’hui, conjugaison du verbe penser.

Présent:

Français Russe
Je pense Я думаю (Ya dumayu)
Tu penses Ты ду́маешь (Ty dumaesh’)
Il, elle pense он, она, оно ду́мает (On, ona, ono dumaet)
Nous pensons My ду́маем (My dumaem)
Vous pensez вы ду́маете (Vy dumaete)
Ils pensent они ду́мают (oni dumayut)

Téléchargez le son du vuvuzela sur l’Iphone

Application Iphone Vuvuzela 2010

Coupe du monde 2010: L’enfer du vuvuzela

Voilà, si vous rêvez d’exaspérer tous vos amis en les soulant avec le bruit désormais célèbre de ces vuvuzelas, vous pouvez!

Téléchargez l’application (gratuite heureusement) pour Iphone ici.

Pour en savoir plus lisez l’article ci-dessous:

http://www.macplus.net/itrafik/depeche-54180-une-vuvuzela-dans-l-iphone?utm_source=feedburner&utm_medium=feed&utm_campaign=Feed%3A+macplus%2Fdepeches+%28MacPlus+%3A+les+d%C3%A9p%C3%AAches%29

Easy AdSense by Unreal