• Resolved corzel

    (@corzel)


    Hello,

    After last update to v3.0.9 I’m getting this warning in php log file:

    Warning: session_start(): Cannot start session when headers already sent in /var/www/html/wp-content/plugins/youzify/includes/public/core/membership/class-youzify-register.php on line 202
    
    Stack trace
    1. {main}() /var/www/html/wp-cron.php:0
    2. require_once() /var/www/html/wp-cron.php:44
    3. require_once() /var/www/html/wp-load.php:37
    4. require_once() /var/www/html/wp-config.php:482
    5. do_action() /var/www/html/wp-settings.php:557
    6. WP_Hook->do_action() /var/www/html/wp-includes/plugin.php:484
    7. WP_Hook->apply_filters() /var/www/html/wp-includes/class-wp-hook.php:311
    8. Youzify_Membership->init() /var/www/html/wp-includes/class-wp-hook.php:287
    9. Youzify_Membership_Register->__construct() /var/www/html/wp-content/plugins/youzify/includes/public/core/class-youzify-membership.php:69
    10. Youzify_Membership_Register->process_signup_errors() /var/www/html/wp-content/plugins/youzify/includes/public/core/membership/class-youzify-register.php:28
    11. session_start() /var/www/html/wp-content/plugins/youzify/includes/public/core/membership/class-youzify-register.php:202

    Best regards.

    • This topic was modified 3 years ago by corzel.
Viewing 5 replies - 1 through 5 (of 5 total)
  • Plugin Support KaineLabs Team

    (@kainelabsteam)

    Hello @corzel,

    Hope you are doing good.

    Thanks for using our plugin.

    Can you please let me know when this error occurs exactly so we can replicate the same process from our end to debug it and solve it. as I just tried opening the registration shortcode page on my localhost and registered a new account and I checked my debug log there was no error generated.

    Waiting for your kind reply.

    Best Regards, KaineLabs Team.

    Thread Starter corzel

    (@corzel)

    Hi,

    I use Error Log Monitor plugin, the warning accurs every 30 seconds, I use Olympus theme and this theme uses Unyson as framework.

    May be, there is some kind of conflict with sessions in unyson because it is a well know bug in this plugin (You can read about it in Github).

    The register process is working fine, activation emails are sending ok.

    Plugin Support KaineLabs Team

    (@kainelabsteam)

    Hello @corzel,

    Thanks for the clarification.

    If you disabled Unyson is the problem resolved?

    Can you try reaching them as this error can be avoided by checking if there’s a session created before like this code below:

            if ( ! session_id() ) {
                session_start();
            }
    

    Also in case, they have any other suggestion to be implemented from our side to solve this problem we will be happy to use it 🙂

    Best Regards, KaineLabs Team.

    Thread Starter corzel

    (@corzel)

    Hi,
    I finally found a solution for this, adding == ” on line 201 in class-youzify-register.php

    
    200        // Init Session.
    201        if ( ! session_id() == '' ) {
    202            session_start();
    203        }

    Everything seems to be working fine, user registration completes smoothly for now.

    Plugin Support KaineLabs Team

    (@kainelabsteam)

    Hello @corzel,

    Thanks for your message.

    No worries, we already removed sessions and used a better solution even with better performance 🙂

    Best Regards, KaineLabs Team.

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Error in php log’ is closed to new replies.