<?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>SDAC Inc &#124; Chicagoland Web Development &#187; Javascript</title> <atom:link href="http://www.sandboxdev.com/category/blog/javascript/feed/" rel="self" type="application/rss+xml" /><link>http://www.sandboxdev.com</link> <description>Just another Sandbox Development and Consulting Inc. Sites site</description> <lastBuildDate>Wed, 25 Jan 2012 07:57:33 +0000</lastBuildDate> <language>en</language> <sy:updatePeriod>hourly</sy:updatePeriod> <sy:updateFrequency>1</sy:updateFrequency> <generator>http://wordpress.org/?v=3.3.1</generator> <item><title>Remove Initial Flicker With Smooth Gallery</title><link>http://www.sandboxdev.com/2008/11/03/remove-initial-flicker-with-smooth-gallery/</link> <comments>http://www.sandboxdev.com/2008/11/03/remove-initial-flicker-with-smooth-gallery/#comments</comments> <pubDate>Tue, 04 Nov 2008 01:51:50 +0000</pubDate> <dc:creator>Jennifer Zelazny</dc:creator> <category><![CDATA[CSS]]></category> <category><![CDATA[HOWTOs]]></category> <category><![CDATA[Javascript]]></category> <category><![CDATA[SDAC Blog]]></category> <category><![CDATA[MooTools]]></category> <category><![CDATA[Smooth Gallery]]></category> <guid
isPermaLink="false">http://www.sandboxdev.com/?p=406</guid> <description><![CDATA[I recently created a site (in beta testing now) with Smooth Gallery and the client loved it. The Problem: The only issue was that upon the initial page load &#8211; all items in the gallery would flicker for a second or two while the first image loaded &#8211; causing this to not look professional at [...]]]></description> <content:encoded><![CDATA[<p>I recently created a site (in beta testing now) with <a
href="http://smoothgallery.jondesign.net/what/">Smooth Gallery</a> and the client loved it.</p><p><strong>The Problem:</strong><br
/> The only issue was that upon the initial page load &#8211; all items in the gallery would flicker for a second or two while the first image loaded &#8211; causing this to not look professional at all.</p><p><strong>The Solution:</strong></p><ol><li><strong>HTML:</strong> I took the example code:<pre class="brush: php; title: Custom Code; notranslate">
&lt;div&gt;
  &lt;div class=&quot;imageElement&quot; id=&quot;element&quot;&gt;
      &lt;h3&gt;Item 1 Title&lt;/h3&gt;
      &lt;p&gt;Item 1 Description&lt;/p&gt;
      &lt;a href=&quot;#&quot; title=&quot;open image&quot; class=&quot;open&quot;&gt;&lt;/a&gt;
      &lt;img src=&quot;images/brugges2006/1.jpg&quot; class=&quot;full&quot; /&gt;
      &lt;img src=&quot;images/brugges2006/1-mini.jpg&quot; class=&quot;thumbnail&quot; /&gt;
   &lt;/div&gt;
 &lt;/div&gt;
