Title: Error passing PHP 5.2 to PHP 5.4
Last modified: August 20, 2016

---

# Error passing PHP 5.2 to PHP 5.4

 *  Resolved [Fikx](https://wordpress.org/support/users/fikx/)
 * (@fikx)
 * [13 years, 6 months ago](https://wordpress.org/support/topic/warning-creating-default-object-from-empty-value-in-capabilitiesphp/)
 * In English :
    I recently moved from version PHP 5.2 to PHP 5.4 and error has 
   occurred in the page of the list of events : Warning: Creating default object
   from empty value in /homepages/2/d421693919/htdocs/zumba/wp-includes/capabilities.
   php on line 641 If I revert to the version of PHP 5.2, the error disappears.
 * Does anyone have a solution or can help me?
 * Thank you in advance!
 * In French :
    Je suis passé récemment de la version PHP 5.2 à PHP 5.4 et cette
   erreur est apparue dans la page de la liste des évènements : Warning: Creating
   default object from empty value in /homepages/2/d421693919/htdocs/zumba/wp-includes/
   capabilities.php on line 641 Si je repasse à la version PHP 5.2, l’erreur disparaît.
 * Est-ce que quelqu’un aurait une solution ou peut m’aider ?
 * Merci d’avance !
 * [http://wordpress.org/extend/plugins/events-manager/](http://wordpress.org/extend/plugins/events-manager/)

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

 *  Thread Starter [Fikx](https://wordpress.org/support/users/fikx/)
 * (@fikx)
 * [13 years, 6 months ago](https://wordpress.org/support/topic/warning-creating-default-object-from-empty-value-in-capabilitiesphp/#post-3270985)
 * I found what is causing the error: the code #_AVAILABLESPACES.
    But I don’t know
   why… Can we not see available spaces in the list of events ?
 *  Thread Starter [Fikx](https://wordpress.org/support/users/fikx/)
 * (@fikx)
 * [13 years, 6 months ago](https://wordpress.org/support/topic/warning-creating-default-object-from-empty-value-in-capabilitiesphp/#post-3270990)
 * Resolved ! It was because some reservations made by a person not registered… :
   S
 *  [agelonwl](https://wordpress.org/support/users/angelonwl/)
 * (@angelonwl)
 * [13 years, 6 months ago](https://wordpress.org/support/topic/warning-creating-default-object-from-empty-value-in-capabilitiesphp/#post-3270996)
 * thanks for updating.
 *  Thread Starter [Fikx](https://wordpress.org/support/users/fikx/)
 * (@fikx)
 * [13 years, 6 months ago](https://wordpress.org/support/topic/warning-creating-default-object-from-empty-value-in-capabilitiesphp/#post-3271005)
 * Finally, the problem reappears when you want to delete a user :
 *     ```
       Warning: Creating default object from empty value in /wp-includes/capabilities.php on line 641
   
       Warning: Cannot modify header information - headers already sent by (output started at /wp-includes/capabilities.php:641) in /wp-includes/pluggable.php on line 876
       ```
   
 * But just before I deleted his booking. That is the problem ?
    And finally the
   user has been deleted.
 * Does anyone have a solution or can help me?
 * Thank you in advance !
 *  Thread Starter [Fikx](https://wordpress.org/support/users/fikx/)
 * (@fikx)
 * [13 years, 6 months ago](https://wordpress.org/support/topic/warning-creating-default-object-from-empty-value-in-capabilitiesphp/#post-3271007)
 * If I’m not mistaken, I think the problem is buddypress with PHP 5.4. Does someone
   can confirm ? I can’t find solutions for the moment…
 *  Plugin Author [Marcus (aka @msykes)](https://wordpress.org/support/users/netweblogic/)
 * (@netweblogic)
 * [13 years, 6 months ago](https://wordpress.org/support/topic/warning-creating-default-object-from-empty-value-in-capabilitiesphp/#post-3271008)
 * this may be partially a WP bug actually… will have to test this out when time
   permits as I don’t have a server with 5.4 handy right now.
 *  Thread Starter [Fikx](https://wordpress.org/support/users/fikx/)
 * (@fikx)
 * [13 years, 6 months ago](https://wordpress.org/support/topic/warning-creating-default-object-from-empty-value-in-capabilitiesphp/#post-3271009)
 * Ok. Thank you Marcus !
    I’m going to do with, because I don’t have a choice unfortunately.
   My host requires me to switch to php 5.4. :S Can I continue to use it with php
   5.4 or I may have cause errors ?
 * Thank you for your reply anyway and good weekend ! 😉
 *  Plugin Author [Marcus (aka @msykes)](https://wordpress.org/support/users/netweblogic/)
 * (@netweblogic)
 * [13 years, 6 months ago](https://wordpress.org/support/topic/warning-creating-default-object-from-empty-value-in-capabilitiesphp/#post-3271023)
 * the above shouldn’t cause any adverse behaviour, if you disable php errors on
   your pages, e.g. disable_errors in your php.ini settings or in your .htaccess
   file it should hide the errors and work normally.
 *  Thread Starter [Fikx](https://wordpress.org/support/users/fikx/)
 * (@fikx)
 * [13 years, 6 months ago](https://wordpress.org/support/topic/warning-creating-default-object-from-empty-value-in-capabilitiesphp/#post-3271024)
 * Ok ! Thank you again Marcus ! 😉
 *  [glyndavidson](https://wordpress.org/support/users/glyndavidson/)
 * (@glyndavidson)
 * [12 years, 6 months ago](https://wordpress.org/support/topic/warning-creating-default-object-from-empty-value-in-capabilitiesphp/#post-3271073)
 * Thanks Fikx, that saved me a bunch of time.
 * I had the same errors and it was because I’d deleted a user who had made a booking.
   Deleting the booking fixed the errors.

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

The topic ‘Error passing PHP 5.2 to PHP 5.4’ is closed to new replies.

 * ![](https://ps.w.org/events-manager/assets/icon-256x256.png?rev=3550347)
 * [Events Manager - Calendar, Bookings, Tickets, and more!](https://wordpress.org/plugins/events-manager/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/events-manager/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/events-manager/)
 * [Active Topics](https://wordpress.org/support/plugin/events-manager/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/events-manager/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/events-manager/reviews/)

## Tags

 * [event](https://wordpress.org/support/topic-tag/event/)
 * [list](https://wordpress.org/support/topic-tag/list/)

 * 10 replies
 * 4 participants
 * Last reply from: [glyndavidson](https://wordpress.org/support/users/glyndavidson/)
 * Last activity: [12 years, 6 months ago](https://wordpress.org/support/topic/warning-creating-default-object-from-empty-value-in-capabilitiesphp/#post-3271073)
 * Status: resolved