I have a folder which has file and folders in it and so on. How do i store the same structure in mongodb using PHP? I want the index to be the root folder's name and the structure to resemble the folder structure. Also i want the file data to be stored as it is.
For example :
{
"Folder1":{
"Folder2":{ File1:{}
}
}
}