Solved

Get WebPage that need a cookie.

Posted on 2003-11-10
5
226 Views
Last Modified: 2010-04-05
How do I retrieve a page (with delphi) that needs a cookie? I need this to make programs that automatically get new email status.

thanks in advance.
0
Comment
Question by:dyancer
  • 2
5 Comments
 
LVL 6

Accepted Solution

by:
GloomyFriar earned 63 total points
ID: 9715698
You need to send your cookies in the html header:

"Set-Cookie: B=5; A=4;\r\n"
0
 
LVL 6

Expert Comment

by:GloomyFriar
ID: 9715806
Ooops. Sorry. "Set-cookie" you can receive from server.

To set cookies in request you need to send to server something like that:

GET /100.xhtml?www.alonewolfsoft.narod.ru/SOFT/gchn.rar HTTP/1.1
Host: narod.yandex.ru
Accept: */*
Referer: http://download.ru/russian/sp/13413.htm
Cookie: yandexuid=1803220281066827206
User-Agent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.0)
0
 
LVL 26

Assisted Solution

by:EddieShipman
EddieShipman earned 62 total points
ID: 9737241
Your cookie, being as it is fromn an email server, may not always be the same. What you should do
is login using idHTTP and catch the cookie with a idCookieManager and then send it along with
your response. I don't have time to build an example for you but that is how I would do it.
0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Delphi - replicating a form 8 82
When i run adoquery my application freezes 26 179
Dynamically Created Query 3 62
DBGrid or StringGrid ? 6 105
Introduction The parallel port is a very commonly known port, it was widely used to connect a printer to the PC, if you look at the back of your computer, for those who don't have newer computers, there will be a port with 25 pins and a small print…
In this tutorial I will show you how to use the Windows Speech API in Delphi. I will only cover basic functions such as text to speech and controlling the speed of the speech. SAPI Installation First you need to install the SAPI type library, th…
Finds all prime numbers in a range requested and places them in a public primes() array. I've demostrated a template size of 30 (2 * 3 * 5) but larger templates can be built such 210  (2 * 3 * 5 * 7) or 2310  (2 * 3 * 5 * 7 * 11). The larger templa…

828 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question