Results 1 to 1 of 1

Thread: Script not compatible to all link types?

  1. #1
    Join Date
    Jul 2010
    Posts
    5
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Exclamation Script not compatible to all link types?

    ***** Problem resolved through use of different script, but feel free to provide an answer on this one if you can, would still be useful *****



    1) Script Title: Drop down/ Overlapping Content script

    2) Script URL (on DD): http://www.dynamicdrive.com/dynamici...lapcontent.htm

    3) Describe problem: I have a large image of a tour map through a historic section of a town, the map has about 15 locations that are "stops" on the tour route designated by #'s in small circles. - I am trying to create a "content rich" div pop-up on mouse over or click of each circle, thus I am having to use an image map to build the links. - This script is perfect when used on a text link except that I need to manually tell the script the position the DIV needs to pop up, not the preset positions the script uses "top-left" :bottom-right" etc. etc.

    The problem being created is that the script when in executes using the links of an image map relates "top-left" "bottom-right" and the other preset positions in relation to the IMAGE used in the image map, not the hot spot the link is located at. - I am not a coder, but I did look at the JS code and noticed line 38 through 41 APPEARS to indicate that a user value can somehow be passed to the script for manual positioning:

    Code:
    var horizontaloffset=(subobj.dropposition[0]=="left")? -(subobj.offsetWidth-anchorobj.offsetWidth) : 0 //calculate user added horizontal offset
    
    var verticaloffset=(subobj.dropposition[1]=="top")? -subobj.offsetHeight : anchorobj.offsetHeight //calculate user added vertical offset
    
    subobj.style.left=this.getposOffset(anchorobj, "offsetLeft") + horizontaloffset + "px"
    subobj.style.top=this.getposOffset(anchorobj, "offsetTop")+verticaloffset+"px"
    Am I misunderstanding the sections above? and in any case, is there anything someone can do to help get this script to accept a "top" and "left" variable to manually position the DIV's?

    Thanks in advance,

    Robert
    Last edited by ARCLite Studio; 11-06-2011 at 04:23 AM. Reason: Resolved through alternate DD script

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •