<?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>(function() { &#187; ycodaslider</title>
	<atom:link href="http://maxb.net/blog/tag/ycodaslider/feed/" rel="self" type="application/rss+xml" />
	<link>http://maxb.net/blog</link>
	<description>// MAXB.NET LABS</description>
	<lastBuildDate>Mon, 16 May 2011 19:12:58 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
		<item>
		<title>YCodaSlider 3.0 – Click’n&#8217;Play + Autoplay</title>
		<link>http://maxb.net/blog/2009/03/09/ycodaslider-30-clicknplay-autoplay/</link>
		<comments>http://maxb.net/blog/2009/03/09/ycodaslider-30-clicknplay-autoplay/#comments</comments>
		<pubDate>Mon, 09 Mar 2009 09:50:36 +0000</pubDate>
		<dc:creator>Massimiliano Balestrieri</dc:creator>
				<category><![CDATA[javascript]]></category>
		<category><![CDATA[jquery]]></category>
		<category><![CDATA[ycodaslider]]></category>

		<guid isPermaLink="false">http://maxb.net/blog/?p=247</guid>
		<description><![CDATA[Ecco due snippets di codice per avere l&#8217;autoplay dello &#8220;slider&#8221; e il play sul click sull&#8217;immagine. Per ora sono snippets di codice esterni alla libreria. Nella futura versione ci saranno le opzioni autoplay clicknplay (ycodagallery) AUTOPLAY GALLERY + LAZYLOAD AUTOPLAY &#8230; <a href="http://maxb.net/blog/2009/03/09/ycodaslider-30-clicknplay-autoplay/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Ecco due snippets di codice per avere l&#8217;autoplay dello &#8220;slider&#8221; e il play sul click sull&#8217;immagine.<br />
Per ora sono snippets di codice esterni alla libreria.<br />
Nella futura versione ci saranno le opzioni</p>
<ul>
<li> autoplay</li>
<li>clicknplay (ycodagallery)</li>
</ul>
<p><strong><br />
<a href="http://www.maxb.net/scripts/ycodaslider-3.0/demo/docs/lazyload/3.html" target="_blank">AUTOPLAY GALLERY + LAZYLOAD</a></strong></p>
<pre class="brush: jscript; title: ; notranslate">
jQuery(window).ycodacss('ycodaslider-3.0.css');
jQuery(window).ycodacss('ycodaslider-3.0.css');
jQuery(document).ready(function() {
	jQuery(&quot;#panel-gallery&quot;)
    .ycodagallery()
    .ycodalazy();
});
jQuery(window).bind(&quot;load&quot;, function() {
    jQuery(&quot;#panel-gallery&quot;)
    .ycodaslider({
    	navigator: false,
    	arrows : false
    });

    setInterval(function(){
    	jQuery(&quot;#panel-gallery&quot;).ycodaslider(&quot;right&quot;);
    }, 2000);
});
</pre>
<p><strong><a href="http://www.maxb.net/scripts/ycodaslider-3.0/demo/docs/slider/7.html" target="_blank">AUTOPLAY SLIDER</a></strong></p>
<pre class="brush: jscript; title: ; notranslate">
jQuery(window).ycodacss('ycodaslider-3.0.css');
jQuery(window).bind(&quot;load&quot;, function() {
    jQuery(&quot;div.ycodaslider&quot;)
    .ycodaslider({arrows: false, navigator: false});

    setInterval(function(){
    	jQuery(&quot;div.ycodaslider&quot;).ycodaslider(&quot;right&quot;);
    }, 2000);
});
</pre>
<p><strong><a href="http://www.maxb.net/scripts/ycodaslider-3.0/demo/docs/gallery/2.html" target="_blank">CLICK&#8217;N'PLAY</a></strong></p>
<pre class="brush: jscript; title: ; notranslate">
jQuery(window).ycodacss('ycodaslider-3.0.css');
jQuery(window).bind(&quot;load&quot;, function() {
    jQuery(&quot;#panel-gallery&quot;)
    .ycodagallery()
    .ycodaslider({navigator: false, arrows: false});

    jQuery(&quot;#panel-gallery&quot;).find(&quot;img&quot;).wrap('&lt;a href=&quot;#&quot;&gt;');
    jQuery(&quot;#panel-gallery&quot;).find(&quot;a&quot;).click(function(){
    	jQuery(&quot;#panel-gallery&quot;).ycodaslider(&quot;right&quot;);
    	return false;
    });
});
</pre>
]]></content:encoded>
			<wfw:commentRss>http://maxb.net/blog/2009/03/09/ycodaslider-30-clicknplay-autoplay/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>YCodaSlider 3.0 – Changelog</title>
		<link>http://maxb.net/blog/2009/03/06/ycodaslider-30-changelog/</link>
		<comments>http://maxb.net/blog/2009/03/06/ycodaslider-30-changelog/#comments</comments>
		<pubDate>Fri, 06 Mar 2009 10:00:09 +0000</pubDate>
		<dc:creator>Massimiliano Balestrieri</dc:creator>
				<category><![CDATA[javascript]]></category>
		<category><![CDATA[jquery]]></category>
		<category><![CDATA[plugins]]></category>
		<category><![CDATA[ycodaslider]]></category>

		<guid isPermaLink="false">http://maxb.net/blog/?p=236</guid>
		<description><![CDATA[updated to jquery 1.3.2 scrolltop: very important when &#8220;panels&#8221; have contents of different hights unstable piece of code have been delated: ycodaframe, history option dragging option and dependence from jQuery UI (basically unusefull) have been delated plugins in 2.0 (gallery, &#8230; <a href="http://maxb.net/blog/2009/03/06/ycodaslider-30-changelog/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<ul>
<li>updated to <strong>jquery 1.3.2</strong></li>
<li><strong>scrolltop</strong>: very important when &#8220;panels&#8221; have contents of different hights</li>
<li>unstable piece of code have been delated: ycodaframe, history option</li>
<li>dragging option and dependence from jQuery UI (basically unusefull) have been delated</li>
</ul>
<ul>
<li>plugins in 2.0 (gallery, lazyload, feeds, code) now have been unified in a single file (easier to use. only 5KB the packed version. 9 KB the minified version)
<ul>
<li><span style="color: #000000;">jQuery</span><span style="color: #ff0000;"><span style="color: #000000;">(window).ycodacss ->to load the css.<br />
</span></span></li>
<li><span style="color: #000000;">jQuery(selector).ycodaslider -> to start up the component.</span></li>
<li><span style="color: #000000;">jQuery</span><span style="color: #000000;">(selector).ycodagallery -> prepares a list of images. To be used &#8220;in chain&#8221; with ycodaslider.</span></li>
<li><span style="color: #000000;">jQuery</span><span style="color: #000000;">(selector).ycodalazy -> starts up the lazyload on the list of images. To be used &#8220;in chain&#8221; with ycodagallery in event <strong>ready</strong>.  Launch ycodaslider on the event <strong>load</strong>.</span></li>
<li><span style="color: #000000;">jQuery</span><span style="color: #000000;">(selector).ycodacode -> prepares a list of links to sources, to be used &#8220;in chain&#8221; with ycodaslider. (optional jQuery Chili 2.2)<br />
</span></li>
<li><span style="color: #000000;">jQuery</span><span style="color: #000000;">(selector).ycodafeeds -> prepares a list of links to rss sources,  to be used &#8220;in chain&#8221; with ycodaslider. (needs  jQuery gFeeds e API google)</span></li>
</ul>
</li>
</ul>
<ul>
<li>I only kept separate the plugin fickr, which is just an example of how you can link ycodaslider
<ul>
<li><span style="color: #000000;">jQuery</span><span style="color: #000000;">(selector).ycodaflickr -> example of external component. (see also ycodagallery, ycodacode e ycodafeeds to write plugins for ycodaslider)</span></li>
</ul>
</li>
</ul>
<ul>
<li>jquery easing is no longer essential: jquery 1.3 has the swing effect as a default animation. Simply set at 0 the parameter easeTime if you don&#8217;t  want to have animation.</li>
<li>default keyboards shorcuts  are now the two arrows left &amp; right (keyboard codes are the same in all platforms)</li>
</ul>
<ul>
<li>I made a <strong>API using jquery UI style</strong>:
<ul>
<li>jQuery(selector).ycodaslider(&#8220;right&#8221;); -> invoke event right. ycodaslider will move right.</li>
<li>jQuery(selector).ycodaslider(&#8220;left&#8221;); -> invoke event left. ycodaslider will move left.</li>
<li>jQuery(selector).ycodaslider(&#8220;go&#8221;, N); -> invoke event go where N is the number of the panel to visualize (starting from 0)</li>
<li>jQuery(&#8220;#id&#8221;).ycodaslider(&#8220;currrent&#8221;); -> returns the panel active</li>
<li>jQuery(&#8220;#id&#8221;).ycodaslider(&#8220;count&#8221;); -> returns the number of panels</li>
<li>jQuery(&#8220;#id&#8221;).ycodaslider(&#8220;width&#8221;); -> returns the width of the component</li>
</ul>
</li>
<li>complete <strong>code refactory</strong></li>
<li>possibility of tracking click with janalytics plugin to have the statistics (google analytics)</li>
<li>a <strong>single css</strong> (easy to customize &#8211; <strong>the design of the demo has a minimalist design</strong>)</li>
<li><strong>easier to use</strong></li>
</ul>
<ul>
<li><strong>tested on the following browser:</strong>
<ul>
<li>firefox 3 (linux/windows xp)</li>
<li>internet explorer 6/7</li>
<li>chrome (windows xp)</li>
<li>safari 3.2.2/safari 4Beta (windows xp)</li>
<li>opera 9.6 (windows xp)</li>
</ul>
</li>
</ul>
<ul>
<li>known bugs
<ul>
<li>IE6: the last panel sometimes literally fall under the second last, leaving empty the last card</li>
</ul>
</li>
</ul>
<ul>
<li>All examples:
<ul>
<li><a href="http://www.maxb.net/scripts/ycodaslider-3.0/demo/docs/slider/1.html" target="_blank">EFFECTS<br />
</a></li>
<li><a href="http://www.maxb.net/scripts/ycodaslider-3.0/demo/docs/slider/2.html" target="_blank">API</a></li>
<li><a href="http://www.maxb.net/scripts/ycodaslider-3.0/demo/docs/slider/3.html" target="_blank">SHORTCUTS</a></li>
<li><a href="http://www.maxb.net/scripts/ycodaslider-3.0/demo/docs/slider/4.html" target="_blank">CHINABILITY</a></li>
<li><a href="http://www.maxb.net/scripts/ycodaslider-3.0/demo/docs/slider/5.html" target="_blank">DIMENSIONS</a></li>
<li><a href="http://www.maxb.net/scripts/ycodaslider-3.0/demo/docs/slider/6.html" target="_blank">NO MENU &amp; ARROWS</a></li>
<li><a href="http://www.maxb.net/scripts/ycodaslider-3.0/demo/docs/gallery/1.html" target="_blank">GALLERY</a></li>
<li><a href="http://www.maxb.net/scripts/ycodaslider-3.0/demo/docs/lazyload/1.html" target="_blank">LAZYLOAD</a></li>
<li><a href="http://www.maxb.net/scripts/ycodaslider-3.0/demo/docs/lazyload/2.html" target="_blank">LAZYLOAD EXPLANATION</a></li>
<li><a href="http://www.maxb.net/scripts/ycodaslider-3.0/demo/docs/feeds/1.html" target="_blank">FEED RSS</a></li>
<li><a href="http://www.maxb.net/scripts/ycodaslider-3.0/demo/docs/code/1.html" target="_blank">CODE</a></li>
<li><a href="http://www.maxb.net/scripts/ycodaslider-3.0/demo/docs/flickr/1.html" target="_blank">EXTERNAL PLUGIN &#8220;FLICKR&#8221;</a></li>
<li><strong><a href="http://www.maxb.net/scripts/ycodaslider-3.0/demo/" target="_blank">DEMO SITE<br />
</a></strong></li>
</ul>
</li>
</ul>
<p>if  you have any suggestions, if you find a bug or you use the plugin, please leave a comment here.<br />
PS: <a href="http://perassi.org/" target="_blank">Carlo</a>&#8230; spero vada bene <img src='http://maxb.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>UPDATE 2008-03-09 :</p>
<ul>
<li>Autoplay &amp; play on click
<ul>
<li><a href="http://www.maxb.net/scripts/ycodaslider-3.0/demo/docs/lazyload/3.html" target="_blank">AUTOPLAY LAZYLOAD<br />
</a></li>
<li><a href="http://www.maxb.net/scripts/ycodaslider-3.0/demo/docs/slider/7.html" target="_blank">AUTOPLAY SLIDER<br />
</a></li>
<li><a href="http://www.maxb.net/scripts/ycodaslider-3.0/demo/docs/gallery/2.html" target="_blank">PLAY ON CLICK<br />
</a></li>
</ul>
</li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://maxb.net/blog/2009/03/06/ycodaslider-30-changelog/feed/</wfw:commentRss>
		<slash:comments>11</slash:comments>
		</item>
		<item>
		<title>YCodaSlider 3.0</title>
		<link>http://maxb.net/blog/2009/03/05/ycodaslider-30/</link>
		<comments>http://maxb.net/blog/2009/03/05/ycodaslider-30/#comments</comments>
		<pubDate>Thu, 05 Mar 2009 18:01:35 +0000</pubDate>
		<dc:creator>Massimiliano Balestrieri</dc:creator>
				<category><![CDATA[javascript]]></category>
		<category><![CDATA[jquery]]></category>
		<category><![CDATA[plugins]]></category>
		<category><![CDATA[ycodaslider]]></category>

		<guid isPermaLink="false">http://maxb.net/blog/?p=231</guid>
		<description><![CDATA[DEMO SITE. Slider scripts are one of the common objects of newspaper &#38; portal websites. They are very useful as they help us present more content in a limited space. This script helps you present your content with a tabbed &#8230; <a href="http://maxb.net/blog/2009/03/05/ycodaslider-30/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p><a title="BETA SITE" href="http://www.maxb.net/scripts/ycodaslider-3.0/demo/" target="_blank"><img src="/scripts/ycodaslider-2.0/include/icons/beta.gif" alt="" /></a> <a href="http://www.maxb.net/scripts/ycodaslider-3.0/demo/" target="_blank">DEMO SITE.</a></p>
<blockquote><p>Slider scripts are one of the common objects of newspaper &amp; portal websites.<br />
They are very useful as they help us present more content in a limited space.<br />
This script helps you present your content with a tabbed menu + previous-next buttons to switch between tabs.<br />
YCodaSlider 2.0 requires jQuery to run and you can use any type of content inside the slider like HTML, Flash, webpages etc.<br />
It can be configured easily to use different effects while changing the content.<br />
<strong><em>from :<br />
<a href="http://www.webresourcesdepot.com/coda-like-slider-ycodaslider-20">www.webresourcesdepot.com</a></em></strong></p></blockquote>
<p>Based on Gian Carlo Mingati&#8217;s slideViewer<br />
<a href="http://www.gcmingati.net/wordpress/wp-content/lab/jquery/imagestrip/imageslide-plugin.html">http://www.gcmingati.net/wordpress/wp-content/lab/jquery/imagestrip/imageslide-plugin.html</a></p>
<p>Based on Niall Doherty&#8217;s coda-slider<br />
<a href="http://www.ndoherty.com/coda-slider">http://www.ndoherty.com/coda-slider</a></p>
<p>Inspired by the clever folks at <a href="http://www.panic.com/coda">http://www.panic.com/coda</a></p>
]]></content:encoded>
			<wfw:commentRss>http://maxb.net/blog/2009/03/05/ycodaslider-30/feed/</wfw:commentRss>
		<slash:comments>6</slash:comments>
		</item>
		<item>
		<title>Benchmark – YCodaSlider 2.0rc2</title>
		<link>http://maxb.net/blog/2008/05/23/benchmark-ycodaslider-20rc2/</link>
		<comments>http://maxb.net/blog/2008/05/23/benchmark-ycodaslider-20rc2/#comments</comments>
		<pubDate>Fri, 23 May 2008 18:51:19 +0000</pubDate>
		<dc:creator>Massimiliano Balestrieri</dc:creator>
				<category><![CDATA[jquery]]></category>
		<category><![CDATA[plugins]]></category>
		<category><![CDATA[ycodaslider]]></category>
		<category><![CDATA[benchmark]]></category>
		<category><![CDATA[javascript]]></category>

		<guid isPermaLink="false">http://maxb.net/blog/?p=44</guid>
		<description><![CDATA[Ho corretto numerosi bug. Pulito il codice. Ora esegue mediamente in 70-80ms su Firefox 2.0 settando una larghezza iniziale. La velocità è praticamente triplicata. BENCHMARK: PRIMA METODI: PRIMA Benchmark 1 Benchmark 2 YCodaSlider 2.0rc2 &#8211; SVN &#8211; rev 121 YCodaSlider &#8230; <a href="http://maxb.net/blog/2008/05/23/benchmark-ycodaslider-20rc2/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Ho corretto numerosi bug. Pulito il codice. Ora esegue mediamente in 70-80ms su Firefox 2.0 settando una larghezza iniziale. La velocità è praticamente triplicata.</p>
<p>BENCHMARK:</p>
<p><a href='http://maxb.net/blog/wp-content/uploads/2008/05/rc2-73ms.png'><img src="http://maxb.net/blog/wp-content/uploads/2008/05/rc2-73ms.png" alt="" title="rc2-73ms" class="alignnone size-full wp-image-49" /></a></p>
<p>PRIMA</p>
<p><a href='http://maxb.net/blog/wp-content/uploads/2008/05/rc1-186.png'><img src="http://maxb.net/blog/wp-content/uploads/2008/05/rc1-186.png" alt="" title="rc1-186" class="alignnone size-full wp-image-51" /></a></p>
<p>METODI:</p>
<p><a href='http://maxb.net/blog/wp-content/uploads/2008/05/rc2-methods2.png'><img src="http://maxb.net/blog/wp-content/uploads/2008/05/rc2-methods2.png" alt="" title="rc2-methods2" class="alignnone size-full wp-image-50" /></a></p>
<p>PRIMA</p>
<p><a href='http://maxb.net/blog/wp-content/uploads/2008/05/prima1.png'><img src="http://maxb.net/blog/wp-content/uploads/2008/05/prima1.png" alt="" title="prima1" class="alignnone size-full wp-image-45" /></a></p>
<p><a href="http://www.maxb.net/scripts/benchmark/24.html">Benchmark 1</a><br />
<a href="http://www.maxb.net/scripts/benchmark/26.html">Benchmark 2</a><br />
<a href="http://www.maxb.net/scripts/benchmark/lib/ycodaslider-2.0.svn.js">YCodaSlider 2.0rc2 &#8211; SVN &#8211; rev 121</a></p>
<p><a href="/blog/2008/05/11/ycodaslider-20/">YCodaSlider 2.0rc2 out.</a><br />
<a href="/scripts/ycodaslider-2.0/include/demo/">DEMO SITE</a></p>
]]></content:encoded>
			<wfw:commentRss>http://maxb.net/blog/2008/05/23/benchmark-ycodaslider-20rc2/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Benchmark – YCodaslider 2.0 refactory</title>
		<link>http://maxb.net/blog/2008/05/23/benchmark-ycodaslider-20-refactory/</link>
		<comments>http://maxb.net/blog/2008/05/23/benchmark-ycodaslider-20-refactory/#comments</comments>
		<pubDate>Fri, 23 May 2008 10:38:32 +0000</pubDate>
		<dc:creator>Massimiliano Balestrieri</dc:creator>
				<category><![CDATA[javascript]]></category>
		<category><![CDATA[jquery]]></category>
		<category><![CDATA[plugins]]></category>
		<category><![CDATA[ycodaslider]]></category>
		<category><![CDATA[benchmark]]></category>

		<guid isPermaLink="false">http://maxb.net/blog/?p=41</guid>
		<description><![CDATA[PRIMA: DOPO: Dal lavoro sui metodi ho capito cosa rende lento il plugin. Ho meglio più che lento, cosa inficia maggiormente sul tempo di esecuzione di YCodaSlider 2.0: Benchmark Il metodo nav() impiega circa 130ms per essere eseguito (firefox 2.0). &#8230; <a href="http://maxb.net/blog/2008/05/23/benchmark-ycodaslider-20-refactory/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>PRIMA:</p>
<p><a href='http://maxb.net/blog/wp-content/uploads/2008/05/prima.png'><img src="http://maxb.net/blog/wp-content/uploads/2008/05/prima.png" alt="" title="prima" class="alignnone size-full wp-image-43" /></a></p>
<p>DOPO:</p>
<p><a href='http://maxb.net/blog/wp-content/uploads/2008/05/dopo.png'><img src="http://maxb.net/blog/wp-content/uploads/2008/05/dopo.png" alt="" title="dopo" class="alignnone size-full wp-image-42" /></a></p>
<p>Dal lavoro sui metodi ho capito cosa rende lento il plugin. Ho meglio più che lento, cosa inficia maggiormente sul tempo di esecuzione di YCodaSlider 2.0:</p>
<p><a href="http://www.maxb.net/scripts/benchmark/13.html">Benchmark</a></p>
<p>Il metodo nav() impiega circa 130ms per essere eseguito (firefox 2.0).</p>
<pre class="brush: jscript; title: ; notranslate">
    nav    :   function(el){
        var jViewer = jQuery(&quot;div.yslider-viewer&quot;,el);
        jViewer.before('&lt;div class=&quot;yslider-navl&quot;&gt;&lt;a href=&quot;#&quot;&gt;Left&lt;/a&gt;&lt;/div&gt;');
        jViewer.after('&lt;div class=&quot;yslider-navr&quot;&gt;&lt;a href=&quot;#&quot;&gt;Right&lt;/a&gt;&lt;/div&gt;');
        jViewer.before('&lt;div class=&quot;yslider-nav&quot;&gt;&lt;ul&gt;&lt;\/ul&gt;&lt;/div&gt;');
        var jNav = jQuery(&quot;div.yslider-nav ul&quot;,el);
        var jPanels = jQuery(&quot;div.yslider-panel&quot;,el);
        jPanels.each(function(n) {
            var lp = jQuery(&quot;div.yslider-panelwrapper&quot;,this).attr(&quot;title&quot;) || (n+1);
            if(el.ycodaslider.options.history){
                 jQuery('&lt;li&gt;&lt;a href=&quot;#' + (n + 1) + '&quot;&gt;' + lp + '&lt;/a&gt;&lt;/li&gt;').appendTo(jNav);
            }else{
                jQuery('&lt;li&gt;&lt;a href=&quot;#&quot;&gt;' + lp + '&lt;/a&gt;&lt;/li&gt;').appendTo(jNav).click(function(){
                   return false;
                });
            }
        });
        //setto la larghezza del menu qui.
        jNav.find(&quot;li&quot;).each(function(nr){
            el.ycodaslider.nw += jQuery(this).width();
        });
        if(el.ycodaslider.options.width)
            jNav.parent().css({&quot;width&quot; : el.ycodaslider.options.width});
        else
            jNav.parent().css(&quot;width&quot; , el.ycodaslider.nw);

    }
</pre>
<p>Commentando questo ottengo un centinaio di ms di risparmio</p>
<pre class="brush: jscript; title: ; notranslate">
//questo costa 100ms!
jNav.find(&quot;li&quot;).each(function(nr){
    el.ycodaslider.nw += jQuery(this).width();
});
</pre>
<p>Innanzitutto non c&#8217;è bisogno di calcolare la larghezza dei tag LI per avere una corretta larghezza del contenitore.<br />
<strong>In ogni caso il metodo width applicato ad un elemento che non ha una larghezza impostata da css è notevolmente lento.</strong><br />
Penso che calcoli il numero di caratteri per il font per ottenere una larghezza in pixels.</p>
<blockquote><p>Non usare il metodo width se non è settata la proprietà css width.</p></blockquote>
<p>Ora il metodo viene eseguito in 12ms. </p>
<p><a href="http://www.maxb.net/scripts/benchmark/14.html">Benchmark</a></p>
<blockquote><p>el.ycodaslider.nw = el.ycodaslider.pc * 2; </p></blockquote>
<blockquote><p>el.ycodaslider.nw = el.ycodaslider.pw;//el.ycodaslider.pc * 2 ? </p></blockquote>
<p>Veniva calcolata la larghezza del navigatore moltiplicando per due il numero dei pannelli. Perchè?<br />
Non lo so. Refuso.</p>
<p>In realtà la larghezza del navigartore è uguale alla larghezza del pannello.</p>
<p>Correggendo questo valore ho modificato il metodo nav al fondo con questo:</p>
<pre class="brush: jscript; title: ; notranslate">
if(el.ycodaslider.options.width){
      jNav.parent().css({&quot;width&quot; : el.ycodaslider.options.width});
}else{
     jNav.parent().css(&quot;width&quot; , el.ycodaslider.nw );
}
</pre>
<p>Ecco il benchmark aggiornato con il metodo nav e il metodo count corretti. </p>
<p><a href="http://www.maxb.net/scripts/benchmark/15.html">Benchmark</a></p>
<p>Notare come il lunghissimo metodo bindings non pesi niente. Grazie alle clousure infatti praticamente il codice viene attaccato all&#8217;handler e verrà valutato solo al bind dell&#8217;evento.</p>
<p>Ma per questo bisogna ringraziare jQuery e John Resig.</p>
]]></content:encoded>
			<wfw:commentRss>http://maxb.net/blog/2008/05/23/benchmark-ycodaslider-20-refactory/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Benchmark 1.0 – Peso dei metodi</title>
		<link>http://maxb.net/blog/2008/05/23/benchmark-10-methods-weight/</link>
		<comments>http://maxb.net/blog/2008/05/23/benchmark-10-methods-weight/#comments</comments>
		<pubDate>Fri, 23 May 2008 09:14:40 +0000</pubDate>
		<dc:creator>Massimiliano Balestrieri</dc:creator>
				<category><![CDATA[javascript]]></category>
		<category><![CDATA[jquery]]></category>
		<category><![CDATA[benchmark]]></category>
		<category><![CDATA[ycodaslider]]></category>

		<guid isPermaLink="false">http://maxb.net/blog/?p=36</guid>
		<description><![CDATA[Ho portato avanti l&#8217;esperimento del plugin &#8220;benchmark&#8221;. Modificando il plugin benchmark, ho trovato un sistema accettabile per adattare il plugin creato al calcolo del &#8220;peso&#8221; dei metodi di un plugin. Qui la verisione usata: svn metodi Ecco il risultato: Il &#8230; <a href="http://maxb.net/blog/2008/05/23/benchmark-10-methods-weight/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Ho portato avanti l&#8217;esperimento del plugin &#8220;benchmark&#8221;.</p>
<p>Modificando il plugin benchmark, ho trovato un sistema accettabile per adattare il plugin creato al calcolo del &#8220;peso&#8221; dei metodi di un plugin. Qui la verisione usata: <a href="/scripts/benchmark/benchmark/benchmark.svn.js">svn</a></p>
<p><a href="/scripts/benchmark/13.html">metodi </a></p>
<p>Ecco il risultato:</p>
<p><a href='http://maxb.net/blog/wp-content/uploads/2008/05/methods1.png'><img src="http://maxb.net/blog/wp-content/uploads/2008/05/methods1.png" alt="" title="methods1"  class="alignnone size-full wp-image-38" /></a></p>
<p>Il widget non è nascosto. E&#8217; visibile. <strong>Ho capito che lavorare su elementi nascosti è sviante.</strong>. E&#8217; vero ci impiega meno, ma se utilizzi i metodi width() e height() questi forniranno dati sbagliati e di fondo il codice sbaglia nellìeseguire le funzioni.</p>
<p>I risultati mi sembrano attendibili. Ogni metodo ha un suo peso.</p>
<table class="rs">
<tr>
<th>&nbsp;</th>
<th>YCodaSlider 2.0</th>
</tr>
<tr>
<th>build</th>
<td>0 ms</td>
</tr>
<tr>
<th>gui</th>
<td>35 ms</td>
</tr>
<tr>
<th>count</th>
<td>26 ms</td>
</tr>
<tr>
<th>init</th>
<td>3 ms</td>
</tr>
<tr>
<th>start</th>
<td>0 ms</td>
</tr>
<tr>
<th>nav</th>
<td>168 ms</td>
</tr>
<tr>
<th>bindings</th>
<td>7 ms</td>
</tr>
<tr>
<th>defaults</th>
<td>2 ms</td>
</tr>
</table>
<p>I test sono stati effettuati su firefox 2.0 con firebug attivo.<br />
Con firefox 3.0 gli stessi test sono nettamente più veloci (evviva!)</p>
<p>Nav è il primo metodo da rifattorizzare.</p>
]]></content:encoded>
			<wfw:commentRss>http://maxb.net/blog/2008/05/23/benchmark-10-methods-weight/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>YCodaSlider 2.0 rc2</title>
		<link>http://maxb.net/blog/2008/05/11/ycodaslider-20/</link>
		<comments>http://maxb.net/blog/2008/05/11/ycodaslider-20/#comments</comments>
		<pubDate>Sun, 11 May 2008 12:52:00 +0000</pubDate>
		<dc:creator>Massimiliano Balestrieri</dc:creator>
				<category><![CDATA[jquery]]></category>
		<category><![CDATA[plugins]]></category>
		<category><![CDATA[thablesorter]]></category>
		<category><![CDATA[ycodaslider]]></category>
		<category><![CDATA[javascript]]></category>

		<guid isPermaLink="false">http://maxb.net/blog/?p=24</guid>
		<description><![CDATA[(UPDATE 2009-03-05) &#8211; YCODASLIDER 3.0. Slider scripts are one of the common objects of newspaper &#038; portal websites. They are very useful as they help us present more content in a limited space. This script helps you present your content &#8230; <a href="http://maxb.net/blog/2008/05/11/ycodaslider-20/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p><a title="BETA SITE" href="http://maxb.net/blog/2009/03/05/ycodaslider-30/"><img src="/scripts/ycodaslider-2.0/include/icons/beta.gif" alt="" /></a> <a href="http://maxb.net/blog/2009/03/05/ycodaslider-30/">(UPDATE 2009-03-05) &#8211; YCODASLIDER 3.0.</a></p>
<blockquote>
<p>
        Slider scripts are one of the common objects of newspaper &#038; portal websites.<br />
        They are very useful as they help us present more content in a limited space.<br />
        This script helps you present your content with a tabbed menu + previous-next buttons to switch between tabs.<br />
        YCodaSlider 2.0 requires jQuery to run and you can use any type of content inside the slider like HTML, Flash, webpages etc.<br />
        It can be configured easily to use different effects while changing the content.<br />
        <strong><em>from :<br />
        <a href="http://www.webresourcesdepot.com/coda-like-slider-ycodaslider-20">www.webresourcesdepot.com</a></em></strong>
        </p>
</blockquote>
<p>Based on Gian Carlo Mingati&#8217;s slideViewer<br />
<a href="http://www.gcmingati.net/wordpress/wp-content/lab/jquery/imagestrip/imageslide-plugin.html"><br />
http://www.gcmingati.net/wordpress/wp-content/lab/jquery/imagestrip/imageslide-plugin.html</a></p>
<p>Based on Niall Doherty&#8217;s coda-slider<br />
<a href="http://www.ndoherty.com/coda-slider">http://www.ndoherty.com/coda-slider</a></p>
<p>Inspired by the clever folks at <a href="http://www.panic.com/coda">http://www.panic.com/coda</a></p>
<p>UPDATES:<br />
2008-05-24 &#8211; RC2 : refactory ycodaslider code. add sidebars option. fix nav width bug. cut pre-loading code and yslider-toggle css class</p>
<p>2008-05-19 &#8211; fix ie6 bugs in demo site (css properties, png/gif replace, padding, tag pre+code) and  moz-user-select in galleries. TODO: keycodes abstraction layer for different platforms.</p>
]]></content:encoded>
			<wfw:commentRss>http://maxb.net/blog/2008/05/11/ycodaslider-20/feed/</wfw:commentRss>
		<slash:comments>40</slash:comments>
		</item>
		<item>
		<title>YCodaSlider 0.9</title>
		<link>http://maxb.net/blog/2008/05/09/ycodaslider-09/</link>
		<comments>http://maxb.net/blog/2008/05/09/ycodaslider-09/#comments</comments>
		<pubDate>Fri, 09 May 2008 09:21:45 +0000</pubDate>
		<dc:creator>Massimiliano Balestrieri</dc:creator>
				<category><![CDATA[javascript]]></category>
		<category><![CDATA[jquery]]></category>
		<category><![CDATA[plugins]]></category>
		<category><![CDATA[ycodaslider]]></category>

		<guid isPermaLink="false">http://maxb.net/blog/?p=21</guid>
		<description><![CDATA[Ho detto un paio&#8230; Questo plugin ci tenevo a pubblicarlo. E&#8217; una copia di questo. Fatto a mano. Ragionando sulle animazioni. E fatto tempo&#8230; fa. Nel frattempo, ma come sempre, alcune tecniche non le avrei più utilizzate. Non conoscevo questo &#8230; <a href="http://maxb.net/blog/2008/05/09/ycodaslider-09/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p><a href="http://maxb.net/blog/2008/05/09/togglepanel-09/">Ho detto un paio&#8230;</a></p>
<p>Questo plugin ci tenevo a pubblicarlo.<br />
E&#8217; una copia di <a href="http://www.panic.com/coda/">questo</a>.<br />
Fatto a mano. Ragionando sulle animazioni.<br />
E fatto tempo&#8230; fa. Nel frattempo, ma come sempre, alcune tecniche non le avrei più utilizzate.</p>
<p>Non conoscevo questo <a href="http://www.ndoherty.com/demos/coda-slider/1.1/">plugin</a> ne tantomeno <a href="http://www.gcmingati.net/wordpress/wp-content/lab/jquery/imagestrip/imageslide-plugin.html">questo</a>.</p>
<p>Sicuramente è più stabile del mio.<br />
Lo pubblico solamente perchè ho fatto parecchia fatica a scriverlo.<br />
Se dovete usare uno slider usate i due plugin segnalati sopra. Il mio è legato ad un progetto. Ha troppa presentazione schiantata nel codice. </p>
<ul>
<li><a href="http://maxb.net/scripts/ycodaslider/lib/ycodaslider.js">Download</a></li>
</ul>
<p>Depends</p>
<ul>
<li>jQuery 1.2.3</li>
<li>Easing</li>
</ul>
<p><a href="/scripts/ycodaslider/">Demo basilare</a></p>
<pre class="brush: jscript; title: ; notranslate">
$(document).ready(function(){
    $(&quot;.ui_ycodaslider_container&quot;).YCodaSlider(
        {
         height      : '630px',
         heightcont  : '680px',
         width       : '770px',
         test        : 0
        }
    );
});
</pre>
<p><a href="http://www.storiaindustria.it/scuola_didattica/siti.shtml">Real World 1</a></p>
<pre class="brush: jscript; title: ; notranslate">
$(document).ready(function(){
    $(&quot;.ui_ycodaslider_container&quot;).YCodaSlider(
			{
			css	: '/js/lib/jquery-1.2.1/plugins/ycodaslider/css/ycodaslider.css',
			cssprint: '/js/lib/jquery-1.2.1/plugins/ycodaslider/css/ycodaslider.print.css',
			skin	: '/js/lib/jquery-1.2.1/plugins/ycodaslider/css/skins/storiaindustria/skin.css',
			height	: '630px',
			heightcont : '680px',
			width	: '763px',
			textprev : '&lt;img src=&quot;/scuola_didattica/im/freccia_gialla_sx.jpg&quot; alt=&quot;precedente&quot; /&gt;',
			textnext : '&lt;img src=&quot;/scuola_didattica/im/freccia_gialla_dx.jpg&quot; alt=&quot;successivo&quot; /&gt;'
			}
		);
});
</pre>
]]></content:encoded>
			<wfw:commentRss>http://maxb.net/blog/2008/05/09/ycodaslider-09/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

