<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=iso-8859-1">
<STYLE>P {
        PADDING-RIGHT: 0px; PADDING-LEFT: 0px; PADDING-BOTTOM: 0px; MARGIN: 0px; PADDING-TOP: 0px
}
BODY {
        FONT-SIZE: 10pt; FONT-FAMILY: Tahoma
}
</STYLE>

<META content="MSHTML 6.00.2900.3086" name=GENERATOR></HEAD>
<BODY bgColor=#ffffff>
<DIV><FONT face=Arial>Troy and Others;</FONT></DIV>
<DIV><FONT face=Arial>I sent an earlier reply (which has not appeared)&nbsp;to 
Peter's suggestion -- the same as you comment Troy.&nbsp; They fixed my 
problem.</FONT></DIV>
<DIV><FONT face=Arial>I do not have a onmouseout&nbsp;handler because&nbsp;the 
toggle&nbsp;is used to help a student through a math problem</FONT></DIV>
<DIV><FONT face=Arial>The page comes up with all steps hidden, the student can 
reveal each step as desired and they&nbsp;remain visible so that in the end the 
entire problem solution is revealed.&nbsp; If the student desires, he can then 
hide&nbsp;all the steps (by mousing over each step)</FONT>&nbsp;<FONT 
face=Arial>and try again to solve the problem on his own.</FONT></DIV>
<DIV><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial>Nick, thanks for your explanations.&nbsp; They help me 
understand.</FONT></DIV>
<DIV><FONT face=Arial>In answer to your suggestion to toggle the className 
</FONT></DIV>
<DIV><FONT face=Arial>The page (and other pages) contain many spans with class = 
"hidden_hint" -- there appearance is controlled with CSS which references that 
class.</FONT></DIV>
<DIV><FONT face=Arial>However,&nbsp;a&nbsp;mouseOver should only toggle 
the&nbsp;one particular hint involved -- the one identified by the 
id.</FONT></DIV>
<DIV>&nbsp;</DIV>
<DIV><FONT face=Arial>If this is not clear, you can view the results by going 
to</FONT></DIV>
<DIV><FONT face=Arial><A 
href="http://www.drdelmath.com/meramec_college_algebra/chapter_summaries/college_algebra_summary_chapter_1.html">http://www.drdelmath.com/meramec_college_algebra/chapter_summaries/college_algebra_summary_chapter_1.html</A></FONT></DIV>
<DIV><FONT face=Arial>and click on an "Examples" menu item at the bottom of some 
unit -- the&nbsp;one at the end of&nbsp;Equations: Linear Equations in One 
Variable is where the problem occurred -- but the others also demonstrate what I 
am doing.</FONT>&nbsp;</DIV>
<DIV><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial>Thanks to everyone for the help.</FONT></DIV>
<DIV><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial>Del</FONT></DIV>
<BLOCKQUOTE 
style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
  <DIV style="FONT: 10pt arial">----- Original Message ----- </DIV>
  <DIV 
  style="BACKGROUND: #e4e4e4; FONT: 10pt arial; font-color: black"><B>From:</B> 
  <A title=trojani2000@hotmail.com href="mailto:trojani2000@hotmail.com">Troy 
  III Ajnej</A> </DIV>
  <DIV style="FONT: 10pt arial"><B>To:</B> <A title=javascript@latech.edu 
  href="mailto:javascript@latech.edu">[JavaScript List]</A> </DIV>
  <DIV style="FONT: 10pt arial"><B>Sent:</B> Tuesday, June 05, 2007 8:55 
