<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0">
  <channel>
    <title>Comments on snippet: 'jQuery.replaceClass();'</title>
    <description>Snipplr comments feed</description>
    <link>https://ipv6.snipplr.com/</link>
    <lastBuildDate>Wed, 15 Apr 2026 02:27:07 +0000</lastBuildDate>
    <item>
      <title>joe-bbb said on 28/Sep/2009</title>
      <link>https://ipv6.snipplr.com/view/19267/jqueryreplaceclass</link>
      <description>&lt;p&gt;Thats nice, however shouldn't that be a colon not an equals? e.g.&#13;
&#13;
//jQuery extension object&#13;
jQuery.extend(jQuery.fn,{&#13;
	replaceClass : function(toReplace,replaceWith){&#13;
	 return $(this).each(function(){&#13;
		return $(this).removeClass(toReplace).addClass(replaceWith);&#13;
	 });&#13;
	}&#13;
})&#13;
&#13;
//call&#13;
$('#first-col').click(function(){&#13;
	$(this).replaceClass('person','dog');&#13;
});&lt;/p&gt;</description>
      <pubDate>Mon, 28 Sep 2009 10:57:40 UTC</pubDate>
      <guid>https://ipv6.snipplr.com/view/19267/jqueryreplaceclass</guid>
    </item>
  </channel>
</rss>
