简体   繁体   中英

RESTLET get parameters from HTML page

I want to develop an web application using RESTLET where i want to send arguments from jsp page. as far as server side code is concerned i have written resource classes in RESTLET.

But the main point is RESTLEt uses xml for communication, how can we communicate with RESTLET from jsp/html page.

RESTLET uses XML/JSON over HTTP and JSP/HTML are capable to do HTTP communication. XML will basically go inside the body of HTTP messages. So there are no compatibility issues, simply follow any tutorial to learn about sending HTTP requests from JSP to your REST server.

RESTlet can additionally return HTML (or any number of other formats) over HTTP if that is what you require to display, it could even be able to parse jsps to create the HTML with a little work. Basically at an initial level Restlet is largely format agnostic providing you with the HTTP protocol support. You communicate with the restlet server by passing HTTP requests in exactly the same way that you would from any HTML page to any other server generating the JSP. the exact details of how and when you need to do this will depend greatly on what you want to use it for, and how, do you want to use the traditional client server model or are you looking for AJAX queries?

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM