<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Mohammed CHERIFI &#187; jquery</title>
	<atom:link href="http://www.mcherifi.org/tag/jquery/feed" rel="self" type="application/rss+xml" />
	<link>http://www.mcherifi.org</link>
	<description>Another Web Developper Blog!</description>
	<lastBuildDate>Tue, 31 Jan 2012 18:42:15 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>symfony: Utiliser sfWidgetFormJQueryDate avec sfFormExtraPlugin</title>
		<link>http://www.mcherifi.org/developpement-web/symfony/symfony-utiliser-sfwidgetformjquerydate-avec-sfformextraplugin.html</link>
		<comments>http://www.mcherifi.org/developpement-web/symfony/symfony-utiliser-sfwidgetformjquerydate-avec-sfformextraplugin.html#comments</comments>
		<pubDate>Thu, 01 Apr 2010 17:45:27 +0000</pubDate>
		<dc:creator>Mohammed CHERIFI</dc:creator>
				<category><![CDATA[Symfony]]></category>
		<category><![CDATA[datepicker]]></category>
		<category><![CDATA[jquery]]></category>
		<category><![CDATA[jqueryui]]></category>
		<category><![CDATA[sfFormExtraPlugin]]></category>
		<category><![CDATA[sfWidgetFormJQueryDate]]></category>
		<category><![CDATA[symfony datepicker]]></category>

		<guid isPermaLink="false">http://www.mcherifi.org/?p=665</guid>
		<description><![CDATA[Tweet
Vu le très peu de documentation que j&#8217;ai pu trouvé au sujet du plugin sfFormExtraPlugin de symfony, voici un guide rapide qui vous permettra d&#8217;installer le plugin sfFormExtraPlugin et pouvoir afficher un calendrier pour les champs de type date grâce au widget sfWidgetFormJQueryDate, voici donc les étapes à suivre:
1 &#8211; Installer le plugin sfFormExtraPlugin
En mode [...]]]></description>
			<content:encoded><![CDATA[<a href="http://twitter.com/share" class="twitter-share-button" data-url="http://www.mcherifi.org/developpement-web/symfony/symfony-utiliser-sfwidgetformjquerydate-avec-sfformextraplugin.html" data-text="symfony: Utiliser sfWidgetFormJQueryDate avec sfFormExtraPlugin" data-count="horizontal">Tweet</a><p><a href="http://www.mcherifi.org/wp-content/uploads/2010/04/sfWidgetFormJQueryDate.jpg"><img src="http://www.mcherifi.org/wp-content/uploads/2010/04/sfWidgetFormJQueryDate.jpg" alt="" title="Résultat" width="666" height="208" class="aligncenter size-full wp-image-672" /></a></p>
<p>Vu le très peu de documentation que j&#8217;ai pu trouvé au sujet du plugin sfFormExtraPlugin de symfony, voici un guide rapide qui vous permettra d&#8217;installer le plugin sfFormExtraPlugin et pouvoir afficher un calendrier pour les champs de type date grâce au widget sfWidgetFormJQueryDate, voici donc les étapes à suivre:<br />
<h2>1 &#8211; Installer le plugin sfFormExtraPlugin</h2>
<p>En mode console, positionnez vous sur le dossier d&#8217;installation du projet et exécuter : </p>
<pre class="brush: plain">./symfony plugin:install sfFormExtraPlugin</pre>
<h2>2 &#8211; Télecharger et mettre en place les librairies jQuery nécessaire</h2>
<p>Malheureusement le plugin sfFormExtraPlugin n&#8217;inclue pas les librairies externes nécessaire au fonctionnement, il faut le faire à la main!</p>
<p>il faut donc télécharger JQuery et <acronym title="JQuery User Interface">JQuery UI</acronym>:</p>
<ul>
<li>Allez sur le site de <a href="http://jqueryui.com/download" target="_blank">jQuery UI</a></li>
<li>Dans la liste des composants déchochez toutes les cases sauf  Core et Datepicker</li>
<li>Sélectionner le thème qui vous convient à droite et cliquez Télécharger</li>
</ul>
<h2>3 &#8211; Placé les fichiers téléchargés dans le dossier web et modifier le fichier view.yml</h2>
<p>Décompresser jquery-ui-1.8custom.zip et copier les fichiers décompresser vers le dossier web ainsi:</p>
<ul>
<li>js/jquery-1.4.2.min.js et js/jquery-ui-1.8.custom.min.js dans le dossier /web/js</li>
<li>css/jquery-ui-1.8.custom.css dans le dossier /web/css</li>
<li>renommer le dossier css/theme/images/ en jquery-ui-images et mettez le dans /web/images/</li>
<li>Ouvrez le fichier /web/css/jquery-ui-1.8.custom.css et remplacer &laquo;&nbsp;images/&nbsp;&raquo; par &laquo;&nbsp;../images/jquery-ui-images/&nbsp;&raquo; pour corriger le chemin vers les images</li>
<li><a href="http://www.mcherifi.org/wp-content/uploads/2010/04/calendar.png" target="_blank">calendar.png</a> une petite icône qu&#8217;on affiche à coté du champs pour faire joli :p (à mettre dans /web/images/) </li>
</ul>
<p>Maintenant il faut inclure les fichiers javascript et css dans view.yml de notre application (par exemple /apps/backend/config/view.yml) :</p>
<p><strong>Ajout du fichier javascript</strong></p>
<pre class="brush: plain">
    javascripts:    [jquery-1.4.2.min.js, jquery-ui-1.8.custom.min.js]
</pre>
<p><strong>Ajout du fichier css</strong></p>
<pre class="brush: plain">
    stylesheets:    [jquery-ui-1.8.custom.css]
</pre>
<h2>4 &#8211; Mise en place du Widget dans la classe du formulaire</h2>
<pre class="brush: php">
class PrescripteursForm extends BasePrescripteursForm
{
  public function configure()
  {
    $this-&gt;widgetSchema[&#039;date_debut&#039;] = new sfWidgetFormJQueryDate(array(&#039;image&#039;=&gt;&#039;/images/calendar.png&#039;));
    $this-&gt;widgetSchema[&#039;date_fin&#039;] = new sfWidgetFormJQueryDate(array(&#039;image&#039;=&gt;&#039;/images/calendar.png&#039;));
  }
}
</pre>
<p>Et le tour est joué ;) ça devrai ressembler à ça : </p>
<p><a href="http://www.mcherifi.org/wp-content/uploads/2010/04/datewidgetOK.jpg"><br />
<img src="http://www.mcherifi.org/wp-content/uploads/2010/04/datewidgetOK.jpg" alt="" title="datewidgetOK" width="391" height="214" class="aligncenter size-full wp-image-669" /></a></p>



Partager cet article:


	<a rel="nofollow"  target="_blank" href="http://www.mcherifi.org/wp-content/plugins/sociable/awesmate.php?c=twitter&t=http%3A%2F%2Fwww.mcherifi.org%2Fdeveloppement-web%2Fsymfony%2Fsymfony-utiliser-sfwidgetformjquerydate-avec-sfformextraplugin.html&d=http://twitter.com/home?status=symfony%3A%20Utiliser%20sfWidgetFormJQueryDate%20avec%20sfFormExtraPlugin%20-%20TARGET" title="Twitter"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/twitter.png" title="Twitter" alt="Twitter" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.mcherifi.org/wp-content/plugins/sociable/awesmate.php?c=facebook-post&t=http%3A%2F%2Fwww.mcherifi.org%2Fdeveloppement-web%2Fsymfony%2Fsymfony-utiliser-sfwidgetformjquerydate-avec-sfformextraplugin.html&d=http://www.facebook.com/share.php?u=TARGET%26t=symfony%3A%20Utiliser%20sfWidgetFormJQueryDate%20avec%20sfFormExtraPlugin" title="Facebook"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/facebook.png" title="Facebook" alt="Facebook" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.google.com/bookmarks/mark?op=edit&amp;bkmk=http%3A%2F%2Fwww.mcherifi.org%2Fdeveloppement-web%2Fsymfony%2Fsymfony-utiliser-sfwidgetformjquerydate-avec-sfformextraplugin.html&amp;title=symfony%3A%20Utiliser%20sfWidgetFormJQueryDate%20avec%20sfFormExtraPlugin&amp;annotation=%0D%0AVu%20le%20tr%C3%A8s%20peu%20de%20documentation%20que%20j%27ai%20pu%20trouv%C3%A9%20au%20sujet%20du%20plugin%20sfFormExtraPlugin%20de%20symfony%2C%20voici%20un%20guide%20rapide%20qui%20vous%20permettra%20d%27installer%20le%20plugin%20sfFormExtraPlugin%20et%20pouvoir%20afficher%20un%20calendrier%20pour%20les%20champs%20de%20type%20date%20gr" title="Google Bookmarks"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/googlebookmark.png" title="Google Bookmarks" alt="Google Bookmarks" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://delicious.com/post?url=http%3A%2F%2Fwww.mcherifi.org%2Fdeveloppement-web%2Fsymfony%2Fsymfony-utiliser-sfwidgetformjquerydate-avec-sfformextraplugin.html&amp;title=symfony%3A%20Utiliser%20sfWidgetFormJQueryDate%20avec%20sfFormExtraPlugin&amp;notes=%0D%0AVu%20le%20tr%C3%A8s%20peu%20de%20documentation%20que%20j%27ai%20pu%20trouv%C3%A9%20au%20sujet%20du%20plugin%20sfFormExtraPlugin%20de%20symfony%2C%20voici%20un%20guide%20rapide%20qui%20vous%20permettra%20d%27installer%20le%20plugin%20sfFormExtraPlugin%20et%20pouvoir%20afficher%20un%20calendrier%20pour%20les%20champs%20de%20type%20date%20gr" title="del.icio.us"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/delicious.png" title="del.icio.us" alt="del.icio.us" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.netvibes.com/share?title=symfony%3A%20Utiliser%20sfWidgetFormJQueryDate%20avec%20sfFormExtraPlugin&amp;url=http%3A%2F%2Fwww.mcherifi.org%2Fdeveloppement-web%2Fsymfony%2Fsymfony-utiliser-sfwidgetformjquerydate-avec-sfformextraplugin.html" title="Netvibes"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/netvibes.png" title="Netvibes" alt="Netvibes" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.viadeo.com/shareit/share/?url=http%3A%2F%2Fwww.mcherifi.org%2Fdeveloppement-web%2Fsymfony%2Fsymfony-utiliser-sfwidgetformjquerydate-avec-sfformextraplugin.html&title=symfony%3A%20Utiliser%20sfWidgetFormJQueryDate%20avec%20sfFormExtraPlugin&urllanguage=fr" title="viadeo FR"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/viadeo.png" title="viadeo FR" alt="viadeo FR" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://digg.com/submit?phase=2&amp;url=http%3A%2F%2Fwww.mcherifi.org%2Fdeveloppement-web%2Fsymfony%2Fsymfony-utiliser-sfwidgetformjquerydate-avec-sfformextraplugin.html&amp;title=symfony%3A%20Utiliser%20sfWidgetFormJQueryDate%20avec%20sfFormExtraPlugin&amp;bodytext=%0D%0AVu%20le%20tr%C3%A8s%20peu%20de%20documentation%20que%20j%27ai%20pu%20trouv%C3%A9%20au%20sujet%20du%20plugin%20sfFormExtraPlugin%20de%20symfony%2C%20voici%20un%20guide%20rapide%20qui%20vous%20permettra%20d%27installer%20le%20plugin%20sfFormExtraPlugin%20et%20pouvoir%20afficher%20un%20calendrier%20pour%20les%20champs%20de%20type%20date%20gr" title="Digg"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/digg.png" title="Digg" alt="Digg" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.linkedin.com/shareArticle?mini=true&amp;url=http%3A%2F%2Fwww.mcherifi.org%2Fdeveloppement-web%2Fsymfony%2Fsymfony-utiliser-sfwidgetformjquerydate-avec-sfformextraplugin.html&amp;title=symfony%3A%20Utiliser%20sfWidgetFormJQueryDate%20avec%20sfFormExtraPlugin&amp;source=Mohammed+CHERIFI+Another+Web+Developper+Blog%21&amp;summary=%0D%0AVu%20le%20tr%C3%A8s%20peu%20de%20documentation%20que%20j%27ai%20pu%20trouv%C3%A9%20au%20sujet%20du%20plugin%20sfFormExtraPlugin%20de%20symfony%2C%20voici%20un%20guide%20rapide%20qui%20vous%20permettra%20d%27installer%20le%20plugin%20sfFormExtraPlugin%20et%20pouvoir%20afficher%20un%20calendrier%20pour%20les%20champs%20de%20type%20date%20gr" title="LinkedIn"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/linkedin.png" title="LinkedIn" alt="LinkedIn" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://slashdot.org/bookmark.pl?title=symfony%3A%20Utiliser%20sfWidgetFormJQueryDate%20avec%20sfFormExtraPlugin&amp;url=http%3A%2F%2Fwww.mcherifi.org%2Fdeveloppement-web%2Fsymfony%2Fsymfony-utiliser-sfwidgetformjquerydate-avec-sfformextraplugin.html" title="Slashdot"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/slashdot.png" title="Slashdot" alt="Slashdot" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://sphinn.com/index.php?c=post&amp;m=submit&amp;link=http%3A%2F%2Fwww.mcherifi.org%2Fdeveloppement-web%2Fsymfony%2Fsymfony-utiliser-sfwidgetformjquerydate-avec-sfformextraplugin.html" title="Sphinn"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/sphinn.png" title="Sphinn" alt="Sphinn" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.mixx.com/submit?page_url=http%3A%2F%2Fwww.mcherifi.org%2Fdeveloppement-web%2Fsymfony%2Fsymfony-utiliser-sfwidgetformjquerydate-avec-sfformextraplugin.html&amp;title=symfony%3A%20Utiliser%20sfWidgetFormJQueryDate%20avec%20sfFormExtraPlugin" title="Mixx"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/mixx.png" title="Mixx" alt="Mixx" class="sociable-hovers" /></a>
	<a  target="_blank" href="http://blogplay.com" title="Blogplay"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/blogplay.png" title="Blogplay" alt="Blogplay" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://identi.ca/notice/new?status_textarea=http%3A%2F%2Fwww.mcherifi.org%2Fdeveloppement-web%2Fsymfony%2Fsymfony-utiliser-sfwidgetformjquerydate-avec-sfformextraplugin.html" title="Identi.ca"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/identica.png" title="Identi.ca" alt="Identi.ca" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.printfriendly.com/print?url=http%3A%2F%2Fwww.mcherifi.org%2Fdeveloppement-web%2Fsymfony%2Fsymfony-utiliser-sfwidgetformjquerydate-avec-sfformextraplugin.html&amp;partner=sociable" title="Print"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/printfriendly.png" title="Print" alt="Print" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.mcherifi.org/wp-content/plugins/sociable/awesmate.php?c=pingfm&t=http%3A%2F%2Fwww.mcherifi.org%2Fdeveloppement-web%2Fsymfony%2Fsymfony-utiliser-sfwidgetformjquerydate-avec-sfformextraplugin.html&d=http://ping.fm/ref/?link=TARGET%26title=symfony%3A%20Utiliser%20sfWidgetFormJQueryDate%20avec%20sfFormExtraPlugin%26body=%0D%0AVu%20le%20tr%C3%A8s%20peu%20de%20documentation%20que%20j%27ai%20pu%20trouv%C3%A9%20au%20sujet%20du%20plugin%20sfFormExtraPlugin%20de%20symfony%2C%20voici%20un%20guide%20rapide%20qui%20vous%20permettra%20d%27installer%20le%20plugin%20sfFormExtraPlugin%20et%20pouvoir%20afficher%20un%20calendrier%20pour%20les%20champs%20de%20type%20date%20gr" title="Ping.fm"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/ping.png" title="Ping.fm" alt="Ping.fm" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.mcherifi.org/wp-content/plugins/sociable/awesmate.php?c=mailto&t=http%3A%2F%2Fwww.mcherifi.org%2Fdeveloppement-web%2Fsymfony%2Fsymfony-utiliser-sfwidgetformjquerydate-avec-sfformextraplugin.html&d=mailto:?subject=symfony%3A%20Utiliser%20sfWidgetFormJQueryDate%20avec%20sfFormExtraPlugin%26body=TARGET" title="email"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/email_link.png" title="email" alt="email" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://posterous.com/share?linkto=http%3A%2F%2Fwww.mcherifi.org%2Fdeveloppement-web%2Fsymfony%2Fsymfony-utiliser-sfwidgetformjquerydate-avec-sfformextraplugin.html&amp;title=symfony%3A%20Utiliser%20sfWidgetFormJQueryDate%20avec%20sfFormExtraPlugin&amp;selection=%0D%0AVu%20le%20tr%C3%A8s%20peu%20de%20documentation%20que%20j%27ai%20pu%20trouv%C3%A9%20au%20sujet%20du%20plugin%20sfFormExtraPlugin%20de%20symfony%2C%20voici%20un%20guide%20rapide%20qui%20vous%20permettra%20d%27installer%20le%20plugin%20sfFormExtraPlugin%20et%20pouvoir%20afficher%20un%20calendrier%20pour%20les%20champs%20de%20type%20date%20gr" title="Posterous"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/posterous.png" title="Posterous" alt="Posterous" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://reddit.com/submit?url=http%3A%2F%2Fwww.mcherifi.org%2Fdeveloppement-web%2Fsymfony%2Fsymfony-utiliser-sfwidgetformjquerydate-avec-sfformextraplugin.html&amp;title=symfony%3A%20Utiliser%20sfWidgetFormJQueryDate%20avec%20sfFormExtraPlugin" title="Reddit"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/reddit.png" title="Reddit" alt="Reddit" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://buzz.yahoo.com/submit/?submitUrl=http%3A%2F%2Fwww.mcherifi.org%2Fdeveloppement-web%2Fsymfony%2Fsymfony-utiliser-sfwidgetformjquerydate-avec-sfformextraplugin.html&amp;submitHeadline=symfony%3A%20Utiliser%20sfWidgetFormJQueryDate%20avec%20sfFormExtraPlugin&amp;submitSummary=%0D%0AVu%20le%20tr%C3%A8s%20peu%20de%20documentation%20que%20j%27ai%20pu%20trouv%C3%A9%20au%20sujet%20du%20plugin%20sfFormExtraPlugin%20de%20symfony%2C%20voici%20un%20guide%20rapide%20qui%20vous%20permettra%20d%27installer%20le%20plugin%20sfFormExtraPlugin%20et%20pouvoir%20afficher%20un%20calendrier%20pour%20les%20champs%20de%20type%20date%20gr&amp;submitCategory=science&amp;submitAssetType=text" title="Yahoo! Buzz"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/yahoobuzz.png" title="Yahoo! Buzz" alt="Yahoo! Buzz" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.printfriendly.com/print?url=http%3A%2F%2Fwww.mcherifi.org%2Fdeveloppement-web%2Fsymfony%2Fsymfony-utiliser-sfwidgetformjquerydate-avec-sfformextraplugin.html&amp;partner=sociable" title="PDF"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/pdf.png" title="PDF" alt="PDF" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.mcherifi.org/feed" title="RSS"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/rss.png" title="RSS" alt="RSS" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.diigo.com/post?url=http%3A%2F%2Fwww.mcherifi.org%2Fdeveloppement-web%2Fsymfony%2Fsymfony-utiliser-sfwidgetformjquerydate-avec-sfformextraplugin.html&amp;title=symfony%3A%20Utiliser%20sfWidgetFormJQueryDate%20avec%20sfFormExtraPlugin" title="Diigo"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/diigo.png" title="Diigo" alt="Diigo" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://cgi.fark.com/cgi/fark/farkit.pl?h=symfony%3A%20Utiliser%20sfWidgetFormJQueryDate%20avec%20sfFormExtraPlugin&amp;u=http%3A%2F%2Fwww.mcherifi.org%2Fdeveloppement-web%2Fsymfony%2Fsymfony-utiliser-sfwidgetformjquerydate-avec-sfformextraplugin.html" title="Fark"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/fark.png" title="Fark" alt="Fark" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.blogospherenews.com/submit.php?url=http%3A%2F%2Fwww.mcherifi.org%2Fdeveloppement-web%2Fsymfony%2Fsymfony-utiliser-sfwidgetformjquerydate-avec-sfformextraplugin.html&amp;title=symfony%3A%20Utiliser%20sfWidgetFormJQueryDate%20avec%20sfFormExtraPlugin" title="Blogosphere News"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/blogospherenews.png" title="Blogosphere News" alt="Blogosphere News" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://cimlap.blogter.hu/index.php?action=suggest_link&amp;title=symfony%3A%20Utiliser%20sfWidgetFormJQueryDate%20avec%20sfFormExtraPlugin&amp;url=http%3A%2F%2Fwww.mcherifi.org%2Fdeveloppement-web%2Fsymfony%2Fsymfony-utiliser-sfwidgetformjquerydate-avec-sfformextraplugin.html" title="blogtercimlap"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/blogter.png" title="blogtercimlap" alt="blogtercimlap" class="sociable-hovers" /></a>


<br/><br/>
<p class="FacebookLikeButton"><fb:like href="http%3A%2F%2Fwww.mcherifi.org%2Fdeveloppement-web%2Fsymfony%2Fsymfony-utiliser-sfwidgetformjquerydate-avec-sfformextraplugin.html" layout="standard" show_faces="true" width="450" action="like" colorscheme="light"></fb:like></p>
]]></content:encoded>
			<wfw:commentRss>http://www.mcherifi.org/developpement-web/symfony/symfony-utiliser-sfwidgetformjquerydate-avec-sfformextraplugin.html/feed</wfw:commentRss>
		<slash:comments>17</slash:comments>
		</item>
		<item>
		<title>Enchainer plusieurs animations avec jQuery</title>
		<link>http://www.mcherifi.org/tutoriaux/enchainer-plusieurs-animations-avec-jquery.html</link>
		<comments>http://www.mcherifi.org/tutoriaux/enchainer-plusieurs-animations-avec-jquery.html#comments</comments>
		<pubDate>Wed, 23 Sep 2009 23:08:07 +0000</pubDate>
		<dc:creator>Mohammed CHERIFI</dc:creator>
				<category><![CDATA[Tutoriaux]]></category>
		<category><![CDATA[animate]]></category>
		<category><![CDATA[chain animation]]></category>
		<category><![CDATA[jquery]]></category>

		<guid isPermaLink="false">http://www.mcherifi.org/?p=176</guid>
		<description><![CDATA[TweetBonjour à tous!
Savez vous qu&#8217;avec jQuery il est possible d&#8217;enchainer plusieurs animations à la fois dans une seule instruction? alors la réponse est OUI, on peut même aller plus loin avec un peu d&#8217;imagination et c&#8217;est vraiment très facile à mettre en œuvre! En fait chaque méthode dans jQuery retourne l’objet lui-même, ainsi on peut [...]]]></description>
			<content:encoded><![CDATA[<a href="http://twitter.com/share" class="twitter-share-button" data-url="http://www.mcherifi.org/tutoriaux/enchainer-plusieurs-animations-avec-jquery.html" data-text="Enchainer plusieurs animations avec jQuery" data-count="horizontal">Tweet</a><p>Bonjour à tous!</p>
<p>Savez vous qu&#8217;avec jQuery il est possible d&#8217;enchainer plusieurs animations à la fois dans une seule instruction? alors la réponse est OUI, on peut même aller plus loin avec un peu d&#8217;imagination et c&#8217;est vraiment très facile à mettre en œuvre! En fait chaque méthode dans jQuery retourne l’objet lui-même, ainsi on peut enchaîner à une autre méthode :</p>
<p>Exemple :</p>
<pre class="brush: html">
&lt;script type=&quot;text/javascript&quot;&gt;// &lt;![CDATA[
jQuery(window).ready(function(){
$(&#039;#testcode1&#039;).click(function(){
$(&#039;#mondiv&#039;).animate({width:&#039;200px&#039;, fontSize: &quot;18px&quot;, borderWidth:&#039;3px&#039;, marginLeft:&#039;100px&#039;, opacity:&#039;0.8&#039;, padding:&#039;10px&#039;},2000)
.animate({width:&#039;120px&#039;, marginLeft:&#039;0&#039;, fontSize: &quot;12px&quot;, borderWidth:0, opacity:&#039;1&#039;, padding:&#039;0&#039;},2000);
return false;
});
});
// ]]&gt;&lt;/script&gt;
&lt;a id=&quot;testcode1&quot;&gt;Tester le code&lt;/a&gt;
&lt;div id=&quot;mondiv&quot; style=&quot;border: 1px solid #ffffff; background: #077f2e none repeat scroll 0% 0%; width: 120px; height: 120px;&quot;&gt;Un div de test&lt;/div&gt;
</pre>
<p><script type="text/javascript">// <![CDATA[
jQuery(window).ready(function(){
$('#testcode1').click(function(){
$('#mondiv').animate({width:'200px', fontSize: "18px", borderWidth:'3px', marginLeft:'100px', opacity:'0.8', padding:'10px'},2000)
.animate({width:'120px', marginLeft:'0', fontSize: "12px", borderWidth:0, opacity:'1', padding:'0'},2000);
return false;
});
});
// ]]&gt;</script><br />
<strong>Resultat</strong><br />
<a id="testcode1">Tester le code</a></p>
<div id="mondiv" style="border: 1px solid #ffffff; background: #077f2e none repeat scroll 0% 0%; width: 120px; height: 120px;">Un div de test</div>
<p>La fonction animate() est une fonction native en jQuery, elle permet d&#8217;animer les propriétés CSS d&#8217;un objet jQuery dans une durée bien déterminée , la syntaxe comme dans l&#8217;exemple si-dessus est très simple!</p>
<p>On peut animer une seule, ou plusieurs propriétés CSS à la fois! Par exemple pour animer la largeur d&#8217;un div ayant l&#8217;id test et la mettre à 300px sur 2secondes le code sera :</p>
<pre class="brush: javascript">
$(&#039;#test&#039;).animate({width&#039;:&#039;300px&#039;},2000);
</pre>
<p>Ainsi on peut enchainer autant qu&#8217;on veux, le reste dépend de votre imagination ^^, à noter que la durée de l&#8217;animation (2000) est en millisecondes, d&#8217;où 1 seconde = 1000 ms</p>
<p><strong>Un autre Exemple d&#8217;enchainement d&#8217;animation</strong></p>
<p>Dans cette exemple, on va animer un div ayant un arrière plan rouge, et une image d&#8217;étoile pour construire le drapeau du maroc à la fin de l&#8217;animation</p>
<p><a href="/data/jquery/animation/animate.html" target="blank">Voir le resultat</a></p>
<p><strong>Code</strong></p>
<pre class="brush: html">
&lt;!DOCTYPE html PUBLIC &quot;-//W3C//DTD HTML 4.01 Transitional//EN&quot; &quot;http://www.w3.org/TR/html4/loose.dtd&quot;&gt;
&lt;html&gt;
&lt;head&gt;
&lt;meta http-equiv=&quot;Content-Type&quot; content=&quot;text/html; charset=ISO-8859-1&quot;&gt;
&lt;script src=&quot;http://ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js&quot; type=&quot;text/javascript&quot;&gt;&lt;/script&gt;
&lt;script type=&quot;text/javascript&quot;&gt;
&lt;!-- 	www.mcherifi.org --&gt;
	jQuery(window).ready(function(){
		$(&#039;#animationlink&#039;).click(function(){
			$(&#039;#mondiv&#039;).animate({left:&#039;400px&#039;, opacity:&#039;0.3&#039;, width:&#039;40px&#039;, height:&#039;70px&#039;, borderWidth:&#039;20px&#039;}, 1500)
				.animate({top:&#039;300px&#039;, opacity:&#039;0.8&#039;, left:&#039;100px&#039;, width:&#039;70px&#039;, height:&#039;70px&#039;, borderWidth:&#039;7px&#039;}, 1500)
				.animate({top:&#039;160px&#039;, opacity:&#039;0.4&#039;, left:&#039;500px&#039;, width:&#039;170px&#039;, borderWidth:&#039;3px&#039;}, 1200)
				.animate({top:0,  opacity:&#039;0.2&#039;,  left:0, width:&#039;200px&#039;, height:&#039;200px&#039;, borderWidth:&#039;1px&#039;}, 700)
				.animate({opacity:&#039;1&#039;, borderWidth:&#039;2px&#039;}, 1000);

			$(&#039;#monetoile&#039;).css(&#039;opacity&#039;, 0).animate({left:&#039;500px&#039;, top:&#039;400px&#039;, opacity:&#039;0.5&#039;, height:&#039;80px&#039;, width:&#039;100px&#039;}, 1300)
				.animate({left:&#039;260px&#039;, top:&#039;250px&#039;, opacity:&#039;0.8&#039;}, 1000)
				.animate({left:&#039;100px&#039;, width:&#039;0&#039;, opacity:&#039;0.2&#039;}, 1200)
				.animate({width:&#039;154px&#039;, top:&#039;100px&#039;, left:&#039;150px&#039;, opacity:&#039;0.5&#039;}, 1000)
				.animate({left:&#039;30px&#039;, height:&#039;135px&#039;, width:&#039;154px&#039;, top:&#039;30px&#039;, opacity:&#039;1&#039;}, 1200);

			return false;
		});
	});

&lt;/script&gt;
&lt;title&gt;Mohammed CHERIFI - Enchainement d&#039;une animation sous jQUery&lt;/title&gt;
&lt;style type=&quot;text/css&quot;&gt;	

	#contenaire{
		position:relative;
		margin:10px;
	}

	#mondiv{
		background:#f00;
		width:150px;
		height:150px;
		border:1px solid #077F2E;
		position:absolute;
	}

	#monetoile{
		position:absolute;
		display:none;
	}

&lt;/style&gt;
&lt;/head&gt;
&lt;body&gt;

	&lt;a href=&quot;#&quot; id=&quot;animationlink&quot;&gt;Animaer&lt;/a&gt;&lt;br /&gt;

	&lt;div id=&quot;contenaire&quot;&gt;
		&lt;div id=&quot;mondiv&quot;&gt;&lt;/div&gt;
		&lt;img id=&quot;monetoile&quot; src=&quot;star.gif&quot; alt=&quot;I Love Morocco&quot; width=&quot;154&quot; height=&quot;135&quot;/&gt;
	&lt;/div&gt;

&lt;/body&gt;
&lt;/html&gt;
</pre>
<p><a href="/data/animation/animatetuto.zip">Télécharger le code source de l&#8217;amination</a></p>



Partager cet article:


	<a rel="nofollow"  target="_blank" href="http://www.mcherifi.org/wp-content/plugins/sociable/awesmate.php?c=twitter&t=http%3A%2F%2Fwww.mcherifi.org%2Ftutoriaux%2Fenchainer-plusieurs-animations-avec-jquery.html&d=http://twitter.com/home?status=Enchainer%20plusieurs%20animations%20avec%20jQuery%20-%20TARGET" title="Twitter"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/twitter.png" title="Twitter" alt="Twitter" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.mcherifi.org/wp-content/plugins/sociable/awesmate.php?c=facebook-post&t=http%3A%2F%2Fwww.mcherifi.org%2Ftutoriaux%2Fenchainer-plusieurs-animations-avec-jquery.html&d=http://www.facebook.com/share.php?u=TARGET%26t=Enchainer%20plusieurs%20animations%20avec%20jQuery" title="Facebook"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/facebook.png" title="Facebook" alt="Facebook" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.google.com/bookmarks/mark?op=edit&amp;bkmk=http%3A%2F%2Fwww.mcherifi.org%2Ftutoriaux%2Fenchainer-plusieurs-animations-avec-jquery.html&amp;title=Enchainer%20plusieurs%20animations%20avec%20jQuery&amp;annotation=Bonjour%20%C3%A0%20tous%21%0D%0A%0D%0ASavez%20vous%20qu%27avec%20jQuery%20il%20est%20possible%20d%27enchainer%20plusieurs%20animations%20%C3%A0%20la%20fois%20dans%20une%20seule%20instruction%3F%20alors%20la%20r%C3%A9ponse%20est%20OUI%2C%20on%20peut%20m%C3%AAme%20aller%20plus%20loin%20avec%20un%20peu%20d%27imagination%20et%20c%27est%20vraiment%20tr%C3%A8s%20facile%20%C3%A0" title="Google Bookmarks"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/googlebookmark.png" title="Google Bookmarks" alt="Google Bookmarks" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://delicious.com/post?url=http%3A%2F%2Fwww.mcherifi.org%2Ftutoriaux%2Fenchainer-plusieurs-animations-avec-jquery.html&amp;title=Enchainer%20plusieurs%20animations%20avec%20jQuery&amp;notes=Bonjour%20%C3%A0%20tous%21%0D%0A%0D%0ASavez%20vous%20qu%27avec%20jQuery%20il%20est%20possible%20d%27enchainer%20plusieurs%20animations%20%C3%A0%20la%20fois%20dans%20une%20seule%20instruction%3F%20alors%20la%20r%C3%A9ponse%20est%20OUI%2C%20on%20peut%20m%C3%AAme%20aller%20plus%20loin%20avec%20un%20peu%20d%27imagination%20et%20c%27est%20vraiment%20tr%C3%A8s%20facile%20%C3%A0" title="del.icio.us"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/delicious.png" title="del.icio.us" alt="del.icio.us" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.netvibes.com/share?title=Enchainer%20plusieurs%20animations%20avec%20jQuery&amp;url=http%3A%2F%2Fwww.mcherifi.org%2Ftutoriaux%2Fenchainer-plusieurs-animations-avec-jquery.html" title="Netvibes"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/netvibes.png" title="Netvibes" alt="Netvibes" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.viadeo.com/shareit/share/?url=http%3A%2F%2Fwww.mcherifi.org%2Ftutoriaux%2Fenchainer-plusieurs-animations-avec-jquery.html&title=Enchainer%20plusieurs%20animations%20avec%20jQuery&urllanguage=fr" title="viadeo FR"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/viadeo.png" title="viadeo FR" alt="viadeo FR" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://digg.com/submit?phase=2&amp;url=http%3A%2F%2Fwww.mcherifi.org%2Ftutoriaux%2Fenchainer-plusieurs-animations-avec-jquery.html&amp;title=Enchainer%20plusieurs%20animations%20avec%20jQuery&amp;bodytext=Bonjour%20%C3%A0%20tous%21%0D%0A%0D%0ASavez%20vous%20qu%27avec%20jQuery%20il%20est%20possible%20d%27enchainer%20plusieurs%20animations%20%C3%A0%20la%20fois%20dans%20une%20seule%20instruction%3F%20alors%20la%20r%C3%A9ponse%20est%20OUI%2C%20on%20peut%20m%C3%AAme%20aller%20plus%20loin%20avec%20un%20peu%20d%27imagination%20et%20c%27est%20vraiment%20tr%C3%A8s%20facile%20%C3%A0" title="Digg"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/digg.png" title="Digg" alt="Digg" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.linkedin.com/shareArticle?mini=true&amp;url=http%3A%2F%2Fwww.mcherifi.org%2Ftutoriaux%2Fenchainer-plusieurs-animations-avec-jquery.html&amp;title=Enchainer%20plusieurs%20animations%20avec%20jQuery&amp;source=Mohammed+CHERIFI+Another+Web+Developper+Blog%21&amp;summary=Bonjour%20%C3%A0%20tous%21%0D%0A%0D%0ASavez%20vous%20qu%27avec%20jQuery%20il%20est%20possible%20d%27enchainer%20plusieurs%20animations%20%C3%A0%20la%20fois%20dans%20une%20seule%20instruction%3F%20alors%20la%20r%C3%A9ponse%20est%20OUI%2C%20on%20peut%20m%C3%AAme%20aller%20plus%20loin%20avec%20un%20peu%20d%27imagination%20et%20c%27est%20vraiment%20tr%C3%A8s%20facile%20%C3%A0" title="LinkedIn"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/linkedin.png" title="LinkedIn" alt="LinkedIn" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://slashdot.org/bookmark.pl?title=Enchainer%20plusieurs%20animations%20avec%20jQuery&amp;url=http%3A%2F%2Fwww.mcherifi.org%2Ftutoriaux%2Fenchainer-plusieurs-animations-avec-jquery.html" title="Slashdot"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/slashdot.png" title="Slashdot" alt="Slashdot" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://sphinn.com/index.php?c=post&amp;m=submit&amp;link=http%3A%2F%2Fwww.mcherifi.org%2Ftutoriaux%2Fenchainer-plusieurs-animations-avec-jquery.html" title="Sphinn"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/sphinn.png" title="Sphinn" alt="Sphinn" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.mixx.com/submit?page_url=http%3A%2F%2Fwww.mcherifi.org%2Ftutoriaux%2Fenchainer-plusieurs-animations-avec-jquery.html&amp;title=Enchainer%20plusieurs%20animations%20avec%20jQuery" title="Mixx"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/mixx.png" title="Mixx" alt="Mixx" class="sociable-hovers" /></a>
	<a  target="_blank" href="http://blogplay.com" title="Blogplay"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/blogplay.png" title="Blogplay" alt="Blogplay" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://identi.ca/notice/new?status_textarea=http%3A%2F%2Fwww.mcherifi.org%2Ftutoriaux%2Fenchainer-plusieurs-animations-avec-jquery.html" title="Identi.ca"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/identica.png" title="Identi.ca" alt="Identi.ca" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.printfriendly.com/print?url=http%3A%2F%2Fwww.mcherifi.org%2Ftutoriaux%2Fenchainer-plusieurs-animations-avec-jquery.html&amp;partner=sociable" title="Print"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/printfriendly.png" title="Print" alt="Print" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.mcherifi.org/wp-content/plugins/sociable/awesmate.php?c=pingfm&t=http%3A%2F%2Fwww.mcherifi.org%2Ftutoriaux%2Fenchainer-plusieurs-animations-avec-jquery.html&d=http://ping.fm/ref/?link=TARGET%26title=Enchainer%20plusieurs%20animations%20avec%20jQuery%26body=Bonjour%20%C3%A0%20tous%21%0D%0A%0D%0ASavez%20vous%20qu%27avec%20jQuery%20il%20est%20possible%20d%27enchainer%20plusieurs%20animations%20%C3%A0%20la%20fois%20dans%20une%20seule%20instruction%3F%20alors%20la%20r%C3%A9ponse%20est%20OUI%2C%20on%20peut%20m%C3%AAme%20aller%20plus%20loin%20avec%20un%20peu%20d%27imagination%20et%20c%27est%20vraiment%20tr%C3%A8s%20facile%20%C3%A0" title="Ping.fm"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/ping.png" title="Ping.fm" alt="Ping.fm" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.mcherifi.org/wp-content/plugins/sociable/awesmate.php?c=mailto&t=http%3A%2F%2Fwww.mcherifi.org%2Ftutoriaux%2Fenchainer-plusieurs-animations-avec-jquery.html&d=mailto:?subject=Enchainer%20plusieurs%20animations%20avec%20jQuery%26body=TARGET" title="email"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/email_link.png" title="email" alt="email" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://posterous.com/share?linkto=http%3A%2F%2Fwww.mcherifi.org%2Ftutoriaux%2Fenchainer-plusieurs-animations-avec-jquery.html&amp;title=Enchainer%20plusieurs%20animations%20avec%20jQuery&amp;selection=Bonjour%20%C3%A0%20tous%21%0D%0A%0D%0ASavez%20vous%20qu%27avec%20jQuery%20il%20est%20possible%20d%27enchainer%20plusieurs%20animations%20%C3%A0%20la%20fois%20dans%20une%20seule%20instruction%3F%20alors%20la%20r%C3%A9ponse%20est%20OUI%2C%20on%20peut%20m%C3%AAme%20aller%20plus%20loin%20avec%20un%20peu%20d%27imagination%20et%20c%27est%20vraiment%20tr%C3%A8s%20facile%20%C3%A0" title="Posterous"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/posterous.png" title="Posterous" alt="Posterous" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://reddit.com/submit?url=http%3A%2F%2Fwww.mcherifi.org%2Ftutoriaux%2Fenchainer-plusieurs-animations-avec-jquery.html&amp;title=Enchainer%20plusieurs%20animations%20avec%20jQuery" title="Reddit"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/reddit.png" title="Reddit" alt="Reddit" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://buzz.yahoo.com/submit/?submitUrl=http%3A%2F%2Fwww.mcherifi.org%2Ftutoriaux%2Fenchainer-plusieurs-animations-avec-jquery.html&amp;submitHeadline=Enchainer%20plusieurs%20animations%20avec%20jQuery&amp;submitSummary=Bonjour%20%C3%A0%20tous%21%0D%0A%0D%0ASavez%20vous%20qu%27avec%20jQuery%20il%20est%20possible%20d%27enchainer%20plusieurs%20animations%20%C3%A0%20la%20fois%20dans%20une%20seule%20instruction%3F%20alors%20la%20r%C3%A9ponse%20est%20OUI%2C%20on%20peut%20m%C3%AAme%20aller%20plus%20loin%20avec%20un%20peu%20d%27imagination%20et%20c%27est%20vraiment%20tr%C3%A8s%20facile%20%C3%A0&amp;submitCategory=science&amp;submitAssetType=text" title="Yahoo! Buzz"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/yahoobuzz.png" title="Yahoo! Buzz" alt="Yahoo! Buzz" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.printfriendly.com/print?url=http%3A%2F%2Fwww.mcherifi.org%2Ftutoriaux%2Fenchainer-plusieurs-animations-avec-jquery.html&amp;partner=sociable" title="PDF"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/pdf.png" title="PDF" alt="PDF" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.mcherifi.org/feed" title="RSS"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/rss.png" title="RSS" alt="RSS" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.diigo.com/post?url=http%3A%2F%2Fwww.mcherifi.org%2Ftutoriaux%2Fenchainer-plusieurs-animations-avec-jquery.html&amp;title=Enchainer%20plusieurs%20animations%20avec%20jQuery" title="Diigo"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/diigo.png" title="Diigo" alt="Diigo" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://cgi.fark.com/cgi/fark/farkit.pl?h=Enchainer%20plusieurs%20animations%20avec%20jQuery&amp;u=http%3A%2F%2Fwww.mcherifi.org%2Ftutoriaux%2Fenchainer-plusieurs-animations-avec-jquery.html" title="Fark"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/fark.png" title="Fark" alt="Fark" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.blogospherenews.com/submit.php?url=http%3A%2F%2Fwww.mcherifi.org%2Ftutoriaux%2Fenchainer-plusieurs-animations-avec-jquery.html&amp;title=Enchainer%20plusieurs%20animations%20avec%20jQuery" title="Blogosphere News"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/blogospherenews.png" title="Blogosphere News" alt="Blogosphere News" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://cimlap.blogter.hu/index.php?action=suggest_link&amp;title=Enchainer%20plusieurs%20animations%20avec%20jQuery&amp;url=http%3A%2F%2Fwww.mcherifi.org%2Ftutoriaux%2Fenchainer-plusieurs-animations-avec-jquery.html" title="blogtercimlap"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/blogter.png" title="blogtercimlap" alt="blogtercimlap" class="sociable-hovers" /></a>


<br/><br/>
<p class="FacebookLikeButton"><fb:like href="http%3A%2F%2Fwww.mcherifi.org%2Ftutoriaux%2Fenchainer-plusieurs-animations-avec-jquery.html" layout="standard" show_faces="true" width="450" action="like" colorscheme="light"></fb:like></p>
]]></content:encoded>
			<wfw:commentRss>http://www.mcherifi.org/tutoriaux/enchainer-plusieurs-animations-avec-jquery.html/feed</wfw:commentRss>
		<slash:comments>6</slash:comments>
		</item>
		<item>
		<title>Introduction aux frameworks JavaScript</title>
		<link>http://www.mcherifi.org/developpement-web/introduction-aux-frameworks-javascript.html</link>
		<comments>http://www.mcherifi.org/developpement-web/introduction-aux-frameworks-javascript.html#comments</comments>
		<pubDate>Mon, 17 Aug 2009 01:41:29 +0000</pubDate>
		<dc:creator>Mohammed CHERIFI</dc:creator>
				<category><![CDATA[Développement WEB]]></category>
		<category><![CDATA[cross-browsing]]></category>
		<category><![CDATA[dojo]]></category>
		<category><![CDATA[framework javascript]]></category>
		<category><![CDATA[jquery]]></category>
		<category><![CDATA[mootools]]></category>
		<category><![CDATA[prototype]]></category>

		<guid isPermaLink="false">http://localhost/?p=18</guid>
		<description><![CDATA[TweetUn framework JavaScript c&#8217;est quoi?
Un framework JavaScript est un ensemble d&#8217;applications et de fonctionnalités regroupés, c&#8217;est une sorte de boite à outils qui contient toutes les tâches répétitives et courantes, grâce aux frameworks, vous pouvez gagner beaucoup de temps dans vos développements, vous pouvez facilement manipuler le DOM, faire des requêtes AJAX, des animations et [...]]]></description>
			<content:encoded><![CDATA[<a href="http://twitter.com/share" class="twitter-share-button" data-url="http://www.mcherifi.org/developpement-web/introduction-aux-frameworks-javascript.html" data-text="Introduction aux frameworks JavaScript" data-count="horizontal">Tweet</a><h2>Un framework JavaScript c&#8217;est quoi?</h2>
<p><img class="size-full wp-image-125 alignleft" title="javascript" src="http://www.mcherifi.org/wp-content/uploads/2009/08/javascript.gif" alt="javascript" width="220" height="170" />Un framework JavaScript est un ensemble d&#8217;applications et de fonctionnalités regroupés, c&#8217;est une sorte de boite à outils qui contient toutes les tâches répétitives et courantes, grâce aux frameworks, vous pouvez gagner beaucoup de temps dans vos développements, vous pouvez facilement manipuler le DOM, faire des requêtes AJAX, des animations et des effets superbes sur vos pages, et vous aurez tout le temps de vous concentrer sur des taches plus complexes et assez intéressantes ;)</p>
<p>Actuellement il existe plus de 500 frameworks JavaScript , ces frameworks qui ne cessent d&#8217;évoluer depuis l&#8217;apparition du WEB2.0</p>
<h2>Faire du WEB2.0!</h2>
<p>Il faut savoir que le WEB2.0 est concrètement basé sur le JavaScript du point de vue technique!  particulièrement grâce à sa capacité de faire des appels asynchrones vers les serveurs WEB via l&#8217;objet XMLHttpRequest, inventé par Microsoft en 2001, ce dernier permet aux visiteurs d&#8217;accéder aux nouveaux contenus sans avoir à cliquer ou rafraichir la page, cette fonctionnalité a été implémenté dans le DHTML pour donner naissance au WEB2.0.</p>
<p>Cette expérience a permis de donner une nouvelle vision au WEB, qui est devenu de plus en plus dynamique, réactif et innovant</p>
<h2>Pallier aux déficiences des navigateurs actuels</h2>
<p>S&#8217;assurer que son code javascript est compatible avec tous les navigateurs modernes est l&#8217;une des tâches les plus pénibles pour un développeur WEB (<a title="cross browser" href="http://fr.wikipedia.org/wiki/Cross-Browser">cross-browsing</a>), d&#8217;où le grand avantage des frameworks javascript: vous n&#8217;avez plus à gérer les dépendances entre les différents navigateurs (sélecteurs, gestion des évènements, méthodes de manipulation DOM..), votre framework javascript le fera à votre place et vous facilitera la vie ;)</p>
<h2>Quel framework JavaScript utiliser?</h2>
<p>Voici une liste des frameworks JavaScript les plus populaires :</p>
<ul>
<li><a title="Framework JavaScript jQuery" href="http://jquery.com/">jQuery</a></li>
<li><a title="Framework JavaScript Prototype" href="http://www.prototypejs.org/">Prototype</a></li>
<li><a title="Framework JavaScript YUI" href="http://developer.yahoo.com/yui/">Yahoo! User Interface</a></li>
<li><a title="Framework JavaScript Dojo" href="http://www.dojotoolkit.org/">Dojo</a></li>
<li><a title="Framework JavaScript Mootools" href="http://mootools.net/">Mootools</a></li>
<li><a title="Framework JavaScript Ext JS" href="http://extjs.com/">Ext JS</a></li>
<li>&#8230;</li>
</ul>
<p>Vu la qualité des outils proposés par les différents frameworks, il est difficile de recommander un en particulier, mais personnellement je préfère jQuery puis mootools grâce à  leurs qualité de documentation, leurs communautés très large, et leurs simplicité!</p>
<p>Vous pourriez préférer d&#8217;autres mais je vous invite à les essayer tous et utiliser celui avec lequel vous vous sentez plus à l&#8217;aise!</p>



Partager cet article:


	<a rel="nofollow"  target="_blank" href="http://www.mcherifi.org/wp-content/plugins/sociable/awesmate.php?c=twitter&t=http%3A%2F%2Fwww.mcherifi.org%2Fdeveloppement-web%2Fintroduction-aux-frameworks-javascript.html&d=http://twitter.com/home?status=Introduction%20aux%20frameworks%20JavaScript%20-%20TARGET" title="Twitter"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/twitter.png" title="Twitter" alt="Twitter" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.mcherifi.org/wp-content/plugins/sociable/awesmate.php?c=facebook-post&t=http%3A%2F%2Fwww.mcherifi.org%2Fdeveloppement-web%2Fintroduction-aux-frameworks-javascript.html&d=http://www.facebook.com/share.php?u=TARGET%26t=Introduction%20aux%20frameworks%20JavaScript" title="Facebook"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/facebook.png" title="Facebook" alt="Facebook" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.google.com/bookmarks/mark?op=edit&amp;bkmk=http%3A%2F%2Fwww.mcherifi.org%2Fdeveloppement-web%2Fintroduction-aux-frameworks-javascript.html&amp;title=Introduction%20aux%20frameworks%20JavaScript&amp;annotation=Un%20framework%20JavaScript%20c%27est%20quoi%3F%0D%0AUn%20framework%20JavaScript%20est%20un%20ensemble%20d%27applications%20et%20de%20fonctionnalit%C3%A9s%20regroup%C3%A9s%2C%20c%27est%20une%20sorte%20de%20boite%20%C3%A0%20outils%20qui%20contient%20toutes%20les%20t%C3%A2ches%20r%C3%A9p%C3%A9titives%20et%20courantes%2C%20gr%C3%A2ce%20aux%20frameworks%2C%20vous%20" title="Google Bookmarks"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/googlebookmark.png" title="Google Bookmarks" alt="Google Bookmarks" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://delicious.com/post?url=http%3A%2F%2Fwww.mcherifi.org%2Fdeveloppement-web%2Fintroduction-aux-frameworks-javascript.html&amp;title=Introduction%20aux%20frameworks%20JavaScript&amp;notes=Un%20framework%20JavaScript%20c%27est%20quoi%3F%0D%0AUn%20framework%20JavaScript%20est%20un%20ensemble%20d%27applications%20et%20de%20fonctionnalit%C3%A9s%20regroup%C3%A9s%2C%20c%27est%20une%20sorte%20de%20boite%20%C3%A0%20outils%20qui%20contient%20toutes%20les%20t%C3%A2ches%20r%C3%A9p%C3%A9titives%20et%20courantes%2C%20gr%C3%A2ce%20aux%20frameworks%2C%20vous%20" title="del.icio.us"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/delicious.png" title="del.icio.us" alt="del.icio.us" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.netvibes.com/share?title=Introduction%20aux%20frameworks%20JavaScript&amp;url=http%3A%2F%2Fwww.mcherifi.org%2Fdeveloppement-web%2Fintroduction-aux-frameworks-javascript.html" title="Netvibes"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/netvibes.png" title="Netvibes" alt="Netvibes" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.viadeo.com/shareit/share/?url=http%3A%2F%2Fwww.mcherifi.org%2Fdeveloppement-web%2Fintroduction-aux-frameworks-javascript.html&title=Introduction%20aux%20frameworks%20JavaScript&urllanguage=fr" title="viadeo FR"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/viadeo.png" title="viadeo FR" alt="viadeo FR" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://digg.com/submit?phase=2&amp;url=http%3A%2F%2Fwww.mcherifi.org%2Fdeveloppement-web%2Fintroduction-aux-frameworks-javascript.html&amp;title=Introduction%20aux%20frameworks%20JavaScript&amp;bodytext=Un%20framework%20JavaScript%20c%27est%20quoi%3F%0D%0AUn%20framework%20JavaScript%20est%20un%20ensemble%20d%27applications%20et%20de%20fonctionnalit%C3%A9s%20regroup%C3%A9s%2C%20c%27est%20une%20sorte%20de%20boite%20%C3%A0%20outils%20qui%20contient%20toutes%20les%20t%C3%A2ches%20r%C3%A9p%C3%A9titives%20et%20courantes%2C%20gr%C3%A2ce%20aux%20frameworks%2C%20vous%20" title="Digg"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/digg.png" title="Digg" alt="Digg" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.linkedin.com/shareArticle?mini=true&amp;url=http%3A%2F%2Fwww.mcherifi.org%2Fdeveloppement-web%2Fintroduction-aux-frameworks-javascript.html&amp;title=Introduction%20aux%20frameworks%20JavaScript&amp;source=Mohammed+CHERIFI+Another+Web+Developper+Blog%21&amp;summary=Un%20framework%20JavaScript%20c%27est%20quoi%3F%0D%0AUn%20framework%20JavaScript%20est%20un%20ensemble%20d%27applications%20et%20de%20fonctionnalit%C3%A9s%20regroup%C3%A9s%2C%20c%27est%20une%20sorte%20de%20boite%20%C3%A0%20outils%20qui%20contient%20toutes%20les%20t%C3%A2ches%20r%C3%A9p%C3%A9titives%20et%20courantes%2C%20gr%C3%A2ce%20aux%20frameworks%2C%20vous%20" title="LinkedIn"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/linkedin.png" title="LinkedIn" alt="LinkedIn" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://slashdot.org/bookmark.pl?title=Introduction%20aux%20frameworks%20JavaScript&amp;url=http%3A%2F%2Fwww.mcherifi.org%2Fdeveloppement-web%2Fintroduction-aux-frameworks-javascript.html" title="Slashdot"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/slashdot.png" title="Slashdot" alt="Slashdot" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://sphinn.com/index.php?c=post&amp;m=submit&amp;link=http%3A%2F%2Fwww.mcherifi.org%2Fdeveloppement-web%2Fintroduction-aux-frameworks-javascript.html" title="Sphinn"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/sphinn.png" title="Sphinn" alt="Sphinn" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.mixx.com/submit?page_url=http%3A%2F%2Fwww.mcherifi.org%2Fdeveloppement-web%2Fintroduction-aux-frameworks-javascript.html&amp;title=Introduction%20aux%20frameworks%20JavaScript" title="Mixx"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/mixx.png" title="Mixx" alt="Mixx" class="sociable-hovers" /></a>
	<a  target="_blank" href="http://blogplay.com" title="Blogplay"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/blogplay.png" title="Blogplay" alt="Blogplay" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://identi.ca/notice/new?status_textarea=http%3A%2F%2Fwww.mcherifi.org%2Fdeveloppement-web%2Fintroduction-aux-frameworks-javascript.html" title="Identi.ca"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/identica.png" title="Identi.ca" alt="Identi.ca" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.printfriendly.com/print?url=http%3A%2F%2Fwww.mcherifi.org%2Fdeveloppement-web%2Fintroduction-aux-frameworks-javascript.html&amp;partner=sociable" title="Print"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/printfriendly.png" title="Print" alt="Print" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.mcherifi.org/wp-content/plugins/sociable/awesmate.php?c=pingfm&t=http%3A%2F%2Fwww.mcherifi.org%2Fdeveloppement-web%2Fintroduction-aux-frameworks-javascript.html&d=http://ping.fm/ref/?link=TARGET%26title=Introduction%20aux%20frameworks%20JavaScript%26body=Un%20framework%20JavaScript%20c%27est%20quoi%3F%0D%0AUn%20framework%20JavaScript%20est%20un%20ensemble%20d%27applications%20et%20de%20fonctionnalit%C3%A9s%20regroup%C3%A9s%2C%20c%27est%20une%20sorte%20de%20boite%20%C3%A0%20outils%20qui%20contient%20toutes%20les%20t%C3%A2ches%20r%C3%A9p%C3%A9titives%20et%20courantes%2C%20gr%C3%A2ce%20aux%20frameworks%2C%20vous%20" title="Ping.fm"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/ping.png" title="Ping.fm" alt="Ping.fm" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.mcherifi.org/wp-content/plugins/sociable/awesmate.php?c=mailto&t=http%3A%2F%2Fwww.mcherifi.org%2Fdeveloppement-web%2Fintroduction-aux-frameworks-javascript.html&d=mailto:?subject=Introduction%20aux%20frameworks%20JavaScript%26body=TARGET" title="email"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/email_link.png" title="email" alt="email" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://posterous.com/share?linkto=http%3A%2F%2Fwww.mcherifi.org%2Fdeveloppement-web%2Fintroduction-aux-frameworks-javascript.html&amp;title=Introduction%20aux%20frameworks%20JavaScript&amp;selection=Un%20framework%20JavaScript%20c%27est%20quoi%3F%0D%0AUn%20framework%20JavaScript%20est%20un%20ensemble%20d%27applications%20et%20de%20fonctionnalit%C3%A9s%20regroup%C3%A9s%2C%20c%27est%20une%20sorte%20de%20boite%20%C3%A0%20outils%20qui%20contient%20toutes%20les%20t%C3%A2ches%20r%C3%A9p%C3%A9titives%20et%20courantes%2C%20gr%C3%A2ce%20aux%20frameworks%2C%20vous%20" title="Posterous"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/posterous.png" title="Posterous" alt="Posterous" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://reddit.com/submit?url=http%3A%2F%2Fwww.mcherifi.org%2Fdeveloppement-web%2Fintroduction-aux-frameworks-javascript.html&amp;title=Introduction%20aux%20frameworks%20JavaScript" title="Reddit"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/reddit.png" title="Reddit" alt="Reddit" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://buzz.yahoo.com/submit/?submitUrl=http%3A%2F%2Fwww.mcherifi.org%2Fdeveloppement-web%2Fintroduction-aux-frameworks-javascript.html&amp;submitHeadline=Introduction%20aux%20frameworks%20JavaScript&amp;submitSummary=Un%20framework%20JavaScript%20c%27est%20quoi%3F%0D%0AUn%20framework%20JavaScript%20est%20un%20ensemble%20d%27applications%20et%20de%20fonctionnalit%C3%A9s%20regroup%C3%A9s%2C%20c%27est%20une%20sorte%20de%20boite%20%C3%A0%20outils%20qui%20contient%20toutes%20les%20t%C3%A2ches%20r%C3%A9p%C3%A9titives%20et%20courantes%2C%20gr%C3%A2ce%20aux%20frameworks%2C%20vous%20&amp;submitCategory=science&amp;submitAssetType=text" title="Yahoo! Buzz"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/yahoobuzz.png" title="Yahoo! Buzz" alt="Yahoo! Buzz" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.printfriendly.com/print?url=http%3A%2F%2Fwww.mcherifi.org%2Fdeveloppement-web%2Fintroduction-aux-frameworks-javascript.html&amp;partner=sociable" title="PDF"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/pdf.png" title="PDF" alt="PDF" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.mcherifi.org/feed" title="RSS"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/rss.png" title="RSS" alt="RSS" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.diigo.com/post?url=http%3A%2F%2Fwww.mcherifi.org%2Fdeveloppement-web%2Fintroduction-aux-frameworks-javascript.html&amp;title=Introduction%20aux%20frameworks%20JavaScript" title="Diigo"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/diigo.png" title="Diigo" alt="Diigo" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://cgi.fark.com/cgi/fark/farkit.pl?h=Introduction%20aux%20frameworks%20JavaScript&amp;u=http%3A%2F%2Fwww.mcherifi.org%2Fdeveloppement-web%2Fintroduction-aux-frameworks-javascript.html" title="Fark"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/fark.png" title="Fark" alt="Fark" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.blogospherenews.com/submit.php?url=http%3A%2F%2Fwww.mcherifi.org%2Fdeveloppement-web%2Fintroduction-aux-frameworks-javascript.html&amp;title=Introduction%20aux%20frameworks%20JavaScript" title="Blogosphere News"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/blogospherenews.png" title="Blogosphere News" alt="Blogosphere News" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://cimlap.blogter.hu/index.php?action=suggest_link&amp;title=Introduction%20aux%20frameworks%20JavaScript&amp;url=http%3A%2F%2Fwww.mcherifi.org%2Fdeveloppement-web%2Fintroduction-aux-frameworks-javascript.html" title="blogtercimlap"><img src="http://www.mcherifi.org/wp-content/plugins/sociable/images/blogter.png" title="blogtercimlap" alt="blogtercimlap" class="sociable-hovers" /></a>


<br/><br/>
<p class="FacebookLikeButton"><fb:like href="http%3A%2F%2Fwww.mcherifi.org%2Fdeveloppement-web%2Fintroduction-aux-frameworks-javascript.html" layout="standard" show_faces="true" width="450" action="like" colorscheme="light"></fb:like></p>
]]></content:encoded>
			<wfw:commentRss>http://www.mcherifi.org/developpement-web/introduction-aux-frameworks-javascript.html/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>

