Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cookie and php-phantomjs #124

Open
DarthMoleman opened this issue Oct 1, 2016 · 8 comments
Open

Cookie and php-phantomjs #124

DarthMoleman opened this issue Oct 1, 2016 · 8 comments
Assignees
Milestone

Comments

@DarthMoleman
Copy link

Hi,

I have a file named predefinedcookie.txt that I already use for a list of websites compatible with curl. I would like to know how can I use it with php-phantomjs or what do I have to do to push cookie's variable in my request.

Best regards.
Luc

@cschalenborgh
Copy link

Any updates on this? We've got a use-case for this library but only if it can work with predefined cookies.

@jonnnnyw jonnnnyw self-assigned this Nov 15, 2016
@jonnnnyw jonnnnyw added this to the Version 4.6 milestone Nov 15, 2016
@jonnnnyw
Copy link
Owner

I will be working on v4.6 over the next few days so I will try and get cookie management in there.

@imam-zeropoint
Copy link

imam-zeropoint commented Feb 19, 2017

Session cookies are still missing and do not appear in the predefined cookie file. Also pushing cookies via $request->addHeader and addCookie do not appear in the response (Set-Cookie) hence missing flow among different requests.

But definitely request object shows some cookie is going to add via addCookie:

[cookies:protected] => Array
(
[add] => Array
(
[0] => Array
(
[name] => JSESSIONID
[value] => JSESSIONID_VALUE
[path] => /
[domain] => testdomain.com
[httponly] =>
[secure] => 1
[expires] => 1487525134
)

            )

        [delete] => Array
            (
            )

    )

But nothing appears regarding forced cookies, neither in the response nor in predefined cookie file, what is the failure here?

@andriuspetrauskis
Copy link
Contributor

@imam-zeropoint Session cookies are not stored in cookie file, according to this issue. @jonnnnyw, I have made a pull request #172 which adds ability to get cookies programmatically from response, without using --cookies-file flag.

@xelda1988
Copy link

@stexaz

I also need cookies to pass between requests. I just checked out your code - looks like a nice job :)!
But as I use the package via packagist I want to wait until the pull request is through.

@jonnnnyw
Will the pull request go through anytime soon?

@cyberfab007
Copy link

Did anyone ever fix this ?

@ahait
Copy link

ahait commented May 15, 2018

Go go go go....

@godgod81302
Copy link

Sadly...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

9 participants