PDA

View Full Version : Javascript PHP Movable Images



onestopplay
08-30-2009, 02:02 AM
THIS IS FOR PEOPLE WHO KNOW PHP AND JAVASCRIPT:
So here's what I want to do.
I want a background Image of a room. A basic blank room with nothing in it.
Let's call that: room.jpg
Users will be able to buy stuff from the store. I will have all the user's items in a PHP database, for example:
userid | item | room
1 | computer.png | bedroom
2 | tv.png | noroom
If it has the `room` as 'noroom', that means it will be in there "Stuff Pile" where I want to use Javascript to DRAG the item into a room. Then the database changes `room` to the room and somehow marks the coordinates in the table so that the next time the user comes to that room, the item is in the exact place. Also, you can drag the item to a different place in the room and also back in the "stuff" pile. That would just change the coordinates I guess.
Is this possible? And how would I do it? I know PHP well, and am sort of familiar with Javascript, but am not too familiar with it.
So really I just need the Javascript and how to set up the table in MySQL.
Anyone who helps me out with this - THANK YOU SO SO SO MUCH!!!!!!! :)

thenajsays
08-31-2009, 12:33 PM
http://www.dynamicdrive.com/forums/showthread.php?t=47945