In my wp widget, $instance has an attribute called order which will the listing order of libraries/services. I'd like to store a multidimensional associative array that will hold the id of each location/service, its type (i.e. if it's a location or a service), and it's name. I'd like it to look something like this:

The user can choose what locations/services s/he wants to display with a multi-select dropdown. Whenever the user selects a library/service, it automatically populates select.select-hours-order. The user can then click the + button of a.add-location-service to add it to ul.location-service-order.

From there, I'd like to save the lis of ul.location-service-order with the attributes I specified above.

1 Answer
1

I ended up using a workaround to solve this problem. Instead of attempting to store a multidimensional array as described above, I instead store a simple array of values created by combining the type with the id.