<?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: observe_field (watch check_box_tag so select_tag can be disabled on click)</title>
	<atom:link href="http://railstrip.ourgreatjourney.com/observe_field-watch-check_box_tag-so-select_tag-can-be-disabled-on-click/feed/" rel="self" type="application/rss+xml" />
	<link>http://railstrip.ourgreatjourney.com/observe_field-watch-check_box_tag-so-select_tag-can-be-disabled-on-click/</link>
	<description>My Ruby trip on Rails</description>
	<pubDate>Tue, 07 Sep 2010 02:50:56 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.7.1</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: Codelucky</title>
		<link>http://railstrip.ourgreatjourney.com/observe_field-watch-check_box_tag-so-select_tag-can-be-disabled-on-click/comment-page-1/#comment-11</link>
		<dc:creator>Codelucky</dc:creator>
		<pubDate>Wed, 16 Dec 2009 11:19:17 +0000</pubDate>
		<guid isPermaLink="false">http://railstrip.ourgreatjourney.com/?p=50#comment-11</guid>
		<description>I love the internet.

I had the exact same problem and wasn't very used to javascript.

Thanks for this post.
After two days of trying, this made my day.

However my solution is a little different.

In the check_box_tag I passed the checkbox to the function in the onchange handler like this.

:onchange =&gt; doChange(this)

and reffered to the select_tag in javascript like this.

function doChange(element){
element.form.select_player.disabled = element.checked
}</description>
		<content:encoded><![CDATA[<p>I love the internet.</p>
<p>I had the exact same problem and wasn&#8217;t very used to javascript.</p>
<p>Thanks for this post.<br />
After two days of trying, this made my day.</p>
<p>However my solution is a little different.</p>
<p>In the check_box_tag I passed the checkbox to the function in the onchange handler like this.</p>
<p>:onchange =&gt; doChange(this)</p>
<p>and reffered to the select_tag in javascript like this.</p>
<p>function doChange(element){<br />
element.form.select_player.disabled = element.checked<br />
}</p>
]]></content:encoded>
	</item>
</channel>
</rss>
