Php - multiple curl requests (NOT "multithreading")

If I want to do a few things (which require cookies) with curl, for example:

  • Log in to (my own) blog
  • then automatically post a blog post

Am I doing this in one curl instance before closing or closing the first session and then starting the second for the second task? (Sorry if this is a dumb question, but I can't get it. As a rule, all the examples on the network that I find in curl do only one thing ... this does not help me with understanding this.)

+6
php curl curl-multi
source share
2 answers

Generally speaking:

So yes, all in one session.

+9
source share

Yes, open and close each curl object before moving on to the next.

0
source share

All Articles