SitePoint Sponsor

User Tag List

Results 1 to 3 of 3

Hybrid View

  1. #1
    SitePoint Enthusiast
    Join Date
    May 2005
    Posts
    41
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Movable / Dragable Content

    Hey guys,

    I'm in a bit of a pickle - I'm really loving the user-friendlyness of sites that allow movable/drag-and-drop content in little containers that can be manipulated to their preferences.

    E.g:
    http://www.google.co.uk/ig?hl=en
    http://www.start.com/3/
    http://www.eurogamer.net/gamers
    MSN Spaces/Live.com
    ...etc

    I was wondering how to go about doing this - any useful tutorials/suggestions would be great, many thanks. Not too sure what to search for.

    Regards,
    jbcubed3

  2. #2
    SitePoint Member
    Join Date
    May 2007
    Posts
    4
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Hey. Check out this blog post I made on moving boxes. All you have to do is keep track of the mouse. When the user presses down, record the offsets of the mouse and then move the element with JavaScript by setting the CSS left and top properties. Make sure that the object is position: absolute;

    http://www.andrewpeace.com/2007/05/21/moving-boxes/

  3. #3
    SitePoint Addict CommanderZ's Avatar
    Join Date
    Apr 2006
    Location
    Czech Republic
    Posts
    236
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Try google - for example "javascript drag and drop". It will return a lot of links.


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
  •