Code in db
Posted 26 October 2011 - 04:16 AM
is this a good idea, or should i use more conventional methods?? I want the ability that users submit their own gadgets.
Any suggestions welcome
Posted 26 October 2011 - 04:39 AM
As for your question:
How about let the user upload php files with user defined widgets. The database will only contain widget names associated with these files.
Posted 26 October 2011 - 04:26 PM
One more thing, how to store parametars(the time for timers or number for countrs....) for "gadgets"? I was planing for a few tables:
user_has_task (link table)
task_has_gadget (link table)
i was thinking to use a array for parameters of gadgets, the problem is where to put them, in what table?? Any iseas?
Posted 27 October 2011 - 01:51 AM
But I think you could also store a serialized array anywhere as a quick solution.
For the invocation of your widget/gadget with parameters you can user
This way you can use clean parameters on your methods. Please do NOT use on parameter for your widget as array.