WordPress.org

Ready to get started?Download WordPress

Forums

Session Interrupted by Another Plugin (2 posts)

  1. edrdesign
    Member
    Posted 10 months ago #

    I hope this is in the right section, but I am in the process of ironing out the kinks of a custom plugin I designed that uses PHP's session function and having some issues. The first time it was because of another plugin using the session function and I had to disable that plugin in order to get my plugin to work. Is there a way to isolate my session variables to my plugin and ensure that if another other plugin clears out all session variables in their code that mine is unaffected?

  2. bcworkz
    Member
    Posted 10 months ago #

    Not that I know of. You probably need to maintain session data with some other mechanism: cookies, transients, URL parameters, POST data, usermeta, etc.; all could work under certain conditions. I realize doing so could invalidate your entire concept, I just don't know how one can protect session data from another process that has equal rights as your own. As such, none of the other mechanisms are inviolate either, but other plugins are less likely to destroy the entire structure.

Reply

You must log in to post.

About this Topic