CodeIgniter Forums

Full Version: MAMP, PHP5.2.11, CI 1.72 and deprecation errors....
You're currently viewing a stripped down version of our content. View the full version with proper formatting.

El Forum

Hi All,

I'm new to the mac world, transitioning from WinXP. I'm using the MAMP stack on Snow Leopard (specifically, the one from which seems to use PHP5.2.11.

I downloaded the latest CI, verified that the default app worked, confirmed that CI_VERSION reports 1.7.2, then copied the application folder only from my XP machine to the new CI install on the mac.

I'm getting the following errors:
Deprecated: Assigning the return value of new by reference is deprecated in /Library/WebServer/Documents/bi/system/codeigniter/Common.php on line 130

Deprecated: Assigning the return value of new by reference is deprecated in /Library/WebServer/Documents/bi/system/codeigniter/Common.php on line 136
A PHP Error was encountered

Severity: 8192

Message: Function set_magic_quotes_runtime() is deprecated

Filename: codeigniter/CodeIgniter.php

Line Number: 60
The URI you submitted has disallowed characters.

Based on forum searches, it seems that these errors might be a result of the PHP 5.3 release, but that 1.7.2 should have fixed those issues.

Does anyone have a working MAMP config working that could share their experience in fixing these errors?

El Forum

Im pretty sure that you dont have CI 1.7.2 installed or you have failed copying all the files. As that line in Common.php is empty in CI 1.7.2 and before that line theres nothing that would cause that error.

If you have not touched the system directory, remove it and copy system dir again from the package. That should fix the problem. Theres nothing Mamp or xampp or wamp specific that you could do.

El Forum

Your reply sparked the realization that I had not updated the

$config['base_url']    = "";

which was still hardcoded, and rerouting to the original, broken instance of CI on the machine. I have updated to
$config['base_url']    = "http://" . $_SERVER["HTTP_HOST"]. ":" .$_SERVER['SERVER_PORT']. "/";

which made everything work just dandy.

Thanks for your help!

El Forum

try to replace



ini_set(“magic_quotes_runtime”, 0);

then restart your web server application.,.,.