0

i am using moodle version 1.9.19. all thing are working properly. but i have an error like below:

Warning: Creating default object from empty value in D:\xampp\htdocs\moodel\server\moodle\theme\standardwhite\config.php on line 9

Warning: Creating default object from empty value in D:\xampp\htdocs\moodel\server\moodle\lib\uploadlib.php on line 78

how to solve this error. please help me

Nisanth
  • 323
  • 8
  • 24
  • Possible duplicate of [How to fix 'Creating default object from empty value' warning in PHP](http://stackoverflow.com/questions/14806959/how-to-fix-creating-default-object-from-empty-value-warning-in-php) – Erik Nov 03 '15 at 13:46
  • But i am having this error in moodle – Nisanth Nov 03 '15 at 14:07
  • According to [the docs](https://docs.moodle.org/29/en/PHP) Moodle is written in PHP. – Erik Nov 03 '15 at 14:09

1 Answers1

0

Correct solution - upgrade to Moodle 2.x. These warnings are due to Moodle 1.9 not being fully compatible with PHP 5.4 (and above) - these warnings have all been fixed in supported versions of Moodle.

If you really need to work with Moodle 1.9, then you will have to manually fix all of these by adding in the missing '$object = new stdClass();' calls before each of the warnings (where '$object' should be replaced by the name of the object that has not been initialised properly).

davosmith
  • 6,037
  • 2
  • 14
  • 23