Answer the question
In order to leave comments, you need to log in
PHP "single data" storage - where?
I have the following data that I don't know where to store:
Form fields that should be displayed on the user page and set in the admin panel.
Here is the moment, where to write them down after the administrator has created a certain form?
Here, as it were, it is necessary to store an array, perhaps, with the form:
array( [type => label], [type => label], [type => label] )
Is it logical to use NoSQL solutions here?
Answer the question
In order to leave comments, you need to log in
IMHO, I would keep it in the json line in the file, parse it from there and decode it into an array. No more is needed here.
I'm not very strong in PHP, but I don't see the point in nosql.
Saved to the database and then generate your form, it's another matter if each user has their own form and there are a lot of such requests, then you can think about it.
The very first option that came to mind is to export the data to a php file using the var_export function. Other options are csv (eg fputcsv), json (json_encode) files. Or you can serialize with serialize. This is in case there is not much data and it makes no sense to start a database.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question