Title: Fatal error: Class &#039;WP_Session&#039; not found&#8230;
Last modified: August 21, 2016

---

# Fatal error: Class 'WP_Session' not found…

 *  [Cristiano](https://wordpress.org/support/users/iclapton/)
 * (@iclapton)
 * [12 years, 7 months ago](https://wordpress.org/support/topic/fatal-error-class-wp_session-not-found-1/)
 * Hi Eric,
 * First of all, thanks for your plugin! I have some problem to use it, so I need
   your help.
    I understand I need to define `$wp_session = WP_Session::get_instance();`
   inside any session-dependent functions, like you said in other topic.
 * I do it inside a function that add some session variables. It’s ok. I print this
   variables on the same page to test it, and it’s fine.
 * On the second page, when I define again the `$wp_session = WP_Session::get_instance();`
   I get the error F
 * > atal error: Class ‘WP_Session’ not found…
 * . If I don’t define it, I can’t get the session variables.
 * What I’m doing wrong?
    Thank you very much!
 * [http://wordpress.org/plugins/wp-session-manager/](http://wordpress.org/plugins/wp-session-manager/)

Viewing 1 replies (of 1 total)

 *  Plugin Author [Eric Mann](https://wordpress.org/support/users/ericmann/)
 * (@ericmann)
 * [12 years, 5 months ago](https://wordpress.org/support/topic/fatal-error-class-wp_session-not-found-1/#post-4283487)
 * I’d have to see your code, but my feeling would be that you’re trying to use `
   WP_Session` before the plugin’s been included and the class is available. Is 
   your code hooked to a specific action or just firing within a page?

Viewing 1 replies (of 1 total)

The topic ‘Fatal error: Class 'WP_Session' not found…’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/wp-session-manager_272e38.svg)
 * [WP Session Manager](https://wordpress.org/plugins/wp-session-manager/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/wp-session-manager/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/wp-session-manager/)
 * [Active Topics](https://wordpress.org/support/plugin/wp-session-manager/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/wp-session-manager/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/wp-session-manager/reviews/)

 * 1 reply
 * 2 participants
 * Last reply from: [Eric Mann](https://wordpress.org/support/users/ericmann/)
 * Last activity: [12 years, 5 months ago](https://wordpress.org/support/topic/fatal-error-class-wp_session-not-found-1/#post-4283487)
 * Status: not resolved