Woocommerce cart is a non-object inside `admin_post` action [closed]

Closed. This question is off-topic. It is not currently accepting answers. Want to improve this question? Update the question so it’s on-topic for WordPress Development Stack Exchange. Closed 3 months ago. Improve this question I’m writing a custom integration plugin for Woocommerce, to add a dynamic product to the cart. Right now, without the plugin, … Read more

$_SESSION variables lost during OAuth callback

When I attempt an OAuth handshake, the first step is a GET call to obtain an access code like so. # Redirect to request authorization code $url = $this->get_authorization_url(); header(“Location: $url”); exit; Just before I send this I store the current URL in a $_SESSION[‘last_url’] variable so that after authentication is complete I can redirect … Read more

I just discovered why all ASP.Net websites are slow, and I am trying to work out what to do about it

I just discovered that every request in an ASP.Net web application gets a Session lock at the beginning of a request, and then releases it at the end of the request! In case the implications of this are lost on you, as it was for me at first, this basically means the following: Anytime an … Read more

“Keep Me Logged In” – the best approach

My web application uses sessions to store information about the user once they’ve logged in, and to maintain that information as they travel from page to page within the app. In this specific application, I’m storing the user_id, first_name and last_name of the person. I’d like to offer a “Keep Me Logged In” option on … Read more

Handling nonces for actions from guests to logged-in users

Imagine the following scenario: John has an account on my website, but is currently not logged in. He clicks the “upvote” button on an article, but is redirected to the login page because only logged-in users can upvote. In the referral URL (to which John is redirected after login) the following parameters are passed: action=upvote … Read more