<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	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/"
		>
<channel>
	<title>Comments on: JQuery &#8211; Run script if!</title>
	<atom:link href="http://eligeske.com/jquery/jquery-run-script-if/feed/" rel="self" type="application/rss+xml" />
	<link>http://eligeske.com/jquery/jquery-run-script-if/</link>
	<description>Good information for the geeky kind.</description>
	<lastBuildDate>Sat, 12 May 2012 15:26:17 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
	<item>
		<title>By: Simon Ferragne</title>
		<link>http://eligeske.com/jquery/jquery-run-script-if/#comment-204</link>
		<dc:creator>Simon Ferragne</dc:creator>
		<pubDate>Wed, 31 Aug 2011 03:47:08 +0000</pubDate>
		<guid isPermaLink="false">http://eligeske.com/?p=120#comment-204</guid>
		<description>jQuery comes with a size() function. In javascript the number  0 = false so you can drop the &gt;0.  

if (  $(&#039;#el&#039;).size()  ){
//code 
}

// To run script if element dont exists 
if( ! $(&#039;#el&#039;).size() ){
// code
}

But jQuery intern mechanism already implement this so you can avoid the if(){}  if it is simple function like: 
 $(&#039;#dontExistsElement&#039;).slideUp();</description>
		<content:encoded><![CDATA[<p>jQuery comes with a size() function. In javascript the number  0 = false so you can drop the &gt;0.  </p>
<p>if (  $(&#8216;#el&#8217;).size()  ){<br />
//code<br />
}</p>
<p>// To run script if element dont exists<br />
if( ! $(&#8216;#el&#8217;).size() ){<br />
// code<br />
}</p>
<p>But jQuery intern mechanism already implement this so you can avoid the if(){}  if it is simple function like:<br />
 $(&#8216;#dontExistsElement&#8217;).slideUp();</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: davide</title>
		<link>http://eligeske.com/jquery/jquery-run-script-if/#comment-97</link>
		<dc:creator>davide</dc:creator>
		<pubDate>Fri, 27 May 2011 04:56:15 +0000</pubDate>
		<guid isPermaLink="false">http://eligeske.com/?p=120#comment-97</guid>
		<description>I liked your post. Cheers</description>
		<content:encoded><![CDATA[<p>I liked your post. Cheers</p>
]]></content:encoded>
	</item>
</channel>
</rss>

