Web Analytics Made Easy -
StatCounter new problem with floating menu - CodingForum

Announcement

Collapse
No announcement yet.

new problem with floating menu

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • new problem with floating menu

    hi guys,

    i have found a wee problem with my floating menu. i have used startx ="x" starty="y". however, when viewing the page with a larger monitor, the menu is obviously in a different position.

    is there a way to make it stay in the same place no matter what size screen?

    cheers

  • #2
    ...in the same place relative to what? Because in fact it stays in the same place relative to the left-top corner of the document.
    KOR
    Offshore programming
    -*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*

    Comment


    • #3
      lol, very true.

      well on my tiny little screen the co-ordinates have it next to a top border line and left of a border line. but obviously with a larger monitor this is out of place.

      i was hoping u could somehow fix the start location with a % instead of a fixed number. i think the tables around it are % widths and heights, so they remain constant on larger screens. example, startx=10% starty=66% or something, but i havent managed to get it to work

      Comment


      • #4
        can you pointed me to a link (if is a test on server) or show me the code? I have to see which element has those "border lines". Than I can calculate, on load, the absolute postion of that element. Now the start coordinates will be those coordinates or relative to them.
        KOR
        Offshore programming
        -*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*

        Comment


        • #5
          ok, i will cut some of the rubbish out, but u will have to excuse the code, i cant program and its probly very messy!

          dont know how much of this will work when copied either :S
          as you will (hopefully) see the menu is on the left and i need it to remain in its place, between the lines, on any resolution...cheers


          PHP Code:
          <html>

          <
          head>
          <
          meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
          <
          meta http-equiv="Content-Language" content="en-us">
          <
          title>News &ampEvents</title>
          <
          style>
          <!--
          div.Section1
              
          {page:Section1;}
          -->
          </
          style>
          <
          meta name="Microsoft Theme" content="breeze 1011">
          </
          head>

          <
          body>

          <
          table border="0" cellpadding="0" cellspacing="0" width="100%">
              <
          tr>
                  <
          td width="150" colspan="2" align="center" bgcolor="#101010" height="164">
                  <
          img border="0" src="images/badge.gif" width="112" height="161" align="left"></td>
                  <
          td align="center" width="643" bgcolor="#101010" height="164">
                  <
          p align="left"><font size="7">News Events</font><br>
                  <
          font size="5">April 2005</font>
                  </
          td>
              </
          tr>
              <
          tr>
                  <
          td width="100%" colspan="3" style="border-bottom-style: none; border-bottom-width: medium">
                  </
          td>
              </
          tr>
          </
          table>
          <
          table border="0" cellpadding="0" cellspacing="0" width="100%">
              <
          tr>
                  <
          td style="border-bottom-style: solid; border-bottom-width: 1" align="right">
                  <
          h4>
                  <
          script type="text/javascript">
          var 
          d=new Date()

          var 
          monthname=new Array("Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec")

          document.write(d.getDate() + "-")
          document.write(monthname[d.getMonth()] + "-")
          document.write(d.getFullYear())
          </
          script>
                  </
          h4>
                  </
          td>
              </
          tr>
          </
          table>
          <
          table border="0" cellpadding="0" cellspacing="0" width="100%">
              <
          tr>
                  <
          td valign="top" width="159" style="border-left-style:none; border-left-width:medium; border-right-style:solid; border-right-width:1; border-top-style:none; border-top-width:medium; border-bottom-style:none; border-bottom-width:medium" bgcolor="#101010">

          <
          script>
          if (!
          document.layers)
          document.write('<div id="divStayTopLeft" style="position:absolute">')
          </
          script>


          <
          layer id="divStayTopLeft">

                      <!--
          webbot CLIENTSIDE bot="Ws4FpEx" MODULEID="'83rdentry (Project)\mgaskin_off.xws'" PREVIEW="&lt;img src='images/mgaskin.gif?0ABDF448' editor='Webstyle4' border='0'&gt;" startspan  -->
                      <
          script src="xaramenu.js"></script>
                      <
          script Webstyle4 src="images/mgaskin.js"></script>
                      <
          noscript><img src="images/mgaskin.gif?0ABDF448" editor="Webstyle4"></noscript>
                      <!--
          webbot bot="Ws4FpEx" endspan i-checksum="53582"  -->


          </
          layer>


          <
          script type="text/javascript">

          /*
          Floating Menu script-  Roy Whittle (http://www.javascript-fx.com/)
          Script featured on/available at http://www.dynamicdrive.com/
          This notice must stay intact for use
          */

          //Enter "frombottom" or "fromtop"
          var verticalpos="frombottom"

          if (!document.layers)
          document.write('</div>')

          function 
          JSFX_FloatTopDiv()
          {
              var 
          startX 15,
              
          startY 485;
              var 
          ns = (navigator.appName.indexOf("Netscape") != -1);
              var 
          document;
              function 
          ml(id)
              {
                  var 
          el=d.getElementById?d.getElementById(id):d.all?d.all[id]:d.layers[id];
                  if(
          d.layers)el.style=el;
                  
          el.sP=function(x,y){this.style.left=x;this.style.top=y;};
                  
          el.startX;
                  if (
          verticalpos=="fromtop")
                  
          el.startY;
                  else{
                  
          el.ns pageYOffset innerHeight document.body.scrollTop document.body.clientHeight;
                  
          el.-= startY;
                  }
                  return 
          el;
              }
              
          window.stayTopLeft=function()
              {
                  if (
          verticalpos=="fromtop"){
                  var 
          pY ns pageYOffset document.body.scrollTop;
                  
          ftlObj.+= (pY startY ftlObj.y)/8;
                  }
                  else{
                  var 
          pY ns pageYOffset innerHeight document.body.scrollTop document.body.clientHeight;
                  
          ftlObj.+= (pY startY ftlObj.y)/8;
                  }
                  
          ftlObj.sP(ftlObj.xftlObj.y);
                  
          setTimeout("stayTopLeft()"10);
              }
              
          ftlObj ml("divStayTopLeft");
              
          stayTopLeft();
          }
          JSFX_FloatTopDiv();
          </
          script>

          &
          nbsp;<p>&nbsp;</p>
                  </
          td>
                  <
          td valign="top" width="0" style="border-right-style:none; border-right-width:medium; border-top-style:none; border-top-width:medium; border-bottom-style:none; border-bottom-width:medium">
                  </
          td>
                  <
          td valign="top" width="85%" height="100%" style="border-right-style:none; border-right-width:medium; border-top-style:none; border-top-width:medium; border-bottom-style:none; border-bottom-width:medium" bgcolor="#101010">
                  <
          div class="Section1">
                      <
          div align="center">
                          <
          table class="MsoNormalTable" id="table1" style="border-collapse: collapse" height="1735" cellSpacing="0" cellPadding="0" border="0">
                              <
          tr style="height: 1301.25pt">
                                  <
          td style="PADDING-RIGHT: 0cm; PADDING-LEFT: 0cm; PADDING-BOTTOM: 0cm; WIDTH: 360pt; PADDING-TOP: 0cm; HEIGHT: 1301.25pt" vAlign="top" width="480">
                                  <
          span style="color: white; font-family: Verdana; font-weight: 700">
                                  <
          br>REUNION 2005 ARRANGEMENTS – AT THE NEW VENUE </span>
                                  <
          p>
                                  <
          span style="FONT-SIZE: 10pt; COLOR: white; FONT-FAMILY: Verdana">
                                  (
          My apologies for the late posting but I’m not retired 
                                  yet 
          and I have just had a new system installed and 
                                  
          de-bugged)</span></p>
                                  
                                  
          td>
                              </
          tr>
                          </
          table>
                      </
          div>
                  </
          div>
                  <
          br>
                  <
          br>
                  <
          br>
                  </
          td>
              </
          tr>
          </
          table>
          <
          table>
              <
          tr align="center">
                  <
          td width=20%>&nbsp;</td>
                  <
          td width=80%>
                      <
          span  style="font-size:12;"><a href="index.htm">Home</a> | <a href="window.htm">Window</a> | <a href="50anniver.htm">50th Anniversary</a> | <a href="entry.htm">Entry History</a> | 
                      <
          a href="members.htm">Members</a> | <a href="news.htm">News Events</a> | <a href="photo.htm">Photo Gallery</a> | <a href="contacts.htm">Contacts</a> | <a href="links.htm">Links</a></span>
                  </
          td>
              </
          tr>
          </
          table>

          </
          body>

          </
          html

          Comment


          • #6
            ok, now point me which element has those "lines"? Which table...or which cell?
            KOR
            Offshore programming
            -*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*

            Comment


            • #7
              I need help

              Hey I recently added a floating menu to my church's web page but the menu is bigger than the screen so I cant reach the bottom with the floating menu is there a way to make it so i can scroll down before the menu goes down?
              thanks

              Comment


              • #8
                i presume you mean this:

                if the menu unfolds, it goes beyond your screenheight (downwards)
                and you cant click the bottom links?

                depends on the menu.
                The menu i use (HV Menu) does this automaticly, it never goes out of view.

                edit:
                May i ask what's the site adress; there are a *lot* of church site builders asking for script help lately.
                Whats going on?
                Last edited by barryke; Sep 11, 2005, 09:33 AM.

                Comment


                • #9
                  sure right now it is at a temporary page the address is http://fbcga.glorifyjesus.com/menu.html
                  tell me if there are any problems thanks
                  Last edited by palmq; Sep 13, 2005, 07:15 PM.

                  Comment


                  • #10
                    _____

                    _____
                    Last edited by palmq; Sep 20, 2005, 09:20 PM.

                    Comment

                    Working...
                    X