WordPress.org

Ready to get started?Download WordPress

Forums

Paid Memberships Pro
[resolved] Session already sent (3 posts)

  1. Austin Passy
    Member
    Posted 4 months ago #

    session_start() [<a href='function.session-start'>function.session-start</a>]:
    Cannot send session cookie - headers already sent in
    /.../plugins/paid-memberships-pro/paid-memberships-pro.php
    on line 26

    https://wordpress.org/plugins/paid-memberships-pro/

  2. Austin Passy
    Member
    Posted 4 months ago #

    Recommended way for versions of PHP >= 5.4.0

    if (session_status() == PHP_SESSION_NONE) {
            session_start();
        }

    Source: http://www.php.net/manual/en/function.session-status.php

    For versions of PHP < 5.4.0

    if(session_id() == '') {
            session_start();
        }
  3. messica
    Member
    Plugin Author

    Posted 4 months ago #

    Thanks for that, we'll actually be updating our code ASAP to detect the PHP version and deliver the right code accordingly. Marking this resolved.

    Thanks,
    Jess

Reply

You must log in to post.

About this Plugin

About this Topic