473,395 Members | 1,968 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

resetting curl's cookie jar

If you want cURL to deal with cookies for you, you need to give cURL
the name of a file you'd like to serve as the "cookie jar". This can
be done with CURLOPT_COOKIEFILE and CURLOPT_COOKIEJAR.

My question is... what if I want to empty the cookie jar? How might
I do that? Is it possible?
Jun 27 '08 #1
2 3404
yawnmoth schreef:
If you want cURL to deal with cookies for you, you need to give cURL
the name of a file you'd like to serve as the "cookie jar". This can
be done with CURLOPT_COOKIEFILE and CURLOPT_COOKIEJAR.

My question is... what if I want to empty the cookie jar? How might
I do that? Is it possible?
Hi yawnmoth,

Did you try simply making the file empty?

Regards,
Erwin Moller
Jun 27 '08 #2
yawnmoth wrote:
If you want cURL to deal with cookies for you, you need to give cURL
the name of a file you'd like to serve as the "cookie jar". This can
be done with CURLOPT_COOKIEFILE and CURLOPT_COOKIEJAR.

My question is... what if I want to empty the cookie jar? How might
I do that? Is it possible?
The easiest way would be to erase the files. Alternatively, you could
clear the fields in your CURL options.

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
js*******@attglobal.net
==================

Jun 27 '08 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Phil Powell | last post by:
I am having trouble retrieving URLs using curl for PHP whereby the URL requires a cookie to produce proper data. I wrote a wrapper class called Timer that will time the execution/download of a...
9
by: Dave Martin | last post by:
I've successfully used CURL to maneuver around and through sites but a new site I've been trying to work with has got me stumped. To retrieve the data I'm trying to get a login is required. If...
12
by: niftyhawk | last post by:
Hi All, I have a small curl function which spits out a bunch of headers. The CURL Code is: $url="http://blahblah.com?Logon"; $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, $url);...
3
by: Leo | last post by:
Can anyone help or offer some explanation with this problem: I'm trying to do a POST from one of my PHP pages, to another page on my site using curl. To maintain the session I'm sending the...
0
by: nfhm2k | last post by:
I've been trying to find a solution to this for quite some time now... I even took a look at existing scripts... Including this one......
9
by: devranger | last post by:
I am using the below CURL Function and can not figure out why it is not retruning the results from the post. Can anyone take a look and tell me what I may be doing wrong? I am just not seeing...
3
by: JDS | last post by:
So, I'd like to create the following scenario: 1) Use cURL library within PHP (cURL + "Cookie Jar", et.al) to create a virtual browser session that "logs in" to a remote site. (For example: ...
3
by: Sarah | last post by:
I was wondering if someone might be able to help me with this issue. I have a feeling this has something to do with my host's server settings as I used to be able to get CURL to follow redirects by...
3
by: buzz2050 | last post by:
Hi all, I am using cURL for the first time. I need to login to a site and my cURL code to do the same is as follows: //curlScript.php <?php function getContent($url, $referer,...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.