Since a GET will put parameters into the URL, you can just re-use the URL and change the page parameter. /?name=test&city=montreal&page=1 <- to change pages On Thu, Oct 16, 2014 at 4:55 PM, John Stoffel <john@stoffel.org> wrote:
Jacques> No. It's just more RESTful. I mainly build API with Dancer, Jacques> so I tend to follow a RESTful design.
I'm familiar with RESTful ideas, just haven't made it work for me yet, but I'm not a programmer by trade and this is my side hobby at points. So I really do appreciate all your help here.
Jacques> GET is used to list/query a collection and also retreive an object Jacques> POST is used to create an object into a collection. Jacques> PUT to update an object Jacques> DELETE to delete an object
Yup, makes sense.
Jacques> Since you are quering a collection, I'd suggest using GET.
Ok, so how would you save the query parameters so that each time you page through the results, they get submitted cleanly? I'm looking at various simple pagination libs now to take the next step here. And looking at the 'bootstrap' framework to make it look pretty.
I've got bigger problems down the line, since I will need to replace a big date library and calendar generation library written in PHP if I want to move forward for one existing DB I offer searches for. But that's not hear nor there. Let me get the basics working better first.
_______________________________________________ dancer-users mailing list dancer-users@dancer.pm http://lists.preshweb.co.uk/mailman/listinfo/dancer-users