Click here to Skip to main content
11,433,997 members (56,543 online)
Rate this: bad
good
Please Sign up or sign in to vote.
See more: ASP.NET Javascript CSS
I call that function in anchor tag mouseover event. I hide the div when the mouse is over on the anchor tag.

the function is called. The function is running without error. But the div is not hide.

I give the coding is
<a href="#"  önmouseover="projectsclick();" title="Projects"><span   class="icon_block m_projects">Projects </span></a>


  function projectsclick() {
         var id = document.getElementById("<%=divprojects.ClientID%>");
         id.style = "display:none";
     }


My div is
  <div id="divprojects"  runat="server"  class="switch_bar">
		 <ul>
			 
			 <li><a href="#"><span class="stats_icon administrative_docs_sl"></span><span class="label">Profile </span></a></li>
			 <li><a href="#"><span class="stats_icon finished_work_sl"><span class="alert_notify blue">30 </span></span><span class="label">Take Test </span></a></li>
			 <li><a href="#"><span class="stats_icon config_sl"></span><span class="label">Test History </span></a></li>
			 <li><a href="#"><span class="stats_icon archives_sl"></span><span class="label">Credits </span></a></li>
 
			 
		 </ul>
         
	 </div>
Anybody help me...
Posted 29-Jan-13 21:20pm
devausha1.4K
Edited 29-Jan-13 21:25pm
v4
Comments
boogac at 30-Jan-13 11:13am
   
there is a mistake 'ö'nmouseover ??
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 1

try this

id.style.Display='none';
  Permalink  
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 2

Hi,

Try like the following:

function projectsclick() {
            document.getElementById("<%=divprojects.ClientID%>").css("display","none");
        }


Thanks
  Permalink  
Comments
AshishChaudha at 30-Jan-13 4:16am
   
my 5+

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



Advertise | Privacy | Mobile
Web02 | 2.8.150428.2 | Last Updated 30 Jan 2013
Copyright © CodeProject, 1999-2015
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100