Welcome to Tech Support Forum home to more then 136,000 problems solved. Issues have included: Spyware, Malware, Virus Issues, Windows, Microsoft, Linux, Networking, Security, Hardware, and Gaming Getting your problem solved is as easy as:
1. Registering for a free account
2. Asking your question
3. Receiving an answer

Registered members:
* Get free support
* Communicate privately with other members (PM).
* Removal of this message
* See fewer ads.
* And much more..

 





Want to know how to post a question? click here Having problems with spyware and pop-ups? First Steps
Go Back   Tech Support Forum > Design Forum > Web Design & Programming
User Name
Password
Site Map Register Donate Rules Blogs Mark Forums Read

Web Design & Programming Discussion of web design, and server-side & client-side scripting

Reply
 
Thread Tools
Old 08-31-2008, 06:01 PM   #1 (permalink)
Registered User
 
Join Date: Aug 2008
Posts: 2
OS: vista


Firefox vs IE

I created a website with Dreamweaver CS3 in which I used a flash video and a Spry menu bar. Everything looks great in Firefox, IE, and Safari.

However, when I tried to stack three div tags on the right side of my page, I get a different view in Firefox/Safari then in IE. I suspect it's in my code or in the way I've stacked the tags, but I don't know how to fix it. I've been working on days, and I'm now admiting that I need HELP!

The second question I have is that when I use the IE browses I have to click on "allow running Active X" to see the slideshow -- is there I can right this in code so that others won't have to be bothered?

Here is my code:

Code:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Home</title>
<link href="SpryAssets/SpryMenuBarVertical.css" rel="stylesheet" type="text/css" />
<script src="SpryAssets/SpryMenuBar.js" type="text/javascript"></script>
<script src="Scripts/AC_RunActiveContent.js" type="text/javascript"></script>
<style type="text/css"> 
<!-- 
--> 
</style>
<link href="Main.css" rel="stylesheet" type="text/css" />
</head>

<body class="thrColFixHdr">
<div id="container">
  <div id="header"><img src="Banner11.png" width="560" height="166" />
    <script type="text/javascript">
AC_FL_RunContent( 'codebase','http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,28,0','width','174','height','134','hspace','18','vspace','14','title','Photos','src','BannerMovieF2','quality','high','pluginspage','http://www.adobe.com/shockwave/download/download.cgi?P1_Prod_Version=ShockwaveFlash','movie','BannerMovieF2' ); //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,28,0" width="174" height="134" hspace="18" vspace="14" title="Photos">
        <param name="movie" value="BannerMovieF2.swf" />
        <param name="quality" value="high" />
        <embed src="BannerMovieF2.swf" width="174" height="134" hspace="18" vspace="14" quality="high" pluginspage="http://www.adobe.com/shockwave/download/download.cgi?P1_Prod_Version=ShockwaveFlash" type="application/x-shockwave-flash"></embed>
      </object>
      </noscript>
  </div>
