Title: HTTP Header problem
Last modified: December 15, 2016

---

# HTTP Header problem

 *  Resolved [fatjester](https://wordpress.org/support/users/fatjester/)
 * (@fatjester)
 * [9 years, 3 months ago](https://wordpress.org/support/topic/http-header-problem/)
 * A highly technical client was asking why his site had an HTTP Response Header
   with an expiration date in the past, thus preventing browser caching:
    Expires:
   Thu, 19 Nov 1981 08:52:00 GMT
 * I did a little digging, and it turns out “custom sidebars” is the culprit from
   creating a PHP session.
    I understand creating the session id for logged in users,
   but is there a reason you are creating it for all users?
 * It seems like there would be performance issues preventing browser caching, and
   possible security issues using session ids over unsecured or unauthenticated 
   connections.
 * If there isn’t a reason, could you wrap those sessions in a check if the user
   is logged in?
 * Thanks,
    -Chris

Viewing 8 replies - 1 through 8 (of 8 total)

 *  [Predrag – WPMU DEV Support](https://wordpress.org/support/users/wpmudev-support1/)
 * (@wpmudev-support1)
 * [9 years, 3 months ago](https://wordpress.org/support/topic/http-header-problem/#post-8576608)
 * Hi Chris,
 * Apologies for the delay here.
 * Thank you for your detailed report, I’m afraid that I’m unable to clear this 
   up for you much without consulting the developers for further information.
 * I will forward this thread to them and get back to you when I get some insight
   from them.
 * Cheers,
    Predrag
 *  Thread Starter [fatjester](https://wordpress.org/support/users/fatjester/)
 * (@fatjester)
 * [9 years, 2 months ago](https://wordpress.org/support/topic/http-header-problem/#post-8635314)
 * Hello,
    Just checking in on this.
 * Thanks,
    -Chris
 *  Thread Starter [fatjester](https://wordpress.org/support/users/fatjester/)
 * (@fatjester)
 * [9 years, 2 months ago](https://wordpress.org/support/topic/http-header-problem/#post-8699492)
 * Hmm,
    4 weeks without any reply.
 * Bummer 🙁
 * -Chris
 *  [Predrag – WPMU DEV Support](https://wordpress.org/support/users/wpmudev-support1/)
 * (@wpmudev-support1)
 * [9 years, 2 months ago](https://wordpress.org/support/topic/http-header-problem/#post-8701806)
 * Hi Chris,
 * Apologies for the delay, our developers are having issues with replicating this
   and I’m still waiting for further information from them.
    I just pinged them 
   again and hopefully there will be some good news soon.
 * Cheers,
    Predrag
 *  Thread Starter [fatjester](https://wordpress.org/support/users/fatjester/)
 * (@fatjester)
 * [9 years, 2 months ago](https://wordpress.org/support/topic/http-header-problem/#post-8702096)
 * No problem,
    Here are my steps to reproduce.
 * 1. fresh install of wordpress (I use the default docker container with mariadb)
   
   2. open site’s mainpage in chrome, open chrome devtools, click network, click
   the main html file, look at “Headers”, notice under “Response Headers” there 
   is no “Expires” header. 3. install and activate the “Custom Sidebars” plugin 
   4. refresh the site’s mainpage and look at the headers again, notice there is
   now an “Expires” header set to “Expires:Thu, 19 Nov 1981 08:52:00 GMT” 5. deactivate
   the “Custom Sidebars” plugin 6. refresh the site’s mainpage and look at the headers
   again, notice the “Expires” header is gone.
 * As noted earlier, this is from the plugin creating a php session for all users.
   
   In php if a session is created, it defaults to expiring the page to prevent sessions
   from caching.
 * Let me know if you have any other questions about replicating the issue.
 * Thanks,
    -Chris
 *  [Predrag – WPMU DEV Support](https://wordpress.org/support/users/wpmudev-support1/)
 * (@wpmudev-support1)
 * [9 years, 2 months ago](https://wordpress.org/support/topic/http-header-problem/#post-8725373)
 * Hi Chris,
 * Our developers are currently working on some improvements for this on next release
   and in the meantime adding below code to your wp-config.php should do the trick:
   `
   define( 'WDEV_USE_SESSION', false );`
 * Cheers,
    Predrag
 *  Thread Starter [fatjester](https://wordpress.org/support/users/fatjester/)
 * (@fatjester)
 * [9 years, 1 month ago](https://wordpress.org/support/topic/http-header-problem/#post-8801217)
 * Thanks so much for the update to the plugin!
    Things working great!
 * -Chris
 *  [Predrag – WPMU DEV Support](https://wordpress.org/support/users/wpmudev-support1/)
 * (@wpmudev-support1)
 * [9 years, 1 month ago](https://wordpress.org/support/topic/http-header-problem/#post-8803776)
 * Awesome! Thanks for getting back to us with the status, have a nice day!
 * Predrag

Viewing 8 replies - 1 through 8 (of 8 total)

The topic ‘HTTP Header problem’ is closed to new replies.

 * ![](https://ps.w.org/custom-sidebars/assets/icon-256x256.png?rev=1414065)
 * [Custom Sidebars - Dynamic Sidebar Classic Widget Area Manager](https://wordpress.org/plugins/custom-sidebars/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/custom-sidebars/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/custom-sidebars/)
 * [Active Topics](https://wordpress.org/support/plugin/custom-sidebars/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/custom-sidebars/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/custom-sidebars/reviews/)

 * 8 replies
 * 2 participants
 * Last reply from: [Predrag – WPMU DEV Support](https://wordpress.org/support/users/wpmudev-support1/)
 * Last activity: [9 years, 1 month ago](https://wordpress.org/support/topic/http-header-problem/#post-8803776)
 * Status: resolved