Programming Basics

  Home arrow Programming Basics arrow Cookies in PHP
PROGRAMMING BASICS

Cookies in PHP
By: bluephoenix
  • Search For More Articles!
  • Disclaimer
  • Author Terms
  • Rating: 3 stars3 stars3 stars3 stars3 stars / 57
    2004-01-27

    Table of Contents:
  • Cookies in PHP
  • Basic Cookie
  • Cookie Attributes
  • Words Of Caution

  •  
     

    SEARCH CODEWALKERS

    Cookies in PHP


    (Page 1 of 4 )

    For those new to web development and 'how things work', cookies can be a very confusing matter. In this tutorial, Timothy gives you an overview of cookies to help you understand how they work.

    A cookie is a small bit of information stored on a viewer's computer by his or her web browser by request from a web page. The information is constantly passed in HTTP headers between the browser and web server; the browser sends the current cookie as part of its request to the server and the server sends updates to the data back to the user as part of its response.

    The size of a cookie depends on the browser but in general should not exceed 1K (1,024 bytes). The information can really be anything... it can be a name, the number of visits to the site, web based shopping cart information, personal viewing preferences or anything else that can be used to help provide customized content to the user.

    In addition to the information it stores, each cookie has a set of attributes: an expiration date, a valid domain, a valid domain path and an optional security flag. These attributes help ensure the browser sends the correct cookie when a request is made to a server.

    More Programming Basics Articles
    More By bluephoenix

    blog comments powered by Disqus

    PROGRAMMING BASICS ARTICLES

    - The Transliteration Operator in Perl
    - Perl String Processing Functions
    - Perl String Processing
    - Control Flow Constructs: Loops Conclusion
    - Loop Control Constructs
    - Control Flow Constructs: the For and Foreach...
    - Loops and Control Flow Constructs
    - Expression Modifiers for Perl Control Flow C...
    - Logical Operators and Control Flow Constructs
    - Comparing Strings with Control Flow Construc...
    - Perl Operators and Control Flow Constructs
    - Control Flow Constructs
    - More Time Manipulation with PHP
    - Validating and Manipulating Dates with PHP
    - Using the Date Constructor in PHP

    Developer Shed Affiliates

     



    © 2003-2018 by Developer Shed. All rights reserved. DS Cluster - Follow our Sitemap