<?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: Changing Form Input Styles on Focus with jQuery</title>
	<atom:link href="http://buildinternet.com/2009/01/changing-form-input-styles-on-focus-with-jquery/feed/" rel="self" type="application/rss+xml" />
	<link>http://buildinternet.com/2009/01/changing-form-input-styles-on-focus-with-jquery/</link>
	<description>Web Design, Development, and Business</description>
	<lastBuildDate>Wed, 08 Feb 2012 22:59:13 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
	<item>
		<title>By: 55 jQuery Form Plugins To Download And Use &#124; Ning Ma blog</title>
		<link>http://buildinternet.com/2009/01/changing-form-input-styles-on-focus-with-jquery/comment-page-1/#comment-32927</link>
		<dc:creator>55 jQuery Form Plugins To Download And Use &#124; Ning Ma blog</dc:creator>
		<pubDate>Wed, 08 Feb 2012 17:22:23 +0000</pubDate>
		<guid isPermaLink="false">http://buildinternet.com/?p=1150#comment-32927</guid>
		<description>[...] Changing Form Input Styles on Focus with jQuery [...]</description>
		<content:encoded><![CDATA[<p>[...] Changing Form Input Styles on Focus with jQuery [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: krish</title>
		<link>http://buildinternet.com/2009/01/changing-form-input-styles-on-focus-with-jquery/comment-page-1/#comment-32894</link>
		<dc:creator>krish</dc:creator>
		<pubDate>Tue, 07 Feb 2012 07:27:41 +0000</pubDate>
		<guid isPermaLink="false">http://buildinternet.com/?p=1150#comment-32894</guid>
		<description>HI,
   
     Like the text-area i would like to add this for password how achieve it?</description>
		<content:encoded><![CDATA[<p>HI,</p>
<p>     Like the text-area i would like to add this for password how achieve it?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Shaun</title>
		<link>http://buildinternet.com/2009/01/changing-form-input-styles-on-focus-with-jquery/comment-page-1/#comment-32886</link>
		<dc:creator>Shaun</dc:creator>
		<pubDate>Mon, 06 Feb 2012 18:45:47 +0000</pubDate>
		<guid isPermaLink="false">http://buildinternet.com/?p=1150#comment-32886</guid>
		<description>Hi There,

Thank you for the code. I&#039;m have one little problem making it work with &#039;textarea&#039; I can get it to work but the textarea won&#039;t recognize rows? Can you help please



	Build Internet! &#124; Changing Form Input Styles on Focus with JQuery
	
	
		$(document).ready(function() {
			$(&#039;input[type=&quot;text&quot;],textarea&#039;).addClass(&quot;idleField&quot;);
       		$(&#039;input[type=&quot;text&quot;],textarea&#039;).focus(function() {
       			$(this).removeClass(&quot;idleField&quot;).addClass(&quot;focusField&quot;);
    		    if (this.value == this.defaultValue){ 
    		    	this.value = &#039;&#039;;
				}
				if(this.value != this.defaultValue){
	    			this.select();
	    		}
    		});
    		$(&#039;input[type=&quot;text&quot;],textarea&#039;).blur(function() {
    			$(this).removeClass(&quot;focusField&quot;).addClass(&quot;idleField&quot;);
    		    if ($.trim(this.value) == &#039;&#039;){
			    	this.value = (this.defaultValue ? this.defaultValue : &#039;&#039;);
				}
    		});
		});			
	

    *{
    	margin:0;
    	padding:0;
    	font:bold 12px &quot;Lucida Grande&quot;, Arial, sans-serif;
    }
    body {
    	padding: 10px;
    }
    h1{
    	font-size:14px;
    }
    #status{
    	width:50%;
    	padding:10px;
    	height:42px;
    	outline:none;
    }
    .focusField{
    	border:solid 2px #73A6FF;
    	background:#EFF5FF;
    	color:#000;
    }
    .idleField{
    	background:#EEE;
    	color: #6F6F6F;
		border: solid 2px #DFDFDF;
    }		




	Changing Form Input Styles on Focus with JQuery
	
	 
		 
		
		 
		
	
	

</description>
		<content:encoded><![CDATA[<p>Hi There,</p>
<p>Thank you for the code. I&#8217;m have one little problem making it work with &#8216;textarea&#8217; I can get it to work but the textarea won&#8217;t recognize rows? Can you help please</p>
<p>	Build Internet! | Changing Form Input Styles on Focus with JQuery</p>
<p>		$(document).ready(function() {<br />
			$(&#8216;input[type="text"],textarea&#8217;).addClass(&#8220;idleField&#8221;);<br />
       		$(&#8216;input[type="text"],textarea&#8217;).focus(function() {<br />
       			$(this).removeClass(&#8220;idleField&#8221;).addClass(&#8220;focusField&#8221;);<br />
    		    if (this.value == this.defaultValue){<br />
    		    	this.value = &#8221;;<br />
				}<br />
				if(this.value != this.defaultValue){<br />
	    			this.select();<br />
	    		}<br />
    		});<br />
    		$(&#8216;input[type="text"],textarea&#8217;).blur(function() {<br />
    			$(this).removeClass(&#8220;focusField&#8221;).addClass(&#8220;idleField&#8221;);<br />
    		    if ($.trim(this.value) == &#8221;){<br />
			    	this.value = (this.defaultValue ? this.defaultValue : &#8221;);<br />
				}<br />
    		});<br />
		});			</p>
<p>    *{<br />
    	margin:0;<br />
    	padding:0;<br />
    	font:bold 12px &#8220;Lucida Grande&#8221;, Arial, sans-serif;<br />
    }<br />
    body {<br />
    	padding: 10px;<br />
    }<br />
    h1{<br />
    	font-size:14px;<br />
    }<br />
    #status{<br />
    	width:50%;<br />
    	padding:10px;<br />
    	height:42px;<br />
    	outline:none;<br />
    }<br />
    .focusField{<br />
    	border:solid 2px #73A6FF;<br />
    	background:#EFF5FF;<br />
    	color:#000;<br />
    }<br />
    .idleField{<br />
    	background:#EEE;<br />
    	color: #6F6F6F;<br />
		border: solid 2px #DFDFDF;<br />
    }		</p>
<p>	Changing Form Input Styles on Focus with JQuery</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: 40 Jquery Form Tutorials &#38; Plugins &#124; My Blog</title>
		<link>http://buildinternet.com/2009/01/changing-form-input-styles-on-focus-with-jquery/comment-page-1/#comment-32806</link>
		<dc:creator>40 Jquery Form Tutorials &#38; Plugins &#124; My Blog</dc:creator>
		<pubDate>Thu, 26 Jan 2012 00:57:49 +0000</pubDate>
		<guid isPermaLink="false">http://buildinternet.com/?p=1150#comment-32806</guid>
		<description>[...] Changing Form Input Styles on Focus with jQuery [...]</description>
		<content:encoded><![CDATA[<p>[...] Changing Form Input Styles on Focus with jQuery [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: 40 Jquery Form Tutorials &#38; Plugins &#124; WEBGRAPHIC</title>
		<link>http://buildinternet.com/2009/01/changing-form-input-styles-on-focus-with-jquery/comment-page-1/#comment-32800</link>
		<dc:creator>40 Jquery Form Tutorials &#38; Plugins &#124; WEBGRAPHIC</dc:creator>
		<pubDate>Wed, 25 Jan 2012 14:58:09 +0000</pubDate>
		<guid isPermaLink="false">http://buildinternet.com/?p=1150#comment-32800</guid>
		<description>[...] Changing Form Input Styles on Focus with jQuery [...]</description>
		<content:encoded><![CDATA[<p>[...] Changing Form Input Styles on Focus with jQuery [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: earthdesigner</title>
		<link>http://buildinternet.com/2009/01/changing-form-input-styles-on-focus-with-jquery/comment-page-1/#comment-32639</link>
		<dc:creator>earthdesigner</dc:creator>
		<pubDate>Sat, 07 Jan 2012 13:41:46 +0000</pubDate>
		<guid isPermaLink="false">http://buildinternet.com/?p=1150#comment-32639</guid>
		<description>I was thinking that simplified version would be to create just a css class &quot;focus&quot; then all the javascript will resume to:

$(&#039;input[type=text], textarea&#039;).focus(function(){ $(this).addClass(&#039;focus&#039;) }).blur(function(){ $(this).removeClass(&#039;focus&#039;)});

Good article anyway ;)</description>
		<content:encoded><![CDATA[<p>I was thinking that simplified version would be to create just a css class &#8220;focus&#8221; then all the javascript will resume to:</p>
<p>$(&#8216;input[type=text], textarea&#8217;).focus(function(){ $(this).addClass(&#8216;focus&#8217;) }).blur(function(){ $(this).removeClass(&#8216;focus&#8217;)});</p>
<p>Good article anyway ;)</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Bohry</title>
		<link>http://buildinternet.com/2009/01/changing-form-input-styles-on-focus-with-jquery/comment-page-1/#comment-32629</link>
		<dc:creator>Bohry</dc:creator>
		<pubDate>Fri, 06 Jan 2012 18:52:35 +0000</pubDate>
		<guid isPermaLink="false">http://buildinternet.com/?p=1150#comment-32629</guid>
		<description>Very nice! I make a little change to able this effect to textarea´s too. Danke!!!!</description>
		<content:encoded><![CDATA[<p>Very nice! I make a little change to able this effect to textarea´s too. Danke!!!!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: tes</title>
		<link>http://buildinternet.com/2009/01/changing-form-input-styles-on-focus-with-jquery/comment-page-1/#comment-32207</link>
		<dc:creator>tes</dc:creator>
		<pubDate>Thu, 01 Dec 2011 02:41:04 +0000</pubDate>
		<guid isPermaLink="false">http://buildinternet.com/?p=1150#comment-32207</guid>
		<description>can you please update this, its not working with jq 1.7.1, when you focus out the field, it reset to default value used at start.</description>
		<content:encoded><![CDATA[<p>can you please update this, its not working with jq 1.7.1, when you focus out the field, it reset to default value used at start.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Awesome css form and validations using jquery &#124; ExceptionHandle.com</title>
		<link>http://buildinternet.com/2009/01/changing-form-input-styles-on-focus-with-jquery/comment-page-1/#comment-32168</link>
		<dc:creator>Awesome css form and validations using jquery &#124; ExceptionHandle.com</dc:creator>
		<pubDate>Sun, 27 Nov 2011 17:08:05 +0000</pubDate>
		<guid isPermaLink="false">http://buildinternet.com/?p=1150#comment-32168</guid>
		<description>[...] Changing Form Input Styles on Focus with jQuery [...]</description>
		<content:encoded><![CDATA[<p>[...] Changing Form Input Styles on Focus with jQuery [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: cyberv</title>
		<link>http://buildinternet.com/2009/01/changing-form-input-styles-on-focus-with-jquery/comment-page-1/#comment-31932</link>
		<dc:creator>cyberv</dc:creator>
		<pubDate>Mon, 07 Nov 2011 19:02:40 +0000</pubDate>
		<guid isPermaLink="false">http://buildinternet.com/?p=1150#comment-31932</guid>
		<description>add something like this in your style 
 #password{  
        width:400px;  
        padding:5px;  
        outline:none;  
        height:20px;
		font-weight:bold;  
    }  

and add this in the script

// password boxes
				    $(document).ready(function() {  
        $(&#039;input[type=&quot;password&quot;]&#039;).addClass(&quot;idleField&quot;);  
        $(&#039;input[type=&quot;password&quot;]&#039;).focus(function() {  
            $(this).removeClass(&quot;idleField&quot;).addClass(&quot;focusField&quot;);  
            if (this.value == this.defaultValue){  
                this.value = &#039;&#039;;  
            }  
            if(this.value != this.defaultValue){  
                this.select();  
            }  
        });  
        $(&#039;input[type=&quot;text&quot;]&#039;).blur(function() {  
            $(this).removeClass(&quot;focusField&quot;).addClass(&quot;idleField&quot;);  
            if ($.trim(this.value == &#039;&#039;)){  
                this.value = (this.defaultValue ? this.defaultValue : &#039;&#039;);  
            }  
        });  
    });</description>
		<content:encoded><![CDATA[<p>add something like this in your style<br />
 #password{<br />
        width:400px;<br />
        padding:5px;<br />
        outline:none;<br />
        height:20px;<br />
		font-weight:bold;<br />
    }  </p>
<p>and add this in the script</p>
<p>// password boxes<br />
				    $(document).ready(function() {<br />
        $(&#8216;input[type="password"]&#8216;).addClass(&#8220;idleField&#8221;);<br />
        $(&#8216;input[type="password"]&#8216;).focus(function() {<br />
            $(this).removeClass(&#8220;idleField&#8221;).addClass(&#8220;focusField&#8221;);<br />
            if (this.value == this.defaultValue){<br />
                this.value = &#8221;;<br />
            }<br />
            if(this.value != this.defaultValue){<br />
                this.select();<br />
            }<br />
        });<br />
        $(&#8216;input[type="text"]&#8216;).blur(function() {<br />
            $(this).removeClass(&#8220;focusField&#8221;).addClass(&#8220;idleField&#8221;);<br />
            if ($.trim(this.value == &#8221;)){<br />
                this.value = (this.defaultValue ? this.defaultValue : &#8221;);<br />
            }<br />
        });<br />
    });</p>
]]></content:encoded>
	</item>
</channel>
</rss>

<!-- Performance optimized by W3 Total Cache. Learn more: http://www.w3-edge.com/wordpress-plugins/

Minified using disk: basic
Page Caching using disk: enhanced
Database Caching using memcached
Object Caching 367/369 objects using disk: basic

Served from: buildinternet.com @ 2012-02-08 21:25:09 -->
