• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
dbutil backup

#1
from the CI doc i see in the "Backup Your Database" section

// Backup your entire database and assign it to a variable
$backup =& $this->dbutil->backup();

but it brings a runtime error:

Severity: Runtime Notice
Message: Only variables should be assigned by reference

from Php manual
http://php.net/manual/en/language.operat...gnment.php

As of PHP 5, the new operator returns a reference automatically, so assigning the result of new by reference results in an E_DEPRECATED message in PHP 5.3 and later, and an E_STRICT message in earlier versions.


simply removing the & works fine.
please update the doc
Reply

#2
I'm seeing the same thing still in the documentation.

Thanks for posting the solution.
Reply

#3
https://github.com/bcit-ci/CodeIgniter/c...a894a296b4
Reply


Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2021 MyBB Group.