Start Building Professional
Web Apps Today


 
Categories Question details Back To List
Question  posted by maxx2097 on Sep 14, 2009 09:53
open dhtmlx forum
dhtmlxgrid and file uploads (vault?)

Hi there!

I got the following use-case: I need to edit data in a grid (no problem so far) and save the corresponding XML. Each row should have an upload possibility for an image and a PDF-file (these will be stored in the filesystem and i want to keep a reference to the uploaded files in the XML).

So what would be the best way to realize that?

Many thanks

Maxx
Answer posted by Alex (support) on Sep 15, 2009 05:47

Hello,

>> I got the following use-case: I need to edit data in a grid (no problem so far) and save the corresponding XML

Grid can be serialized by serialize() method. The sample is dhtmlxGrid/samples/17_serialization/01_pro_serialize.html

>> Each row should have an upload possibility for an image and a PDF-file (these will be stored in the filesystem and i want to keep a reference to the uploaded files in the XML)

The reference to uploaded file can be placed into the userdata tag.

grid.setUserData(rowId,name,value)

Userdata is serialized:

grid.setSerializationLevel(true);