<?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/"
	xmlns:series="http://unfoldingneurons.com/"
		>
<channel>
	<title>Comments on: Add javascript function using css class</title>
	<atom:link href="http://www.digimantra.com/tutorials/add-javascript-function-using-css-class/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.digimantra.com/tutorials/add-javascript-function-using-css-class/</link>
	<description>Technology tips for all</description>
	<lastBuildDate>Sun, 13 Nov 2011 09:56:09 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
<xhtml:meta xmlns:xhtml="http://www.w3.org/1999/xhtml" name="robots" content="noindex" />
	<item>
		<title>By: Sachin Khosla</title>
		<link>http://www.digimantra.com/tutorials/add-javascript-function-using-css-class/#comment-152132</link>
		<dc:creator>Sachin Khosla</dc:creator>
		<pubDate>Mon, 30 May 2011 04:00:38 +0000</pubDate>
		<guid isPermaLink="false">http://realin.co.in/?p=248#comment-152132</guid>
		<description>Hi Dulshan, 

You can send the complete HTML file containing JS and HTML code to me. I can help you out. You will get the email address from about page.

Thanks
Sachin</description>
		<content:encoded><![CDATA[<p>Hi Dulshan, </p>
<p>You can send the complete HTML file containing JS and HTML code to me. I can help you out. You will get the email address from about page.</p>
<p>Thanks<br />
Sachin</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Dulshan</title>
		<link>http://www.digimantra.com/tutorials/add-javascript-function-using-css-class/#comment-152107</link>
		<dc:creator>Dulshan</dc:creator>
		<pubDate>Mon, 30 May 2011 02:29:55 +0000</pubDate>
		<guid isPermaLink="false">http://realin.co.in/?p=248#comment-152107</guid>
		<description>Hi, I have a simple rollover button with css class:





and I need to add js code to mouseover. Javascript code is:


function mouseOver()
{ document.photo.src=&quot;images/mouse_rollovers_in_the_main_page/history_mouseover.png&quot; }

function mouseOut()
{ document.photo.src=&quot;images/mouse_rollovers_in_the_main_page/mouseout.png&quot; }


It works when the css class is not there as normal html:

&lt;a href=&quot;http://www.w3schools.com&quot; rel=&quot;nofollow&quot;&gt;
   
  &lt;/a&gt;

but I want to use css classes as well because my images are positioned with them. Please help.</description>
		<content:encoded><![CDATA[<p>Hi, I have a simple rollover button with css class:</p>
<p>and I need to add js code to mouseover. Javascript code is:</p>
<p>function mouseOver()<br />
{ document.photo.src=&#8221;images/mouse_rollovers_in_the_main_page/history_mouseover.png&#8221; }</p>
<p>function mouseOut()<br />
{ document.photo.src=&#8221;images/mouse_rollovers_in_the_main_page/mouseout.png&#8221; }</p>
<p>It works when the css class is not there as normal html:</p>
<p><a href="http://www.w3schools.com" rel="nofollow"></p>
<p>  </a></p>
<p>but I want to use css classes as well because my images are positioned with them. Please help.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Paul Tessier</title>
		<link>http://www.digimantra.com/tutorials/add-javascript-function-using-css-class/#comment-83579</link>
		<dc:creator>Paul Tessier</dc:creator>
		<pubDate>Sun, 16 Jan 2011 03:32:20 +0000</pubDate>
		<guid isPermaLink="false">http://realin.co.in/?p=248#comment-83579</guid>
		<description>What I don&#039;t see in your example is a description of how the hookFunc function is called in response to the mouse pointer hovering over the link.  Am I missing something obvious?</description>
		<content:encoded><![CDATA[<p>What I don&#8217;t see in your example is a description of how the hookFunc function is called in response to the mouse pointer hovering over the link.  Am I missing something obvious?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Sachin Khosla</title>
		<link>http://www.digimantra.com/tutorials/add-javascript-function-using-css-class/#comment-8758</link>
		<dc:creator>Sachin Khosla</dc:creator>
		<pubDate>Thu, 22 Oct 2009 04:17:11 +0000</pubDate>
		<guid isPermaLink="false">http://realin.co.in/?p=248#comment-8758</guid>
		<description>Glad that the posts are helping you guys.</description>
		<content:encoded><![CDATA[<p>Glad that the posts are helping you guys.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Chethan</title>
		<link>http://www.digimantra.com/tutorials/add-javascript-function-using-css-class/#comment-8669</link>
		<dc:creator>Chethan</dc:creator>
		<pubDate>Tue, 20 Oct 2009 14:00:09 +0000</pubDate>
		<guid isPermaLink="false">http://realin.co.in/?p=248#comment-8669</guid>
		<description>I am a Student! and we have a subject Programming the web&quot; this tutorial as well as the whole category &quot;Javascript&quot; &quot;PHP&quot; is very handy</description>
		<content:encoded><![CDATA[<p>I am a Student! and we have a subject Programming the web&#8221; this tutorial as well as the whole category &#8220;Javascript&#8221; &#8220;PHP&#8221; is very handy</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Sincere</title>
		<link>http://www.digimantra.com/tutorials/add-javascript-function-using-css-class/#comment-7913</link>
		<dc:creator>Sincere</dc:creator>
		<pubDate>Wed, 07 Oct 2009 00:45:19 +0000</pubDate>
		<guid isPermaLink="false">http://realin.co.in/?p=248#comment-7913</guid>
		<description>good stuff! i have a question though, what if i want to give a script im using a class, how would i do so? 

for ex: im running a random image script, the images are  called in the JS file, so i cant give them a specific class using css can i?

the JS code thats in the body of the html simply just calls the function, ...this has been bugging me...can you help?</description>
		<content:encoded><![CDATA[<p>good stuff! i have a question though, what if i want to give a script im using a class, how would i do so? </p>
<p>for ex: im running a random image script, the images are  called in the JS file, so i cant give them a specific class using css can i?</p>
<p>the JS code thats in the body of the html simply just calls the function, &#8230;this has been bugging me&#8230;can you help?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Sachin Khosla</title>
		<link>http://www.digimantra.com/tutorials/add-javascript-function-using-css-class/#comment-1509</link>
		<dc:creator>Sachin Khosla</dc:creator>
		<pubDate>Sun, 07 Jun 2009 07:12:15 +0000</pubDate>
		<guid isPermaLink="false">http://realin.co.in/?p=248#comment-1509</guid>
		<description>Well nothing is impossible, probably there is a way to do it if you can hack background:url(javascript:alert()) thing ... Give it a shot..</description>
		<content:encoded><![CDATA[<p>Well nothing is impossible, probably there is a way to do it if you can hack background:url(javascript:alert()) thing &#8230; Give it a shot..</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Semakula</title>
		<link>http://www.digimantra.com/tutorials/add-javascript-function-using-css-class/#comment-1508</link>
		<dc:creator>Semakula</dc:creator>
		<pubDate>Sun, 07 Jun 2009 06:25:52 +0000</pubDate>
		<guid isPermaLink="false">http://realin.co.in/?p=248#comment-1508</guid>
		<description>Actually I am using a WYSIWYG editor (tinyMCE) and apparently it comments out the javascript and displays the js code in the frontend.

so am trying to find a work around this and am hoping the above approach will do it.

Thanx</description>
		<content:encoded><![CDATA[<p>Actually I am using a WYSIWYG editor (tinyMCE) and apparently it comments out the javascript and displays the js code in the frontend.</p>
<p>so am trying to find a work around this and am hoping the above approach will do it.</p>
<p>Thanx</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Semakula</title>
		<link>http://www.digimantra.com/tutorials/add-javascript-function-using-css-class/#comment-1506</link>
		<dc:creator>Semakula</dc:creator>
		<pubDate>Sun, 07 Jun 2009 06:17:29 +0000</pubDate>
		<guid isPermaLink="false">http://realin.co.in/?p=248#comment-1506</guid>
		<description>Thanx guys,

I think i wasn`t clear what i wanted.. here now.

i have a 
      
       var ... ;...
       Book_Image_Sources=new Array(...);
       function carousel() {...} 
     

I want to (i hope it`s possible) call the script above in a css class or id like

     #carouse
        {
        [B]... somehow call the script above[/B]
         }
then in my html code
       

i hope am clearer now. i know its something simple but just can`t make out how.
Thanx</description>
		<content:encoded><![CDATA[<p>Thanx guys,</p>
<p>I think i wasn`t clear what i wanted.. here now.</p>
<p>i have a </p>
<p>       var &#8230; ;&#8230;<br />
       Book_Image_Sources=new Array(&#8230;);<br />
       function carousel() {&#8230;} </p>
<p>I want to (i hope it`s possible) call the script above in a css class or id like</p>
<p>     #carouse<br />
        {<br />
        [B]&#8230; somehow call the script above[/B]<br />
         }<br />
then in my html code</p>
<p>i hope am clearer now. i know its something simple but just can`t make out how.<br />
Thanx</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Sachin Khosla</title>
		<link>http://www.digimantra.com/tutorials/add-javascript-function-using-css-class/#comment-1498</link>
		<dc:creator>Sachin Khosla</dc:creator>
		<pubDate>Sat, 06 Jun 2009 19:29:54 +0000</pubDate>
		<guid isPermaLink="false">http://realin.co.in/?p=248#comment-1498</guid>
		<description>Hey Semakula Abdul, 

Thanks for dropping in .. I was unable to understand what you want to do in the above query, but still I will try to answer. 

1) The above example only searches for a particular class and hooks an anonymous  function to that very element, you can call your function from inside that function.

2) Simply calling a javascript function is also achievable in the following way. 

&lt;a href=&quot;&quot; onclick=&quot;my_javascript_function();&quot; rel=&quot;nofollow&quot;&gt; Click here to move the carousel &lt;/a&gt; 

Let me know if that helped you or it would be great if you can clarify your question 

Cheers!!</description>
		<content:encoded><![CDATA[<p>Hey Semakula Abdul, </p>
<p>Thanks for dropping in .. I was unable to understand what you want to do in the above query, but still I will try to answer. </p>
<p>1) The above example only searches for a particular class and hooks an anonymous  function to that very element, you can call your function from inside that function.</p>
<p>2) Simply calling a javascript function is also achievable in the following way. </p>
<p>&lt;a href=&#8221;" onclick=&#8221;my_javascript_function();&#8221; rel=&#8221;nofollow&#8221;> Click here to move the carousel &lt;/a&gt; </p>
<p>Let me know if that helped you or it would be great if you can clarify your question </p>
<p>Cheers!!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Semakula Abdul</title>
		<link>http://www.digimantra.com/tutorials/add-javascript-function-using-css-class/#comment-1497</link>
		<dc:creator>Semakula Abdul</dc:creator>
		<pubDate>Sat, 06 Jun 2009 19:15:03 +0000</pubDate>
		<guid isPermaLink="false">http://realin.co.in/?p=248#comment-1497</guid>
		<description>Hullo Sachin,

thanx for the good work of making us know these things.

I however wanted to know how i can define or call a javascript function from a css class or id. 

I basically want to display a javascript carousel image rotator and i have the function but don`t know how i can call it using a css class that i can later reference in an html  tag.
Thanx in advance..</description>
		<content:encoded><![CDATA[<p>Hullo Sachin,</p>
<p>thanx for the good work of making us know these things.</p>
<p>I however wanted to know how i can define or call a javascript function from a css class or id. </p>
<p>I basically want to display a javascript carousel image rotator and i have the function but don`t know how i can call it using a css class that i can later reference in an html  tag.<br />
Thanx in advance..</p>
]]></content:encoded>
	</item>
</channel>
</rss>

