PDA

View Full Version : Can't get chrome menu bar to work with flash



uelandg
09-05-2007, 01:23 PM
1) Script Title: Chrome CSS Drop Down Menu

2) Script URL (on DD): http://www.dynamicdrive.com/dynamicindex1/chrome/index.htm

3) Describe problem:

I cannot get the chrome menu to work with a flash script.

I have tried to put the flash header on top and put the chrome menu below. What results is either the chrome menu shows, when the flash script is gone, or the flash menu shows when the chrome menu script is there or not.

Here is my code. By the way, I have added the chromestyle.css code to mainstyle.css to consolidate the styles.


<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>menuheader</title>
<script language="javascript">AC_FL_RunContent = 0;</script>
<script src="AC_RunActiveContent.js" language="javascript"></script>
<link href="css/mainStyle.css" rel="stylesheet" type="text/css">
<script type="text/javascript" src="chromejs/chrome.js">

/***********************************************
* Chrome CSS Drop Down Menu- Dynamic Drive DHTML code library (www.dynamicdrive.com)
* This notice MUST stay intact for legal use
* Visit Dynamic Drive at http://www.dynamicdrive.com/ for full source code
***********************************************/

</script>
</head>
<body>
<table align="center" cellpadding="0" cellspacing="0">
<tr>
<td valign="top">

<!--url's used in the movie-->
<!--text used in the movie-->
<!-- saved from url=(0013)about:internet -->
<script language="javascript">
if (AC_FL_RunContent == 0) {
alert("This page requires AC_RunActiveContent.js.");
} else {
AC_FL_RunContent(
'codebase', 'http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,0,0',
'width', '773',
'height', '130',
'src', 'menuheader',
'quality', 'high',
'pluginspage', 'http://www.macromedia.com/go/getflashplayer',
'align', 'middle',
'play', 'true',
'loop', 'true',
'scale', 'showall',
'wmode', 'window',
'devicefont', 'false',
'id', 'menuheader',
'bgcolor', '#ffffff',
'name', 'menuheader',
'menu', 'true',
'allowFullScreen', 'false',
'allowScriptAccess','sameDomain',
'movie', 'menuheader',
'salign', ''
); //end AC code
}
</script>
<noscript>
<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,0,0" width="773" height="130" id="menuheader" align="middle">
<param name="allowScriptAccess" value="sameDomain" />
<param name="allowFullScreen" value="false" />
<param name="wmode" value="transparent">
<param name="movie" value="menuheader.swf" />
<param name="quality" value="high" />
<param name="bgcolor" value="#ffffff" />
<embed src="menuheader.swf" wmode="transparent" quality="high" bgcolor="#ffffff" width="773" height="130" name="menuheader" align="middle" allowScriptAccess="sameDomain" allowFullScreen="false" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" />
</object>
</td>
</tr>
</table>
<div align="center" class="chromestyle" id="chromemenu">

<ul>
<li><a href="http://www.dynamicdrive.com">Home</a></li>
<li><a href="#" rel="dropmenu1">Resources</a></li>
<li><a href="#" rel="dropmenu2">News</a></li>
<li><a href="#" rel="dropmenu3">Search</a></li>
</ul>
</div>

<!--1st drop down menu -->
<div id="dropmenu1" class="dropmenudiv">
<a href="">Link 1</a>
<a href="">Link 2</a>
<a href="">Link 3</a>
<a href="">Link 4</a>
<a href="">Link 5</a>
</div>


<!--2nd drop down menu -->
<div id="dropmenu2" class="dropmenudiv" style="width: 150px;">
<a href="">Link 1</a>
<a href="">Link 2</a>
<a href="">Link 3</a>
</div>

<!--3rd drop down menu -->
<div id="dropmenu3" class="dropmenudiv" style="width: 150px;">
<a href="">Link 1</a>
<a href="">Link 2</a>
<a href="">Link 3</a>
</div>


<script type="text/javascript">

cssdropdown.startchrome("chromemenu")

</script></body>
</html>

jscheuer1
09-05-2007, 03:51 PM
To make this easier to diagnose:

Please post a link to the page on your site that contains the problematic script so we can check it out.

One solution that may not require much sleuthing would be to include your Flash item on the page without using the AC_RunActiveContent.js script or the script that depends upon it, neither of which are required for any reason.

uelandg
09-05-2007, 04:09 PM
Here is the link:

http://www.campusmanitoba.com/index-new.asp

jscheuer1
09-05-2007, 04:34 PM
Really just a typo. You forgot to close the <noscript> tag:


<noscript>
<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,0,0" width="773" height="130" id="menuheader" align="middle">
<param name="allowScriptAccess" value="sameDomain" />
<param name="allowFullScreen" value="false" />
<param name="wmode" value="transparent">
<param name="movie" value="menuheader.swf" />
<param name="quality" value="high" />
<param name="bgcolor" value="#ffffff" />
<embed src="menuheader.swf" wmode="transparent" quality="high" bgcolor="#ffffff" width="773" height="130" name="menuheader" align="middle" allowScriptAccess="sameDomain" allowFullScreen="false" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" />
</object></noscript>

One other thing, just offhand, that you might want to do is to change the version number to 8 or lower (red in the above, and below, scroll to see them) - whatever the lowest Flash version that will support your Flash item is:


. . .
AC_FL_RunContent(
'codebase', 'http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,0,0',
. . .