<div id="headerbot">
          <div align="center"><img name="BannerBot" src="BannerBot.gif" width="780" height="62" border="0" id="BannerBot" alt="Communities Served" /></div>
  </div>
  <div id="sidebar1">
    <ul id="MenuBar1" class="MenuBarVertical">
      <li><a href="Index.html">HOME</a>        </li>
      <li><a href="About Us.html" class="MenuBarItemSubmenu">ABOUT US</a>
        <ul>
          <li><a href="About Us.html"> Purpose</a></li>
          <li><a href="Leadership.html">Leadership</a></li>
        </ul>
      </li>
      <li><a class="MenuBarItemSubmenu" href="#">GRANTS</a>
          <ul>
            <li><a href="#">What We Fund</a>            </li>
            <li><a href="#">Instructions</a></li>
            <li><a href="#">Application</a></li>
          </ul>
      </li>
      <li><a href="#">EVENTS</a> </li>
      <li><a href="#" class="MenuBarItemSubmenu">DONATE</a>
        <ul>
          <li><a href="#">Ways to Give</a></li>
          <li><a href="#">Donate Form</a></li>
        </ul>
      </li>
      <li><a href="#">VOLUNTEER</a></li>
      <li><a href="#">CONTACT US</a></li>
    </ul>
    <p>
      <!-- end #sidebar1 --><img src="Child.JPG" alt="Logo" width="139" height="138" /></p>
    <div id="leftlogo"></div>
  </div>
  
  <div id="mainContent">
    <h6><span class="fpheading">WELCOME TO THE I.S.D. NO 197 EDUCATIONAL </span><span class="fpheading">FOUNDATION</span> </h6>
    <span class="text">Good  school districts require supportive partners that enable them to grow from  ordinary to extraordinary. As  the gap between government aid and the increased need for innovative  programming widens, this becomes even more  critical.</span>&nbsp;
    <p class="text">The I.S.D. No. 197 Educational Foundation supports educational  opportunities that help our learners build successful lives.&nbsp; We do so by seeking additional resources that  will enable our teachers to consider new avenues to improve and enhance  learning throughout the district.&nbsp; We allow more imaginative and creative ways for  students to learn by generating financial support for programs,  equipment and projects that promote and enhance excellence in our schools.</p>
    <p class="text"> We hope you  will join us in making a tax-deductible contribution to this endeavor.&nbsp; Your dollars will stay right here, providing  resources that would otherwise not be available.&nbsp; And because the Foundation is a  volunteer-only organization, the dollars you contribute are used for programs  and people, not administration costs.</p>
  </div>
  <p>
  <!-- This clearing element should immediately follow the #mainContent div in order to force the #container div to contain all child floats -->
  <p>&nbsp;</p>
  <div id="sidebar2">TEST</div>
  <p>&nbsp;</p>
  <p>&nbsp;</p>
  <div id="sidebar3">TEST</div>
  <p>&nbsp;</p>
  <p>&nbsp;</p>
  <div id="sidebar4">TEST</div>
   <p>&nbsp;	</p>
     <p><br class="clearfloat" />
       <br />
        </p>
     <div id="footer">
    <p>I.S.D. NO. 197 Educational Foundation &nbsp;&nbsp;1897 Delaware Avenue &nbsp; &nbsp;Mendota Heights, MN 55118 </p>
    <!-- end #footer -->
  </div>
<!-- end #container --></div>

<script type="text/javascript">
<!--
var MenuBar1 = new Spry.Widget.MenuBar("MenuBar1", {imgRight:"SpryAssets/SpryMenuBarRightHover.gif"});
//-->
</script>
</body>
</html>
Thanks!

A "54" year young volunteer who thought this would be much simpler.

Last edited by carsey : 08-31-2008 at 07:08 PM.
duluthmn is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Bookmark on Thread SoupReddit!
Reply With Quote
Old 08-31-2008, 06:41 PM   #2 (permalink)
Registered User
 
Join Date: Aug 2008
Posts: 2
OS: vista


Re: Firefox vs IE - additional code

Here is the CSS and Spry codes

