Mattingly "AI & Prompt Design: The Basics of Prompt Design"
Post and get methods
1.
2. Disclaimer: This presentation is prepared by trainees of
baabtra as a part of mentoring program. This is not official
document of baabtra –Mentoring Partner
Baabtra-Mentoring Partner is the mentoring division of baabte System Technologies Pvt .
Ltd
5. Muhammed Noufal V T
muhammednoufalvt@gmail.c
om
www.facebook.com/vtnoufa
lvt
twitter.com/noufalurnappy
in.linkedin.com/pub/muham
med-noufal
9744003056
6. Request-Response Cycle
request
Web
Browser
URL
HTML, images, files
response
Web
Server
• When enter an address (URL) into
the address bar of a web browser or
click on a link, we generate a
request for a file
• The request is routed to a Web
server, which sends back a
7. Get Method
• Send parameters in the URL
http://localhost:8081/fstpro/sec.jsp?na
me=sonia
• sec.jsp
<%session.setAttribute("name",request.getP
arameter("name"));
session.setAttribute("age",request.getParam
eter("age"));
session.setAttribute("sex",request.getParam
eter("sex"));%>
8.
9. HTML Forms
• Send parameters via forms
<FORM ACTION="printname.jsp" METHOD="get">
<INPUT TYPE="text" NAME="firstname" SIZE=40>
<INPUT TYPE="submit" value="Print Name">
</FORM>
• Access these with the request object
<%
String name = request.getParameter("firstname");
...
%>
10. Post Method
• Post attaches parameter values to request
• A POST on the other hand will (typically)
send the information through a socket
back to the webserver and it won't show
up in the URL bar.
• You can send much more information to
the server this way - and it's not restricted
to textual data either.
11.
12.
13.
14.
15.
16.
17. Get & Post
• Get puts parameters and values in the URL
page.jsp?param1=value1¶m2=value2&...
– Send with a link or in a form with method="get"
• Post attaches parameters to request
– Send in a form with method="post“
GET
POST
• Parameters
encoded in URL
request
• data limit URL length no limit
• Bookmarks
yes
no
attached to
18. Contact Us
Emarald Mall (Big Bazar Building)
Mavoor Road, Kozhikode,
Kerala, India.
Ph: + 91 – 495 40 25 550
Start up Village
Eranakulam,
Kerala, India.
Email: info@baabtra.com
NC Complex, Near Bus Stand
Mukkam, Kozhikode,
Kerala, India.
Ph: + 91 – 495 40 25 550