HTML Programming
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsWeb DesignHTML Programming

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old December 21st, 2000, 11:07 AM
gqlondon gqlondon is offline
Junior Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Dec 2000
Posts: 2 gqlondon User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
HI, can someone tell me why the menu doesn't expand in netscape, but does in ie?
code below:
<br>
<script language="JavaScript">
//--- Preload Images ---//
var idx;
var check;
var maxImages = 20; // Number of images to preload.
var rollImg = new Array();
for(idx=0; idx < maxImages + 1; idx++)

function writeMenu(catTitle,catNum)
//{
// if (navigator.appName == 'Netscape' && document.layers != null)
// document.write( "<font face="Arial,Helvetica" size="2" color="#000084"><b>" + catTitle + "</b></font><br><div>");
// else
{
var imgBeg = "<img ";
var imgBtn = "id="btn" + catNum + "" ";
var imgSrc = "src="http://www.ukinvest.com/images/lc_uk_plus.gif" ";
var imgWidth = "width="11" ";
var imgHeight = "height="11" ";
var imgBorder = "border="0" ";
var imgAlt = "ALT="Expand/Collapse Item" ";
var imgClick = "onClick="expandIt(cat" + catNum + ",btn" + catNum + ")" ";
var imgStyle = "style="cursor: hand;">";
document.write(imgBeg+imgBtn+imgSrc+imgWidth+imgHeight+imgBorder+imgAlt+imgClick+imgStyle);
var divBeg = "<a href="javascript:showmenu();" class="b" style="cursor:hand" ";
var divClick = "onclick="expandIt(cat" + catNum + ",btn" + catNum + ")"> ";
var divEnd = catTitle + "</a><br><div id="cat" + catNum + "" style="display:none">";
document.write(divBeg+divClick+divEnd);
}
//}
function showmenu(){}
function expandIt(whichEl,button)
{
var outcount;
var objCatCls;
var objBtnCls;
nomenus = 11; //Set to the number of menus
for (outCount=1; outCount < nomenus +1; outCount++)
{
objCatCls = eval("cat" + outCount);
objBtnCls = eval("btn" + outCount);
if(whichEl.id != objCatCls.id)
{
objCatCls.style.display="none";
objBtnCls.src = "http://www.ukinvest.com/images/lc_uk_plus.gif";
}
}
if (whichEl.style.display == "none")
{
whichEl.style.display = "";
button.src = "http://www.ukinvest.com/images/lc_uk_minus.gif";
}
else
{
whichEl.style.display = "none";
button.src = "http://www.ukinvest.com/images/lc_uk_plus.gif";
}
}

myRandomNum = Math.round(10000*Math.random())

<!--// MOUSE-OVERS AND PRELOADED FUNCTIONS

function GotoURL(form)
{
if (form.lister.selectedIndex)
window.location.href = form.lister.options[form.lister.selectedIndex].value;
return false;
}
function MM_preloadImages() { //v2.0
if (document.images) {
var imgFiles = MM_preloadImages.arguments;
if (document.preloadArray==null) document.preloadArray = new Array();
var i = document.preloadArray.length;
with (document) for (var j=0; j<imgFiles.length; j++) if (imgFiles[j].charAt(0)!="#"){
preloadArray[i] = new Image;
preloadArray[i++].src = imgFiles[j];
} }
}

function MM_swapImgRestore() { //v2.0
if (document.MM_swapImgData != null)
for (var i=0; i<(document.MM_swapImgData.length-1); i+=2)
document.MM_swapImgData[i].src = document.MM_swapImgData[i+1];
}

function MM_swapImage() { //v2.0
var i,j=0,objStr,obj,swapArray=new Array,oldArray=document.MM_swapImgData;
for (i=0; i < (MM_swapImage.arguments.length-2); i+=3) {
objStr = MM_swapImage.arguments[(navigator.appName == 'Netscape')?i:i+1];
if ((objStr.indexOf('document.layers[')==0 && document.layers==null) | |
(objStr.indexOf('document.all[') ==0 && document.all ==null))
objStr = 'document'+objStr.substring(objStr.lastIndexOf('.'),objStr.length);
obj = eval(objStr);
if (obj != null) {
swapArray[j++] = obj;
swapArray[j++] = (oldArray==null | | oldArray[j-1]!=obj)?obj.src URLldArray[j];
obj.src = MM_swapImage.arguments[i+2];
} }
document.MM_swapImgData = swapArray; //used for restore
}