AM</DIV>
  <DIV style="FONT: 10pt arial"><B>Subject:</B> RE: [Javascript] Trouble with 
  id</DIV>
  <DIV><BR></DIV>Helo Del,<BR>this code works&nbsp;as expected&nbsp;on both, IE 
  and FX (strictmode): <BR>&nbsp;<BR>&lt;a href="#" onMouseOver = 
  toggle_visibility('hint4')&gt;<BR>&lt;img src="../../image/icon_toggle.jpg" 
  width="22" height="22" border="0"&gt;&lt;/a&gt;<BR>&lt;span class = 
  "hidden_hint" id=hint4&gt;<BR>&nbsp;Add -<BR>&nbsp;&lt;img 
  src="../images/sq_root_7.gif" align="absmiddle"&gt;<BR>&nbsp;to both sidesof 
  the equation.<BR>&lt;/span&gt;<BR>&nbsp;<BR>function toggle_visibility(id) 
  {<BR>&nbsp; var e = document.getElementById(id);<BR>&nbsp; 
  if(e.style.visibility != 'visible')<BR>&nbsp;&nbsp; e.style.visibility = 
  'visible';<BR>&nbsp; else<BR>&nbsp;&nbsp; e.style.visibility = 'hidden'; <BR>} 
  <BR>&nbsp;<BR>One thing I don't understand is what's the use of a toggle 
  function if<BR>there is no "onmouseout" event defined? Since you'll have to 
  mouseover<BR>twice to toggle it, consider defining the mouseout 
  also:<BR><BR>&lt;a href="#"onMouseOver = toggle_visibility('hint4') 
  <BR>onMouseOut = 
  toggle_visibility('hint4')&gt;<BR>...<BR><BR>Regards<BR>~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 
  <BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Troy III 
  <BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
  progressive art 
  enterprise<BR>~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~<BR><BR><BR><BR>
  <HR id=stopSpelling>
  <BR>&gt; From: del@delweg.com<BR>&gt; To: javascript@LaTech.edu<BR>&gt; Date: 
  Mon, 4 Jun 2007 22:13:51 -0500<BR>&gt; Subject: [Javascript] Trouble with 
  id<BR>&gt; <BR>&gt; Good Day;<BR>&gt; <BR>&gt; This is the JavaScript 
  function<BR>&gt; function toggle_visibility(id)<BR>&gt; {<BR>&gt; var e = 
  document.getElementById(id);<BR>&gt; if(e.style.visibility != 
  'visible')<BR>&gt; e.style.visibility = 'visible';<BR>&gt; else<BR>&gt; 
  e.style.visibility = 'hidden';<BR>&gt; }<BR>&gt; <BR>&gt; This is the HTML 
  which does the calling<BR>&gt; &lt;a href="#" onMouseOver = 
  toggle_visibility(104)&gt;<BR>&gt; &lt;img src="../../image/icon_toggle.jpg" 
  width="22" height="22" <BR>&gt; border="0"&gt;&lt;/a&gt;<BR>&gt; &lt;span 
  class = "hidden_hint" id=104&gt;<BR>&gt; Add -&lt;img 
  src="../images/sq_root_7.gif" align="absmiddle"&gt; to both sides<BR>&gt; of 
  the equation.<BR>&gt; &lt;/span&gt;<BR>&gt; <BR>&gt; This works fine when I 
  use a number for the id.<BR>&gt; However I would prefer(reasons involve the 
  rest of the page) to use "hint4" <BR>&gt; for the ID<BR>&gt; When I use hint4 
  with or without quotes, the whole toggle fails.<BR>&gt; An ALERT inserted in 
  the function returns object for id when I use hint4<BR>&gt; and returns the 
  number when I use a number.<BR>&gt; <BR>&gt; I do not understand.<BR>&gt; Can 
  someone explain what goes wrong when I use id = hint4 ?<BR>&gt; <BR>&gt; 
  Thanks for any help.<BR>&gt; <BR>&gt; Del<BR>&gt; <BR>&gt; <BR>&gt; 
  _______________________________________________<BR>&gt; Javascript mailing 
  list<BR>&gt; Javascript@LaTech.edu<BR>&gt; 
  https://lists.LaTech.edu/mailman/listinfo/javascript<BR><BR><BR>
  <HR>
  Play free games, earn tickets, get cool prizes! Join Live Search 
  Club.&nbsp;&nbsp; <A 
  href="http://club.live.com/home.aspx?icid=CLUB_wlmailtextlink" 
  target=_new>Join Live Search Club!</A> 
  <P>
  <HR>

  <P></P>_______________________________________________<BR>Javascript mailing 
  list<BR>Javascript@LaTech.edu<BR>https://lists.LaTech.edu/mailman/listinfo/javascript<BR></BLOCKQUOTE></BODY></HTML>