I basically want to write a POST request in sinatra that has to take 3 links at the same time and process it in someway.

post account/:id/

Here id represents the user id...what will come after

:id/

so that I can capture 3 links like link1, link2, link3 and then do something with it inside the POST request?

有帮助吗?

解决方案

Doing this with interpolated path variables is very inflexible. Rather do it by accepting a posted array of parameters

If you absolutely have to do this; the syntax is something like

post 'account/:id/link1/:link1/link2/:link2/link3/:link3'
许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top