[phpBB Debug] PHP Notice: in file /includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Notice: in file /includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
www.dhtmlgoodies.com • View topic - Folder tree with drag and drop: Add item
Page 1 of 1

Folder tree with drag and drop: Add item

PostPosted: Thu Jan 11, 2007 10:19 am
by rudolff

PostPosted: Wed Jan 31, 2007 9:47 pm
by Arakrys
You could start with adding an extra 'neutral' item at the bottom of the tree, and raise an alarm (so to speak) if you detect it has been dropped (by the node number), then you might update the entire tree, maybe add a (div) popup to ask for the new name.

But I have a similar question on how to implement something like that. If this was mentioned earlier in the forum please provide me with a searchword or the link - I am slowly going through this forum now.

The drag and drop menu is very inspiring.

I would like to offer several objects on the page that can be dragged into the tree. I want to enhance the script so it knows what objects can "hang" where.

For now I am thinking of simply making "menu header" items and "menu item" items. Which is pretty daft as it can already be done by serverside logic (I'm into PHP too). I was imagining to show them in a box from which it might be dragged to the tree. Later on I was even thinking (vertical) flow diagrams, photo albums, but especially information organizing. I already have an expanding form (pretty basic now) on each branch, which uses the same ID as the node digit (parameters posted though ajax via "save icon").
(the forms belong to the LI above it)
Image

One way I can imagine doing this is using the amazing double tree presented here this week, and detect the presence of the foreign branches of tree 2 in the left tree, on dropping and/or on data submission.

Is this a feasible approach, or can someone think of a better way?

Has anybody thought of a clear "handle" image in stead of a folder? Maybe in combination with a custom pointer in stead of the hand?

Is there some maximum size known to the drag and drop menu?
(I have a product list of 8000 items in mind)

Even more questions: how to make a 'copy item/branch' option, so you drag with the 'copy' handle or maybe press the 'copy' button and then the old node is left?
Hm, this bites a bit with the general idea doesn't it?
[/img]

PostPosted: Tue Feb 06, 2007 2:34 pm
by Arakrys