Results 1 to 17 of 17
-
Cookies Tutorial Part 1 - Introduction to Cookies
Introduction
Cookies are a technology which can be easily and simply used by a Webmaster to achieve a great many very useful tasks when creating websites. Although cookies are well known to users, many people are not really sure what they are used for, and a large amount of webmasters don't realise the possibilities open to them when they use cookies. Others have been put off, thinking that they must be difficult to use, but in reality, cookies can be set and used by a simple command in most scripting languages. In this tutorial I'll cover setting and using cookies in PHP, JavaScript and ASP, as well as giving some basic information on how cookies can be used.
-
12-07-2011 05:29 AM # ADSAdvertise here Circuit advertisement
- Join Date
- My Birthday
- Posts
- Million and counting
-
Re: Cookies Tutorial Part 1 - Introduction to Cookies
What Is A Cookie?
Apart from being a type of biscuit, a cookie is also a very useful piece of technology for use on the web. One of the problems which many websites need to overcome is that there is no way of directly finding out who is on a website. Although many details about the user (such as their browser, IP address and operating system) are available, the use of dynamic IP addresses (which change every time the user logs on) and IP address sharing (so that many people share the same IP) mean that there is no reliable way of recognising a particular user when they re-visit a website.
Cookies overcome this problem. They basically give the website owner the opportunity to store a little piece of information on a user's computer which they can then retrieve at a later date. Cookies are just tiny text files (only up to 4Kb in size) and a website can write them to the user's computer via the web browser. The same website can then request the cookie from the user and, if it exists, the value stored will be reported back to the website. The cookie can persist on the user's computer, staying there if the browser is closed, the computer is switched off and if the internet connection is changed.
-
Re: Cookies Tutorial Part 1 - Introduction to Cookies
What Use Is A Cookie?
So why would anyone want to store 4000 characters of text on a user's computer? It isn't enough to put anything really worthwhile on there! The power of the cookie, though, is to recognise a site visitor over and over again. To give just a few uses of cookies:
Many portals and search engines use them to provide customized pages and results to their users, allowing such features as 'My Yahoo' etc.
Many websites use cookies to log their users in automatically. By storing a few pieces of user information they can automatically authenticate the user's details and use them to save the user time when they log in>/li>
Visitor tracking and statistics systems often use them to track visitors. By assigning the visitor a cookie, they will not be counted more than once, so accurate unique visitor statistics can be obtained. Also, if a user has a unique cookie the system can 'follow' them through a website, showing the webmaster exactly where the visitor has been, and in what order.
ahmadatta2009 - ahmad paolo
-
Re: Cookies Tutorial Part 1 - Introduction to Cookies
Using Cookies
A cookie is a very basic data file. It has a name and a value and also stores the address of websites which are allowed to access it and an expiry time. Basically, a website will set a cookie and give it a name and value. This name is used by the website to refer to it, and no other website can access the cookie, even if they know it's name. The name should be unique to the website, but it doesn't matter if it clashes with the name of a cookie from another website.
The cookie (as mentioned before) can only store up to 4000 characters of data. This is enough to store lots of information about a user so if, for example, you wanted to store the user preferences for a search engine (much like Google does), you could simply list the preferences in the cookie. If you wanted to store more data, you would have to store a unique ID in the cookie, which matched up with a database record, and you could th
en access the user's data this way.
To retrieve data, the website simply has to request if the user has a cookie with a particular name. If the user does, the value is returned to the script and it can be dealt with however the website owner chooses (for example a name stored in a cookie could be returned, a user ID could be loaded from a database, or a record could be made of a user visiting a site).
Every cookie is assigned an expiry date and time. It is up to the website owner to decide how long the cookie should exist for. Many owners may just choose to set the cookie for an hour, meaning it is only available for the user's single session. This is common in visitor tracking. Other cookies could be set for much longer. Maybe a week or a month (often used for affiliate program tracking) or even several years (often used for user preferences).
ahmadatta2009 - ahmad paolo
-
Re: Cookies Tutorial Part 1 - Introduction to Cookies
Cookie Security
Despite much worrying in the news a few years ago, cookies pose no real danger to users. Unless they are really worried about themselves being recognised by a website, they are harmless. The browser actually writes and reads cookies from the computer when requested to by a website, so a malicious website cannot damage the computer.
For webmasters, there are some security concerns. When the cookie is set, the domain(s) which can access it are set. Usually this is just the website who set the cookie. This makes them relatively secure, as you can be sure that your competitor cannot load your cookie from one of your visitors' computers (they cannot even find out if it exisits).
One major security problem with cookies, though, is that they can easily be read by anyone using the computer. They are just a simple text file, so you should not under any circumstances store passwords in cookies. A common way to log people in automatically is to store an encrypted version of their password, which can then be matched with an encrypted version on the server. Another method is to store a unique ID and a unique validation number on the user's system. This is then referenced in a database to the user's account. This way, no actual details are stored and a malicious user cannot simply guess users' IDs (as there is the validation number).
ahmadatta2009 - ahmad paolo
-
Re: Cookies Tutorial Part 1 - Introduction to Cookies
The End .......
ahmadatta2009 - ahmad paolo
i hope you are enjoy with me ))))))))))
and enjoy with my lesson )))))))
-
08-25-2012, 06:11 PM #7
Banned
This user has no status.I am:----
- Join Date
- Aug 2012
- Posts
- 463
- MTV$
- 1,116
Re: Cookies Tutorial Part 1 - Introduction to Cookies
i think Introduction Cookies are a technology which can be easily and simply used by a Webmaster to achieve a great many very useful tasks when creating websites.so it is very best site.
-
08-28-2012, 08:30 PM #8
MTV Senior
is www.investorposts.comI am:----
- Join Date
- Jul 2012
- Posts
- 1,798
- MTV$
- 367
Re: Cookies Tutorial Part 1 - Introduction to Cookies
wow what a great information that you provide us .Really i didn't know about it but now i really came to know about cookies and it mean it is used by webmaster to achieve a great many useful task .It really proves that it is very important in browser and i really love to know about it.so,thank you.
-
09-01-2012, 09:42 PM #9
MTV Regular
This user has no status.I am:----
- Join Date
- Aug 2012
- Posts
- 908
- MTV$
- 107
Re: Cookies Tutorial Part 1 - Introduction to Cookies
It takes me about 15 minutes to read all your articles ahmadatta. Thanks for good sharing. I have one question here, why when I play poker in Texas holdem poker in face book, after a while my browser move slowly and sometimes it not moving (not responding). After I click here and there, a message appear asking me to clear cookies from tools option. Why is it? Is it really cause by the cookies?
-
09-09-2012, 05:50 PM #10
Banned
is who wander are lost!!!I am:
- Join Date
- Sep 2012
- Posts
- 1,704
- MTV$
- 5,031
Re: Cookies Tutorial Part 1 - Introduction to Cookies
t takes me about 15 minutes to read all your articles ahmadatta. Thanks for good sharing. I have one question here, why when I play poker in Texas holdem poker in face book, after a while my browser move slowly and sometimes it not moving (not responding).
-
09-13-2012, 09:04 AM #11
MTV Regular
This user has no status.I am:----
- Join Date
- Sep 2012
- Posts
- 349
- MTV$
- 8
Re: Cookies Tutorial Part 1 - Introduction to Cookies
i think Introduction Cookies are a technology which can be easily and simply used by a Webmaster to achieve a great many very useful tasks when creating websites.so it is very best site. The browser actually writes and reads cookies from the computer when requested to by a website, so a malicious website cannot damage the computer.
-
09-13-2012, 08:44 PM #12
Banned
This user has no status.I am:----
- Join Date
- Sep 2012
- Posts
- 1,129
- MTV$
- 3,336
Re: Cookies Tutorial Part 1 - Introduction to Cookies
i think Introduction Cookies are a technology which can be easily and simply used by a Webmaster to achieve a great many very useful tasks when creating websites.so it is very best site. The browser actually writes and reads cookies from the computer when requested to by a websitetakes me about 15 minutes to read all your articles ahmadatta. Thanks for good sharing. I have one question here, why when I play poker in Texas holdem poker in face book........
-
10-04-2012, 11:28 AM #13
Banned
is is banned for copy pastingI am:----
- Join Date
- Oct 2012
- Posts
- 340
- MTV$
- 1,000
Re: Cookies Tutorial Part 1 - Introduction to Cookies
Cookies are a technology which can be easily and simply used by a Webmaster to achieve a great many very useful tasks when creating websites. Although cookies are well known to users, many people are not really sure what they are used for, and a large amount of webmasters don't realise the possibilities open to them when they use cookies. Others have been put off, thinking that they must be difficult to use, but in reality, cookies can be set and used by a simple command in most scripting languages. In this tutorial I'll cover setting and using cookies in PHP, JavaScript and ASP, as well as giving some basic information on how cookies can be used.
-
10-07-2012, 01:58 PM #14
Banned
This user has no status.I am:----
- Join Date
- Aug 2012
- Posts
- 383
- MTV$
- 980
Re: Cookies Tutorial Part 1 - Introduction to Cookies
t takes me about 15 minutes to read all your articles ahmadatta.i think Introduction Cookies are a technology which can be easily and simply used by a Webmaster to achieve a great many very useful tasks when creating websites.
-
10-10-2012, 09:58 PM #15
MTV Regular
This user has no status.I am:
- Join Date
- Sep 2012
- Posts
- 493
- MTV$
- -37
Re: Cookies Tutorial Part 1 - Introduction to Cookies
i think Introduction Cookies are a technology which can be easily and simply used by a Webmaster to achieve a great many very useful tasks when creating websites.so it is very best site. The browser actually writes and reads cookies from the computer when requested to by a website, so a malicious website cannot damage the computer.
-
12-02-2012, 03:40 PM #16
MTV Regular
This user has no status.I am:----
- Join Date
- Nov 2012
- Posts
- 323
- MTV$
- 863
Re: Cookies Tutorial Part 1 - Introduction to Cookies
Cookies carries small piece of information on each and every website whenever it is loaded on site or in the global network. In the Tutorial consisting of the Introduction part about cookies discusses about the basics of cookies.
-
02-15-2013, 07:19 AM #17
MTV Newbie
This user has no status.I am:----
- Join Date
- Feb 2013
- Posts
- 12
- MTV$
- 36
Re: Cookies Tutorial Part 1 - Introduction to Cookies
Cookies are used in web application to store information about the users who have used website. The cookie are physically a text file that stores information regarding the user identification. For example if the user has visited a web site the web site can store text file on users computer if the user comes to web site again to use that web site can refer to the cookie for making things easier.
Thread Information
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)































Reply With Quote



Bookmarks