Describe how to implement Cookies for Web python.
Answer / chaitanya
A cookie is an arbitrary string of characters that uniquely identify a session.
Each cookie is specific to one Web site and one user.
The Cookie module defines classes for abstracting the concept of cookies. It contains following method to creates cookie
Cookie.SimpleCookie([input])
Cookie.SerialCookie([input]
Cookie.SmartCookie([input])
for instance following code creates a new cookie ck-
import Cookie
ck= Cookie.SimpleCookie ( x )
| Is This Answer Correct ? | 0 Yes | 0 No |
What is the use of globals() function in python?
Is python zero indexed?
What data types does python support?
What is an abstract class in python?
What is the python decorator?
Explain about pdb module in python?
What is kwargs in python?
What is python identifiers?
How do you disconnect from the database?
What is Python Set?
What is the best flask or Django
How to create dynamic array in python?