</pre><p>I then added an ID to each div (id=&#8221;element1&#8243;) so that each div had a class of &#8220;imageElement&#8221; and a unique ID (element1, element2, etc).</li><li><strong>CSS:</strong> Now that I had IDs to style, I added the following to my style sheet:<pre class="brush: css; title: Custom Code; notranslate">
#element2 {display: none;}
</pre><li></ol><p>By adding the 2 bits of code mentioned below, I was able to initially hide the content in the second div so that only the content in the first div appeared on page load.  Once the script started running, it then changed the display from none to block automatically.  Problem solved.</p> <script type="text/javascript">sdac_post_slideshows.push({fx: 'fade', timeout: 0, speed: 1000, pause: 0,})</script>]]></content:encoded> <wfw:commentRss>http://www.sandboxdev.com/2008/11/03/remove-initial-flicker-with-smooth-gallery/feed/</wfw:commentRss> <slash:comments>3</slash:comments> </item> <item><title>Upgrade Google Analytic Tracker Code</title><link>http://www.sandboxdev.com/2008/01/18/upgrade-google-analytic-tracker-code/</link> <comments>http://www.sandboxdev.com/2008/01/18/upgrade-google-analytic-tracker-code/#comments</comments> <pubDate>Fri, 18 Jan 2008 21:56:52 +0000</pubDate> <dc:creator>Jennifer Zelazny</dc:creator> <category><![CDATA[HOWTOs]]></category> <category><![CDATA[Javascript]]></category> <category><![CDATA[Code]]></category> <category><![CDATA[Google]]></category> <category><![CDATA[Update]]></category> <guid
isPermaLink="false">http://www.sandboxdev.com/blog/javascript/2008/01/18/upgrade-google-analytic-tracker-code.php</guid> <description><![CDATA[If you use Google Analytics on your web site, you should update your tracker code that is placed in your code. The new tracker is faster, and offers added tracking functionality (See Google&#8217;s announcement) New Code: (put your tracker ID in where you see the X&#8217;s) While you are updating your code, you might also [...]]]></description> <content:encoded><![CDATA[<p>If you use <a
href="http://www.google.com/analytics/">Google Analytics</a> on your web site, you should update your tracker code that is placed in your code. The new tracker is faster, and offers added tracking functionality (<a
href="http://analytics.blogspot.com/2007/12/announcing-new-graphing-tools-gajs.html">See Google&#8217;s announcement</a>)</p><p>New Code: (put your tracker ID in where you see the X&#8217;s)</p><pre class="brush: xml; title: Custom Code; notranslate">
var pageTracker=_gat._getTracker('UA-XXXXXX-X');
pageTracker._initData();
pageTracker._trackPageview();
</pre><p>While you are updating your code, you might also want to <a
href="http://developer.yahoo.net/blog/archives/2007/07/high_performanc_5.html">consider moving this and any other javascript</a> to the bottom of your web site for improved performance.</p> <script type="text/javascript">sdac_post_slideshows.push({fx: 'fade', timeout: 0, speed: 1000, pause: 0,})</script>]]></content:encoded> <wfw:commentRss>http://www.sandboxdev.com/2008/01/18/upgrade-google-analytic-tracker-code/feed/</wfw:commentRss> <slash:comments>0</slash:comments> </item> <item><title>Terms of Use Javascript</title><link>http://www.sandboxdev.com/2007/01/31/terms-of-use-javascript/</link> <comments>http://www.sandboxdev.com/2007/01/31/terms-of-use-javascript/#comments</comments> <pubDate>Wed, 31 Jan 2007 23:37:55 +0000</pubDate> <dc:creator>Jennifer Zelazny</dc:creator> <category><![CDATA[HOWTOs]]></category> <category><![CDATA[Javascript]]></category> <category><![CDATA[SDAC Blog]]></category> <guid
isPermaLink="false">http://www.sandboxdev.com/blog/2007/01/31/terms-of-use-javascript.php</guid> <description><![CDATA[Need: A script that a client could easily call within a URL to force the users to agree to their terms of use before downloading a file. Solution:Either put the following code in the header, or in a .js file to include: Then, call this code in your HTML code by using:]]></description> <content:encoded><![CDATA[<p><strong>Need:</strong> A script that a client could easily call within a URL to force the users to agree to their terms of use before downloading a file.<br
/> <br
/> <strong>Solution:</strong>Either put the following code in the header, or in a .js file to include:<br
/> <code><pre class="brush: jscript; title: Custom Code; notranslate">
function terms(){
	question = confirm(&quot;Terms of Use text here&quot;)
 if (question !=&quot;0&quot;){
		document.URL()
	}
  }
</pre><p></code></p><p>Then, call this code in your HTML code by using:<br
/> <code><pre class="brush: xml; title: Custom Code; notranslate">
&lt;a href=&quot;http://www.sandboxdev.com&quot; /&gt;Download Link&lt;/a&gt;
</pre><p></code></p> <script type="text/javascript">sdac_post_slideshows.push({fx: 'fade', timeout: 0, speed: 1000, pause: 0,})</script>]]></content:encoded> <wfw:commentRss>http://www.sandboxdev.com/2007/01/31/terms-of-use-javascript/feed/</wfw:commentRss> <slash:comments>2</slash:comments> </item> </channel> </rss>
