<?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: toggle checkboxes javascript using prototype</title>
	<atom:link href="http://www.accessdataservices.com/blog/toggle-checkboxes-javascript-using-prototype/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.accessdataservices.com/blog/toggle-checkboxes-javascript-using-prototype/</link>
	<description>Linux, Freedom, and More</description>
	<lastBuildDate>Mon, 16 Jan 2012 22:37:54 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
	<item>
		<title>By: gare</title>
		<link>http://www.accessdataservices.com/blog/toggle-checkboxes-javascript-using-prototype/comment-page-1/#comment-53872</link>
		<dc:creator>gare</dc:creator>
		<pubDate>Mon, 23 May 2011 15:47:33 +0000</pubDate>
		<guid isPermaLink="false">http://www.accessdataservices.com/blog/toggle-checkboxes-javascript-using-prototype/#comment-53872</guid>
		<description>Hello Tim -

Have updated this blog entry to reflect your suggested change.  

Thanks.
Gare</description>
		<content:encoded><![CDATA[<p>Hello Tim -</p>
<p>Have updated this blog entry to reflect your suggested change.  </p>
<p>Thanks.<br />
Gare</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: gare</title>
		<link>http://www.accessdataservices.com/blog/toggle-checkboxes-javascript-using-prototype/comment-page-1/#comment-51772</link>
		<dc:creator>gare</dc:creator>
		<pubDate>Sat, 19 Mar 2011 11:09:38 +0000</pubDate>
		<guid isPermaLink="false">http://www.accessdataservices.com/blog/toggle-checkboxes-javascript-using-prototype/#comment-51772</guid>
		<description>Thank you for the updates and the post.  I hope to update this page in the near future with more information about prototype, and to clarify this code.</description>
		<content:encoded><![CDATA[<p>Thank you for the updates and the post.  I hope to update this page in the near future with more information about prototype, and to clarify this code.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Tim McNamara</title>
		<link>http://www.accessdataservices.com/blog/toggle-checkboxes-javascript-using-prototype/comment-page-1/#comment-50060</link>
		<dc:creator>Tim McNamara</dc:creator>
		<pubDate>Tue, 25 Jan 2011 22:23:01 +0000</pubDate>
		<guid isPermaLink="false">http://www.accessdataservices.com/blog/toggle-checkboxes-javascript-using-prototype/#comment-50060</guid>
		<description>Update. Checkboxes have a &lt;code&gt;click&lt;/code&gt; method. This makes life even easier:

&lt;code&gt;function(checkBox){
  checkBox.click();
}
&lt;/code&gt;</description>
		<content:encoded><![CDATA[<p>Update. Checkboxes have a <code>click</code> method. This makes life even easier:</p>
<p><code>function(checkBox){<br />
  checkBox.click();<br />
}<br />
</code></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Tim McNamara</title>
		<link>http://www.accessdataservices.com/blog/toggle-checkboxes-javascript-using-prototype/comment-page-1/#comment-50059</link>
		<dc:creator>Tim McNamara</dc:creator>
		<pubDate>Tue, 25 Jan 2011 22:20:10 +0000</pubDate>
		<guid isPermaLink="false">http://www.accessdataservices.com/blog/toggle-checkboxes-javascript-using-prototype/#comment-50059</guid>
		<description>Just a tip, you&#039;re adding some unnecessary conditionals to your anonymous function:

If you have the element already, then you could do this to make things faster.

&lt;code&gt;function(checkBox){
	checkBox.checked = !checkBox.checked
}
&lt;/code&gt;

However, this can be extended. If you have the &lt;code&gt;id&lt;/code&gt; of a checkbox, you can use something that will get the checkbox for you.

&lt;code&gt;function(elem_id){
	$(elem_id).checked = !$(elem_id).checked
}&lt;/code&gt;</description>
		<content:encoded><![CDATA[<p>Just a tip, you&#8217;re adding some unnecessary conditionals to your anonymous function:</p>
<p>If you have the element already, then you could do this to make things faster.</p>
<p><code>function(checkBox){<br />
	checkBox.checked = !checkBox.checked<br />
}<br />
</code></p>
<p>However, this can be extended. If you have the <code>id</code> of a checkbox, you can use something that will get the checkbox for you.</p>
<p><code>function(elem_id){<br />
	$(elem_id).checked = !$(elem_id).checked<br />
}</code></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: tuba</title>
		<link>http://www.accessdataservices.com/blog/toggle-checkboxes-javascript-using-prototype/comment-page-1/#comment-47251</link>
		<dc:creator>tuba</dc:creator>
		<pubDate>Sun, 17 Oct 2010 17:31:57 +0000</pubDate>
		<guid isPermaLink="false">http://www.accessdataservices.com/blog/toggle-checkboxes-javascript-using-prototype/#comment-47251</guid>
		<description>very nice, thanks!</description>
		<content:encoded><![CDATA[<p>very nice, thanks!</p>
]]></content:encoded>
	</item>
</channel>
</rss>

