larwilliams
03-02-2008, 05:13 PM
Hi guys,
I am upgrading a server (for a client) to php5 that has about 75 small sites (php + basic forms and feedback). Some of these sites were coded back in the day and use the old $HTTP_GET_VARS, $HTTP_POST_VARS and $HTTP_SERVER_VARS.
I would rather not set register_long_arrays = On to be safe.
I have root access to the server and all sites are stored under /home.
Is there a way to automatically replace the above variables with the current ones ($_GET, $_POST, and $_SERVER) in every .php file. I know some combination of the find, sed, and xargs commands (shell) is needed, but not sure the syntax required.
If someone could post an example, it would be appreciated.
I am upgrading a server (for a client) to php5 that has about 75 small sites (php + basic forms and feedback). Some of these sites were coded back in the day and use the old $HTTP_GET_VARS, $HTTP_POST_VARS and $HTTP_SERVER_VARS.
I would rather not set register_long_arrays = On to be safe.
I have root access to the server and all sites are stored under /home.
Is there a way to automatically replace the above variables with the current ones ($_GET, $_POST, and $_SERVER) in every .php file. I know some combination of the find, sed, and xargs commands (shell) is needed, but not sure the syntax required.
If someone could post an example, it would be appreciated.
