The HTTP protocol is by definition stateless, meaning that it has no mechanism for "remembering" data from one interaction to the next. (a) Suggest a means by which you can preserve state between two HTTP calls. For example, you may send the user a page of books and prices matching a user's query, and you want to avoid having to look up the price of each book again once the user chooses one to
purchase. (b) Suggest a means by which you can preserve some notion of state between two web accesses many days apart. For example, the user may prefer prices quoted in euros instead of dollars, and you want to present prices in the preferred currency next time without asking the user.
What will be an ideal response?
State
can
be
preserved
on
the
client
or
server
end.
On
the
server
end,
saving
state
takes
space,
especially
if
some
interactions
are
broken
(the
user
does
not
complete
the
purchase,
perhaps
just
browsing
to
collect
prices).
On
the
client
end,
the
state
information
is
subject
to
malicious
or
nonmalicious
modification
and
loss.
Also,
there
is
the
difficulty
that
a
"user"
is
not
synonymous
with
a
single
workstation:
the
workstation
may
be
shared,
and
the
user
may
access
two
different
workstations.
Most
sites
opt
to
store
state
on
the
client's
machine,
using
encryption
and
proprietary
formats
to
limit
the
amount
of
modification
a
user
can
do.
You might also like to view...
A ________ is a 256-color graphic file format that uses lossless compression and is best for simple images with large areas of solid color
A) TIF B) GIF C) JPG D) BMP
A company is receiving a large number of laptop theft reports in the corporate buildings. Which of the following is the MOST cost-efficient way to discourage theft of laptops?
A. A CCTV system B. A cable lock C. A badge reader D. A retina scanner