function MM_showHideLayers() { //v2.0
var i, visStr, args, theObj;
args = MM_showHideLayers.arguments;
for (i=0; i<(args.length-2); i+=3) { //with arg triples (objNS,objIE,visStr)
visStr = args[i+2];
if (navigator.appName == 'Netscape' && document.layers != null) {
theObj = eval(args[i]);
if (theObj) theObj.visibility = visStr;
} else if (document.all != null) { //IE
if (visStr == 'show') visStr = 'visible'; //convert vals
if (visStr == 'hide') visStr = 'hidden';
theObj = eval(args[i+1]);
if (theObj) theObj.style.visibility = visStr;
} }
}
//-->

</script>

</head>

<BODY BGCOLOR="#FFFFFF" VLINK="#00009C" LINK="#00009C" ALINK="#cc0000" TEXT="#000000" onLoad="MM_preloadImages('http://www.ukinvest.com/images/lc_glbnetwork_america.gif','#940452562264');MM_preloadImages('http://www.ukinvest.com/images/lc_glbnetwork_glbnfinancial.gi f','#940452632725');MM_preloadImages('http://www.ukinvest.com/images/lc_glbnetwork_italia.gif','#940452648037');MM_preloadImages('http://www.ukinvest.com/images/lc_glbnetwork_learn _uk.gif','#940452673163');MM_preloadImages('http://www.ukinvest.com/images/lc_glbnetwork_matchbook.gif','#940452673163');MM_preloadImages('http://www.ukinvest.com/images/lc_glbnetw ork_neder.gif','#940452673163');MM_preloadImages('http://www.ukinvest.com/images/lc_glbnetwork_ukwire.gif','#940452673163');MM_preloadImages('http://www.ukinvest.com/images/lc_uk_p lus.gif');MM_preloadImages('http://www.ukinvest.com/images/lc_glbnetwork_fr.gif');MM_preloadImages('http://www.ukinvest.com/images/lc_uk_minus.gif');MM_preloadImages('http://www.uk invest.com/images/lc_glbnetwork_danmark.gif');"><!--htdig_noindex-->

</center>
<script LANGUAGE="JavaScript">
writeMenu("Market Watch",1);
</script>
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td><img src="/images/trans_pixel_1x1.gif" width=15 height=1 alt="" border=0></td>
<td>
<a class="a" href="http://ukinvest.ukwire.com/type/16/">Directors' Dealings</a><br>
<a class="a" href="/news/markets.html">Market Roundup</a><br>
<a class="a" href="/freeserve">News Briefings</a><br>
<a class="a" href="/homepage/move.html">Stocks on the Move</a><br>
<a class="a" href="/news/techoutlook.html">Technical Outlook</a><br>
<a class="a" href="http://ukinvest.stockpoint.com/ukinvest/mostactive.asp?group=UKMKTCAP">Top Gainers/Losers</a><br>
<a class="a" href="/news/yourbuys.html">What You're Buying</a><br>
<a class="a" href="/homepage/bulletin.html">What's on the Boards</a><p>
</td>
</tr>
</table>
</div>
<script>writeMenu("What's News",2)</script>
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td><img src="/images/trans_pixel_1x1.gif" width=15 height=1 alt="" border=0></td>
<td>
<a class="a" href="/news/brokerstips.html">Brokers' Tips</a><br>
<a class="a" href="/news/bbriefs.html">Economy</a><br>
<a class="a" href="/news/internetnews.html">Internet News</a><br>
<a class="a" href="/news/issues.html">New Issues/</a><a class="a" href="/news/tables.html">Tables</a><br>
<a class="a" href="/news/newspaper.html">Press Clips</a><br>
<a class="a" href="http://ukinvest.ukwire.com/">UK-Wire</a><p>
<p>
</td>
</tr>
</table>
</div>

Reply With Quote
Reply

Viewing: Dev Shed ForumsWeb DesignHTML Programming > dynamic menu doesn't work in netscape?


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump



 Free IT White Papers!
 
How to Present Effectively Online
This white paper offers practical and actionable advice on the key steps that any presenter should consider as they plan and execute a Webinar or online meeting.

 
Open Source Security Myths
Open Source Software (OSS) is computer software whose source code is available to the general public with relaxed or non-existent intellectual property restrictions (or arrangement such as the public domain), and is usually developed with the input of many contributors.

 
Power and Cooling Capacity Management for Data Centers
This paper describes the principles for achieving power and cooling capacity management.

 
Scalable, Fault-Tolerant NAS for Oracle - The Next Generation
For several years NAS has been evolving as a storage alternative for Oracle databases, and for good reason: NAS is quite often the simplest, most cost-effective storage approach for Oracle. Learn about the benefits that HP's approach to scalable NAS brings to Oracle environments in this comprehensive white paper.

 
Understanding Web Application Security Challenges
This white paper discusses many common threats and preventive measures for Web application security, and explains what you can do to help protect your organization.

 

Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2009 by Developer Shed. All rights reserved. DS Cluster 6 hosted by Hostway
Stay green...Green IT