I have been helping a not for profit organisation to move servers and reinstate their bespoke PHP CMS website after the website creator/coder who also was hosting their site and administering it, deserted them and we cannot find him despite paying a visit to his office and home address for the past 4 months.
The script is fully owned by the not for profit organisation. However some key files have been encrypted using Ion Cube. While the migration was largely successful, I am trying to resolve a niggly problem which refers to account paths within these encrypted files which is throwing up errors on just the file upload function.
What I want is a little script to prepend (maybe?) all php files within directories and sub directories in problem areas, that will replace the account paths on the script functions with the new account path:
For example replace /home/xxx/yyy with /home/aaa/bbb in one before the script is compiled by the server or replace it with $_SERVER['DOCUMENT_ROOT']."/xyz/".
This is part of the file upload function which is hard coded with the original server path.
I know what the old account path and the new account paths are but cannot work out the php required to do this to prepend to the encrypted file as I am very much a noob. I don't know if this approach will work but, if implemented correctly, I don't see any reason why it shouldn't.
I would be grateful for any help or any other suggestions.