PDA

View Full Version : I need a trick...


jonathaw
12-14-2004, 11:09 PM
Hello! I'm trying to do something very specific and I'm hoping someone might have an idea that would help. I am making a web photo gallery, and I have it set up so that you can edit the captions and name for each picture from a browser. I would also like to have the ability to change the order/ranking of the images. To do this, I made a drop down menu that allows you to choose a new rank for each picture. This is not only tedious, but it's hard to keep track of (you don't want to give 2 pictures the same rank). So, I would like a way of sorting the pictures by moving the filenames around, but I can't think of anything. Dragging and dropping, the way you move Photoshop layers around, would be nice, but is there any way to do something like that in an HTML form?
Hopefully that made some sense... Thanks!

fischerm
12-15-2004, 08:26 AM
The simplest thing I can think of is to have your script rename the files by appending a sequence to the front ie, 001_myphoto.jpg, 002_somepic.jpg. If two files have the same number on accident, the remainder of the filename would be used to determine the position.

I have seen some DHTML drag and drop ordering things, but I can't remember where, and I have no clue how.

jonathaw
12-15-2004, 09:42 AM
Yeah, I figured that might be the best solution. My goal was to have it so that once you upload a folder full of pics, you could do everything from a browser, but it looks like that's a bit lofty. Thanks!

abudhu
12-15-2004, 03:01 PM
Er, A Good DHTML place would be dynamicdrive.com