开发者

redirection follow by post

just wonder how those air ticket booking website redirect the user to the airline booking website and then fill up(i suppose doing POST) the required information so that the users will land on the booking page with origin/destination/date selected?

Is the technique used is to o开发者_开发知识库pen up new browser window and do a ajax POST from there?

Thanks.


It can work like this: on air ticket booking system you have a html form pointing on certain airline booking website (by action parameter). If user submits data then data lands on airline booking website and this website proceed the request.

Usuallly people want to get back to the first site. This can be done by sending return url with request data. Of course there must be an API on the airline booking site to handle such url.

This is common mechanism when you do online payments, all kind of reservations, etc.

Not sure about your idea to use ajax calls. Simple html form is enough here. Note that also making ajax calls between different domains can be recognized as attempt to access the restricted url.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