Making an AJAX endpoint as an Omeka Plugin


I have set up my items page to allow in-place editing of certain metadata elements under specific circumstances. My JS is also set up - it picks up the parameters it needs to send to the server for further processing.

What I am having trouble with is figuring out how to set up the backend as an Omeka plugin. I.e. how to create the bare minimum plugin, which will pick up the parameters from the AJAX call at a given URL and then use Omeka's db functions to finish the job.

Your tips will be greatly appreciated.

All best,

Some additional background information might help.

Which page, exactly, have you set up in-place editing for? It sounds like it might be the public-facing items/show page, modified by changing the theme... is that right?

thanks, patrick. i figured this one out. yes, it was the public items/show page of a custom theme.

i was just confused about the MVC set up for the ajax endpoint, but in the end i got it right. basically, i needed to set up an empty views/shared/index/index.php in my ajax client plugin and then do all the backend processing in controllers/IndexController.php.

all best,