Welcome to WebmasterWorld Guest from

Forum Moderators: incrediBILL

Message Too Old, No Replies

Floating Div Javascript not working in FF

Floating Div Javascript Fire Fox

7:04 pm on Aug 28, 2009 (gmt 0)

New User

5+ Year Member

joined:Aug 28, 2009
posts: 1
votes: 0

I am trying to make a Floating div visible in both I.E. and Firefox. I can only get it to work in i.e. it works in I.e. when I put the code in the <HEAD> tag however not in Firefox. I can get it to work for both if I put the code outside of the HTML tags altogher however If it works in both it justifies my web page to the left in i.e. I have inserted every possible tag possible to center the page but it is still justifying the page to the left. Whats more is the code is a mixture of includes, css, and asp. The script that I am using for the "visibility" is as follows:

<script type="text/javascript">

// shows the pop up div

function showObject(e, element) {

document.getElementById(element.id).style.visibility = "visible";

document.getElementById(element.id).style.top = e.clientY;


// hides to pop up div

function hideObject(element) {

document.getElementById(element.id).style.visibility = "hidden";




8:15 pm on Aug 28, 2009 (gmt 0)

Senior Member

WebmasterWorld Senior Member rocknbil is a WebmasterWorld Top Contributor of All Time 10+ Year Member

joined:Nov 28, 2004
votes: 0

Welcome aboard Taggert, without running the code, where does "clientY" come from?

Also, what does your FireFox error console have to say about it?


Join The Conversation

Moderators and Top Contributors

Hot Threads This Week

Featured Threads

Free SEO Tools

Hire Expert Members