41 users online (1 members and 40 guests)  


  Results 1 to 7 of 7

Related

  1. help positioning    Forum: HTML Forum
    Replies: 4
  2. More Positioning    Forum: HTML Forum
    Replies: 3
  3. OS differences in CSS positioning    Forum: CSS Forum
    Replies: 2
  4. Positioning Text    Forum: HTML Forum
    Replies: 0
  5. css positioning....??    Forum: CSS Forum
    Replies: 1
  1. #1
    JimJx's Avatar
    New User

    Status
    Offline
    Join Date
    Feb 2003
    Posts
    4

    Positioning no work :-(

    Hi all,

    I DL'd a script from DHTMLCentral.com and am having a prob getting a couple mods to work. I asked there but have yet to get a response after 3 days.

    Anyway, it is a sliding menu script and I am having 2 problems.

    1 -- I cannot get the menu to go all the way up to the top of the screen. I have tried every positioning trick that I can, and I can't get it to go there.

    2 -- I managed to get my logo to move with the menu, but the menu appears over it.

    I think these are related, but I cannot find it.

    You can check at http://www.rivercity.ish.biz/
    and then click on Test Site to see what I mean. All source code is available there.

    Thanks for any suggestions are very welcome.

    Jim

  2. #2
    QuietDean's Avatar
    Administrator

    Status
    Offline
    Join Date
    Oct 2000
    Location
    Bournemouth, UK
    Posts
    2,662
    open links.js and find -

    Code:
    //Variables to set
    between=28                //The pixel between the menus and the submenus
    mainheight=25                //The height of the mainmenus
    subheight=22                //The height of the submenus
    pxspeed=13                //The pixel speed of the animation
    timspeed=15                //The timer speed of the animation
    menuy=125                        //The top placement of the menu.
    menux=0                        //The left placement of the menu
    change menuy to suit, I found 10 was a good value.

    As to the image, there is a lot of code, where abouts is the image set?
    If one of our members helps you, please click the icon to add to their reputation!
    No support via email or private message - use the forums!
    Before you ask, have you Searched?

  3. #3
    JimJx's Avatar
    New User

    Status
    Offline
    Join Date
    Feb 2003
    Posts
    4
    Thanks for taking the time to check everything out..... I really appreciate it.

    I really don't know how I missed that menuy..... Been looking at code way too long I guess.

    The code for the menu and the image is set in slidemenu.js and it is almost all of the way down. The section is headed "Functions to write out the layers..."

    Once again, thanks for taking the time to look the code over,
    Jim

  4. #4
    QuietDean's Avatar
    Administrator

    Status
    Offline
    Join Date
    Oct 2000
    Location
    Bournemouth, UK
    Posts
    2,662
    Everything I try with the second problem seems to make it worse.

    As this point you may be better off experimenting yourself, or cantacting the author.
    If one of our members helps you, please click the icon to add to their reputation!
    No support via email or private message - use the forums!
    Before you ask, have you Searched?

  5. #5
    JimJx's Avatar
    New User

    Status
    Offline
    Join Date
    Feb 2003
    Posts
    4
    I know how you feel with everything that you tried only making matters worse. I feel like that is the boat I am in.

    Unfortunately, I contacted the author and have received no response. That is one reason I turned here. But I am going to keep experimenting on it to see if I can get it to work the way I want it too. It doesn't seem like it should be too difficult, it is just a little positioning and the original script works great, except I wanted the logo to scroll also. But now it has become more like an obsession.

    I am determined to find the answer and when I do, I will be sure to post it here so that you can see what is going on also.

    On another note, I really do appreciate you taking the time to look this over and give finding a solution a try. Thank you very much.

    Jim

  6. #6
    JimJx's Avatar
    New User

    Status
    Offline
    Join Date
    Feb 2003
    Posts
    4

    Talking Got it fixed.....

    Hello again Dean,

    After taking some time off from the project to clear my head, I basically started from scratch again on the mods.

    I don't know WHY it works now, only that it does in NN4 + 7, IE, and Opera.

    If you would like to check out the very beginning of the site and see the script working, you can go to http://rivercity.ish.biz/TestSite/index.html

    Thanks again for helping before, I appreciate all the effort you put in.
    Jim

    PS -- If you would like to see the code, just ask!
    Last edited by JimJx; 02-27-2003 at 08:43 PM.

  7. #7
    Doorknob's Avatar
    Super Newbie

    Status
    Offline
    Join Date
    Jun 2002
    Location
    Malaysia
    Posts
    316
    i use that script too, it's real cool. i also have another script that works like a navigation tree, just in case u want to give up on the topmenu

    btw u can also add background images to that menu

    *****code begins*****
    <style>
    <!--
    #foldheader{cursorointer;cursor:hand ; font-weight:bold ;
    list-style-image:url(fold.gif)}
    #foldinglist{list-style-image:url(list.gif)}
    //-->
    </style>
    <script language="JavaScript1.2">
    <!--

    //Smart Folding Menu tree- By Dynamic Drive (rewritten 03/03/02)
    //For full source code and more DHTML scripts, visit http://www.dynamicdrive.com
    //This credit MUST stay intact for use

    var head="display:''"
    img1=new Image()
    img1.src="fold.gif"
    img2=new Image()
    img2.src="open.gif"

    var ns6=document.getElementById&&!document.all
    var ie4=document.all&&navigator.userAgent.indexOf("Opera")==-1

    function checkcontained(e){
    var iscontained=0
    cur=ns6? e.target : event.srcElement
    i=0
    if (cur.id=="foldheader")
    iscontained=1
    else
    while (ns6&&cur.parentNode||(ie4&&cur.parentElement)){
    if (cur.id=="foldheader"||cur.id=="foldinglist"){
    iscontained=(cur.id=="foldheader")? 1 : 0
    break
    }
    cur=ns6? cur.parentNode : cur.parentElement
    }

    if (iscontained){
    var foldercontent=ns6? cur.nextSibling.nextSibling : cur.all.tags("UL")[0]
    if (foldercontent.style.display=="none"){
    foldercontent.style.display=""
    cur.style.listStyleImage="url(open.gif)"
    }
    else{
    foldercontent.style.display="none"
    cur.style.listStyleImage="url(fold.gif)"
    }
    }
    }

    if (ie4||ns6)
    document.onclick=checkcontained

    //-->
    </script>

    //add to body

    <font face="Verdana">

    <ul>
    <li id="foldheader">News</li>
    <ul id="foldinglist" style="display:none" style=&{head};>
    <li><a href="http://www.cnn.com">CNN</a></li>
    <li><a href="http://www.abcnews.com">ABC News</a></li>
    <li><a href="http://www.news.bbc.co.uk">BBC News</a></li>
    </ul>

    <li id="foldheader">Webmaster</li>
    <ul id="foldinglist" style="display:none" style=&{head};>
    <li><a href="http://www.dynamicdrive.com">Dynamic Drive</a></li>
    <li><a href="http://www.javascriptkit.com">JavaScript Kit</a></li>
    <li><a href="http://www.freewarejava.com">Freewarejava.com</a></li>
    </ul>

    <li id="foldheader">Nested Example</li>
    <ul id="foldinglist" style="display:none" style=&{head};>
    <li><a href="http://www.dynamicdrive.com">outer 1</a></li>
    <li><a href="http://www.dynamicdrive.com">outer 2</a></li>
    <li id="foldheader">Nested</li>
    <ul id="foldinglist" style="display:none" style=&{head};>
    <li><a href="http://www.dynamicdrive.com">nested 1</a></li>
    <li><a href="http://www.dynamicdrive.com">nested 2</a></li>
    </ul>
    <li><a href="http://www.dynamicdrive.com">outer 3</a></li>
    <li><a href="http://www.dynamicdrive.com">outer 4</a></li>
    </ul>
    </ul>

    </font>

    <p align="center"><font face="Arial" size="-2">Free DHTML scripts provided by<br>
    <a href="http://www.dynamicdrive.com">Dynamic Drive</a></font></p>

    //persistant tree
    <script language="JavaScript1.2">
    <!--

    function get_cookie(Name) {
    //Get cookie routine by Shelley Powers
    var search = Name + "="
    var returnvalue = "";
    if (document.cookie.length > 0) {
    offset = document.cookie.indexOf(search)
    // if cookie exists
    if (offset != -1) {
    offset += search.length
    // set index of beginning of value
    end = document.cookie.indexOf(";", offset);
    // set index of end of cookie value
    if (end == -1) end = document.cookie.length;
    returnvalue=unescape(document.cookie.substring(offset, end))
    }
    }
    return returnvalue;
    }

    var foldercontentarray=new Array()
    var c=0

    if (ns6){
    for (i=0;i<document.getElementsByTagName("UL").length;i++){
    if (document.getElementsByTagName("UL")[i].id=="foldinglist"){
    foldercontentarray[c]=document.getElementsByTagName("UL")[i]
    c++
    }
    }
    }

    if (get_cookie(window.location.pathname) != ''){
    var openresults=get_cookie(window.location.pathname).split(" ")
    for (i=0 ; i < openresults.length ; i++){
    if (ns6){
    foldercontentarray[openresults[i]].style.display=''
    foldercontentarray[openresults[i]].previousSibling.previousSibling.style.listStyleImage="url(open.gif)"
    }
    else{
    foldinglist[openresults[i]].style.display=''
    document.all[foldinglist[openresults[i]].sourceIndex -1].style.listStyleImage="url(open.gif)"
    }
    }
    }

    if (ns6||ie4){
    var nodelength=ns6? c-1 : foldinglist.length-1
    var nodes=new Array(nodelength)
    var openones=''
    }

    function checkit(){
    for (i=0 ; i <= nodelength ; i++){
    if ((ns6&&foldercontentarray[i].style.display=='')||(ie4&&foldinglist[i].style.display==''))
    openones=openones + " " + i
    }
    document.cookie=window.location.pathname+"="+openones
    }

    if (ns6||ie4)
    window.onunload=checkit
    //-->
    </script>
    *****code ends*****



Tags for this Thread