If you have seen igoogle, you will know what i am doing!
The idea is that it saves the co-ordinates of the box that you can move into two text files : usercoord.txt-x axis & usercoord2.txt-y axis! can anyone tell me how i can load the coordinates back, from the text files?, into the page to position the box? Help much appreciated.
P.S website link http://howscienceworks.x10hosting.com/phpwork/drag_and_drop_simple.html
Please help me, i am new to Php but am reasonable at html.

Recommended Answers

All 2 Replies

Thecodingbee,

As I'm sure you realise, you need to store all user configuration settings somewhere - the question is where?

You could use a cookie, which would tie a particular user configuration to a particular computer/logon. Not particularly useful for many people.

The other main option is to store settings server-side. You could tie settings to ip addresses but that's no more useful than using a cookie (and for dialup users no use at all). The solution is to introduce a logon schema, such that the server-side code (your php) knows which settings to retrieve from the database on each occasion.

If you follow this approach, then you will need to use something like mysql (often included in php-enabled hosting packages). I've not done a logon schema from scratch but am sure there are off-the-peg downloadable examples out there. Alternatively use a framework such as zen or cake, which are tricky to learn but have lots of goodies either built-in or available as third-party extensions.

Good luck.

Airshow

Member Avatar for diafol

Your website is using JS I take it? If so, ask in the Javascript forum unless you want to go server-side/ajax. At which technology are you aiming?

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.