Code:
@charset "utf-8";
/* CSS Document */
body  {
	font: 100% Verdana, Arial, Helvetica, sans-serif;
	background: #666666;
	margin: 0; /* it's good practice to zero the margin and padding of the body element to account for differing browser defaults */
	padding: 0;
	text-align: center; /* this centers the container in IE 5* browsers. The text is then set to the left aligned default in the #container selector */
	color: #000000;
}
.thrColFixHdr #container {
	width: 780px;  /* using 20px less than a full 800px width allows for browser chrome and avoids a horizontal scroll bar */
	background: #FFFFFF;
	margin: 0 auto;
	text-align: left; /* this overrides the text-align: center on the body element. */
	border: 1px solid #000000;
} 
.thrColFixHdr #header {
	background-color: #FFFF66;
	width: 777px;
	float: left;
	height: 166px;
	border-left-width: 2px;
	border-left-style: solid;
	border-left-color: #FF0000;
	border-top-width: 2px;
	border-top-style: solid;
	border-top-color: #FF0000;
	border-right-width: 2px;
	border-right-style: solid;
	border-right-color: #FF0000;
} 
.thrColFixHdr #sidebar1 {
	float: left; /* since this element is floated, a width must be given */
	width: 150px; /* padding keeps the content of the div away from the edges */
	background-color: #FFFFFF;
	padding-top: 15px;
	padding-right: 10px;
	padding-bottom: 15px;
	padding-left: 25px;
}
.footer {
	font-family: Calibri;
	font-size: 10px;
	font-weight: bold;
	color: #FF0000;
}
.thrColFixHdr #sidebar2 {
	float: right; /* since this element is floated, a width must be given */
	width: 145px; /* the actual width of this div, in standards-compliant browsers, or standards mode in Internet Explorer will include the padding and border in addition to the width */
	background: #EBEBEB;
	padding-right: 0px;
	padding-bottom: 15px;
	padding-left: 15px;
	background-color: #336600;
	margin-top: 15px;
	margin-right: 22px;
	height: 600px;
}
.thrColFixHdr #mainContent {
	margin-top: 0;
	margin-right: 0px;
	margin-bottom: 0;
	margin-left: 0px;
	padding-top: 0px;
	padding-right: 20px;
	padding-bottom: 0;
	padding-left: 15px;
	float: left;
	width: 350px;
} 
.thrColFixHdr #footer {
	padding: 0 10px 0 20px;
	background-color: #0066CC;
} 
.thrColFixHdr #footer p {
	margin: 0; /* zeroing the margins of the first element in the footer will avoid the possibility of margin collapse - a space between divs */
	padding: 10px 0; /* padding on this element will create space, just as the the margin would have, without the margin collapse issue */
	font-family: Verdana, Arial, Helvetica, sans-serif;
	font-size: 10px;
	font-weight: bold;
	color: #FFFFFF;
	text-align: center;
}
.fltrt { /* this class can be used to float an element right in your page. The floated element must precede the element it should be next to on the page. */
	float: right;
	margin-left: 8px;
}
.fltlft { /* this class can be used to float an element left in your page */
	float: left;
	margin-right: 8px;
}
.clearfloat { /* this class should be placed on a div or break element and should be the final element before the close of a container that should fully contain a float */
	clear:both;
    height:0;
    font-size: 1px;
    line-height: 0px;

}
#leftlogo {
}
#apDiv10 {
	position:absolute;
	left:988px;
	top:23px;
	width:174px;
	height:134px;
	z-index:1;
	background-color: #FFFF66;
}
.fpheading {
	font-family: Verdana, Arial, Helvetica, sans-serif;
	font-size: 18px;
	color: #0066CC;
}
.text {
	font-family: Verdana, Arial, Helvetica, sans-serif;
	font-size: 12px;
	line-height: 18px;
}
.thrColFixHdr #headerss {
	background-color: #FFFF66;
	width: 176px;
	float: right;
	height: 134px;
	margin-right: 15px;
}
#box {
	height: 75px;
	width: 780px;
}
.thrColFixHdr #sidebar3 {
	float: none; /* since this element is floated, a width must be given */
	width: 130px;
	padding: 0px;
	height: 70px;
	margin-top: 20px;
	margin-right: 0px;
	margin-left: 0px;
}
.FundFacts {
	font-family: "Comic Sans MS";
	font-size: 16px;
	font-style: normal;
	line-height: 22px;
	color: #FFFF66;
	text-align: center;
	font-weight: bold;
}
.thrColFixHdr #sidebar4 {
	float: none; /* since this element is floated, a width must be given */
	width: 130px;
	height: 370px;
	text-align: center;
	background-color: #FFFF66;
}
.thrColFixHdr #sidebar5 {
	float: none; /* since this element is floated, a width must be given */
	width: 130px;
	padding: 0px;
	height: 200px;
	margin-right: 0px;
	margin-bottom: 0px;
	margin-left: 0px;
}
.textfund {
	font-family: "Comic Sans MS";
	font-weight: bold;
	color: #FF0000;
	text-align: center;
	font-size: 15px;
	text-transform: uppercase;
	padding-right: 5px;
}
.textfact {
	font-size: 15px;
	text-align: center;
	padding-top: 6px;
	padding-right: 12px;
	padding-bottom: 0px;
	padding-left: 12px;
	font-family: "Comic Sans MS";
}
.style1 {color: #F0F0F0}
.thrColFixHdr #headerbot {
	background-color: #FFFF66;
	width: 777px;
	float: left;
	height: 62px;
	border-left-color: #FF0000;
	border-top-style: none;
	border-top-color: #FF0000;
	margin-bottom: 15px;
	border-right-color: #FF0000;


/* SpryMenuBar.js - Revision: Spry Preview Release 1.4 */

// Copyright (c) 2006. Adobe Systems Incorporated.
// All rights reserved.
//
// Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following conditions are met:
//
//   * Redistributions of source code must retain the above copyright notice,
//     this list of conditions and the following disclaimer.
//   * Redistributions in binary form must reproduce the above copyright notice,
//     this list of conditions and the following disclaimer in the documentation
//     and/or other materials provided with the distribution.
//   * Neither the name of Adobe Systems Incorporated nor the names of its
//     contributors may be used to endorse or promote products derived from this
//     software without specific prior written permission.
//
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
// AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
// ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
// LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
// CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
// SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
// CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
// ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
// POSSIBILITY OF SUCH DAMAGE.

/*******************************************************************************

 SpryMenuBar.js
 This file handles the JavaScript for Spry Menu Bar.  You should have no need
 to edit this file.  Some highlights of the MenuBar object is that timers are
 used to keep submenus from showing up until the user has hovered over the parent
 menu item for some time, as well as a timer for when they leave a submenu to keep
 showing that submenu until the timer fires.

 *******************************************************************************/

var Spry;
if(!Spry)
{
	Spry = {};
}
if(!Spry.Widget)
{
	Spry.Widget = {};
}

// Constructor for Menu Bar
// element should be an ID of an unordered list (<ul> tag)
// preloadImage1 and preloadImage2 are images for the rollover state of a menu
Spry.Widget.MenuBar = function(element, opts)
{
	this.init(element, opts);
};

Spry.Widget.MenuBar.prototype.init = function(element, opts)
{
	this.element = this.getElement(element);

	// represents the current (sub)menu we are operating on
	this.currMenu = null;

	var isie = (typeof document.all != 'undefined' && typeof window.opera == 'undefined' && navigator.vendor != 'KDE');
	if(typeof document.getElementById == 'undefined' || (navigator.vendor == 'Apple Computer, Inc.' && typeof window.XMLHttpRequest == 'undefined') || (isie && typeof document.uniqueID == 'undefined'))
	{
		// bail on older unsupported browsers
		return;
	}

	// load hover images now
	if(opts)
	{
		for(var k in opts)
		{
			var rollover = new Image;
			rollover.src = opts[k];
		}
	}

	if(this.element)
	{
		this.currMenu = this.element;
		var items = this.element.getElementsByTagName('li');
		for(var i=0; i<items.length; i++)
		{
			this.initialize(items[i], element, isie);
			if(isie)
			{
				this.addClassName(items[i], "MenuBarItemIE");
				items[i].style.position = "static";
			}
		}
		if(isie)
		{
			if(this.hasClassName(this.element, "MenuBarVertical"))
			{
				this.element.style.position = "relative";
			}
			var linkitems = this.element.getElementsByTagName('a');
			for(var i=0; i<linkitems.length; i++)
			{
				linkitems[i].style.position = "relative";
			}
		}
	}
};

Spry.Widget.MenuBar.prototype.getElement = function(ele)
{
	if (ele && typeof ele == "string")
		return document.getElementById(ele);
	return ele;
};

Spry.Widget.MenuBar.prototype.hasClassName = function(ele, className)
{
	if (!ele || !className || !ele.className || ele.className.search(new RegExp("\\b" + className + "\\b")) == -1)
	{
		return false;
	}
	return true;
};

Spry.Widget.MenuBar.prototype.addClassName = function(ele, className)
{
	if (!ele || !className || this.hasClassName(ele, className))
		return;
	ele.className += (ele.className ? " " : "") + className;
};

Spry.Widget.MenuBar.prototype.removeClassName = function(ele, className)
{
	if (!ele || !className || !this.hasClassName(ele, className))
		return;
	ele.className = ele.className.replace(new RegExp("\\s*\\b" + className + "\\b", "g"), "");
};

// addEventListener for Menu Bar
// attach an event to a tag without creating obtrusive HTML code
Spry.Widget.MenuBar.prototype.addEventListener = function(element, eventType, handler, capture)
{
	try
	{
		if (element.addEventListener)
		{
			element.addEventListener(eventType, handler, capture);
		}
		else if (element.attachEvent)
		{
			element.attachEvent('on' + eventType, handler);
		}
	}
	catch (e) {}
};

// createIframeLayer for Menu Bar
// creates an IFRAME underneath a menu so that it will show above form controls and ActiveX
Spry.Widget.MenuBar.prototype.createIframeLayer = function(menu)
{
	var layer = document.createElement('iframe');
	layer.tabIndex = '-1';
	layer.src = 'javascript:false;';
	menu.parentNode.appendChild(layer);
	
	layer.style.left = menu.offsetLeft + 'px';
	layer.style.top = menu.offsetTop + 'px';
	layer.style.width = menu.offsetWidth + 'px';
	layer.style.height = menu.offsetHeight + 'px';
};

// removeIframeLayer for Menu Bar
// removes an IFRAME underneath a menu to reveal any form controls and ActiveX
Spry.Widget.MenuBar.prototype.removeIframeLayer =  function(menu)
{
	var layers = menu.parentNode.getElementsByTagName('iframe');
	while(layers.length > 0)
	{
		layers[0].parentNode.removeChild(layers[0]);
	}
};

// clearMenus for Menu Bar
// root is the top level unordered list (<ul> tag)
Spry.Widget.MenuBar.prototype.clearMenus = function(root)
{
	var menus = root.getElementsByTagName('ul');
	for(var i=0; i<menus.length; i++)
	{
		this.hideSubmenu(menus[i]);
	}
	this.removeClassName(this.element, "MenuBarActive");
};

// bubbledTextEvent for Menu Bar
// identify bubbled up text events in Safari so we can ignore them
Spry.Widget.MenuBar.prototype.bubbledTextEvent = function()
{
	return (navigator.vendor == 'Apple Computer, Inc.' && (event.target == event.relatedTarget.parentNode || (event.eventPhase == 3 && event.target.parentNode == event.relatedTarget)));
};

// showSubmenu for Menu Bar
// set the proper CSS class on this menu to show it
Spry.Widget.MenuBar.prototype.showSubmenu = function(menu)
{
	if(this.currMenu)
	{
		this.clearMenus(this.currMenu);
		this.currMenu = null;
	}
	
	if(menu)
	{
		this.addClassName(menu, "MenuBarSubmenuVisible");
		if(typeof document.all != 'undefined' && typeof window.opera == 'undefined' && navigator.vendor != 'KDE')
		{
			if(!this.hasClassName(this.element, "MenuBarHorizontal") || menu.parentNode.parentNode != this.element)
			{
				menu.style.top = menu.parentNode.offsetTop + 'px';
			}
		}
		if(typeof document.uniqueID != "undefined")
		{
			this.createIframeLayer(menu);
		}
	}
	this.addClassName(this.element, "MenuBarActive");
};

// hideSubmenu for Menu Bar
// remove the proper CSS class on this menu to hide it
Spry.Widget.MenuBar.prototype.hideSubmenu = function(menu)
{
	if(menu)
	{
		this.removeClassName(menu, "MenuBarSubmenuVisible");
		if(typeof document.all != 'undefined' && typeof window.opera == 'undefined' && navigator.vendor != 'KDE')
		{
			menu.style.top = '';
			menu.style.left = '';
		}
		this.removeIframeLayer(menu);
	}
};

// initialize for Menu Bar
// create event listeners for the Menu Bar widget so we can properly
// show and hide submenus
Spry.Widget.MenuBar.prototype.initialize = function(listitem, element, isie)
{
	var opentime, closetime;
	var link = listitem.getElementsByTagName('a')[0];
	var submenus = listitem.getElementsByTagName('ul');
	var menu = (submenus.length > 0 ? submenus[0] : null);

	var hasSubMenu = false;
	if(menu)
	{
		this.addClassName(link, "MenuBarItemSubmenu");
		hasSubMenu = true;
	}

	if(!isie)
	{
		// define a simple function that comes standard in IE to determine
		// if a node is within another node
		listitem.contains = function(testNode)
		{
			// this refers to the list item
			if(testNode == null)
			{
				return false;
			}
			if(testNode == this)
			{
				return true;
			}
			else
			{
				return this.contains(testNode.parentNode);
			}
		};
	}
	
	// need to save this for scope further down
	var self = this;

	this.addEventListener(listitem, 'mouseover', function(e)
	{
		if(self.bubbledTextEvent())
		{
			// ignore bubbled text events
			return;
		}
		clearTimeout(closetime);
		if(self.currMenu == listitem)
		{
			self.currMenu = null;
		}
		// show menu highlighting
		self.addClassName(link, hasSubMenu ? "MenuBarItemSubmenuHover" : "MenuBarItemHover");
		if(menu && !self.hasClassName(menu, "MenuBarSubmenuVisible"))
		{
			opentime = window.setTimeout(function(){self.showSubmenu(menu);}, 250);
		}
	}, false);

	this.addEventListener(listitem, 'mouseout', function(e)
	{
		if(self.bubbledTextEvent())
		{
			// ignore bubbled text events
			return;
		}

		var related = (typeof e.relatedTarget != 'undefined' ? e.relatedTarget : e.toElement);
		if(!listitem.contains(related))
		{
			clearTimeout(opentime);
			self.currMenu = listitem;

			// remove menu highlighting
			self.removeClassName(link, hasSubMenu ? "MenuBarItemSubmenuHover" : "MenuBarItemHover");
			if(menu)
			{
				closetime = window.setTimeout(function(){self.hideSubmenu(menu);}, 600);
			}
		}
	}, false);
};

Last edited by carsey : 08-31-2008 at 07:08 PM. Reason: Added Code tags
duluthmn is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Bookmark on Thread SoupReddit!
Reply With Quote
Reply


Thread Tools

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
Trackbacks are Off
Pingbacks are Off
Refbacks are Off



All times are GMT -7. The time now is 04:02 PM.



Copyright 2001 - 2008, Tech Support Forum

Search Engine Friendly URLs by vBSEO

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82