SitePoint Sponsor

User Tag List

Results 1 to 2 of 2
  1. #1
    SitePoint Member airabove's Avatar
    Join Date
    Mar 2006
    Stockholm, Sweden
    0 Post(s)
    0 Thread(s)

    Positioning with JavaScript

    I'm currently working on tweaking a colorpicker. The original colorpicker was made by Bjorge Dijkstra (, all credits belong to him

    Both my tweak and the original colorpicker have positioning problems. I'm no JavaScript genious (rarely use javascript at all) and I don't have a clue what is wrong, nor does Bjorge.

    Here is the colorpicker:
    Click on the box next to the field to open the colorpicker. As you can see it wont position at all.

    As the source is 500 lines+ I wont paste it here, it can be found here instead:
    The functions for positioning are marked.

    Hope that someone can bring some light on this issue!


    - Robert
    / Robert
    Airabove | Online portfolio

    Need a job done? Hire me!

  2. #2
    SitePoint Zealot sajjad's Avatar
    Join Date
    May 2005
    0 Post(s)
    0 Thread(s)
    dear i have check the code of javascript
    u can set the position of window i'll let u know how?
    go to function name function cp_show(event, obj, pal) in ur js file
    then in this function there are some parameter u can move the window according to ur need u can move window x/y axis.
    change these lines = ax + sx + 40; = ay + sy;

    to this line = ax + sx + 0; = ay + sy + 100;


Posting Permissions

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