2013-02-13, 08:44 PM
After brad brought up the idea of fetching remotely hosted images included in posts and hosting them locally, I decided to make a simple script to do just that that could be ran via a cron job. I've only tested it a little bit on my localhost today and it seems to be working just fine.
The script can be found here: https://github.com/euantor/MyBB-Local-Images
To use it, you will have to modify the definitions at the top of the file to suit your site and I definitely don't recommend using it live without first trying it locally and backing up your database fully.
The script itself can be ran via cron job or accessed directly via your browser. Either way, it will simply output the number of posts that were modified.
If anybody can test this out and post back results, I would be very glad indeed.
The script can be found here: https://github.com/euantor/MyBB-Local-Images
To use it, you will have to modify the definitions at the top of the file to suit your site and I definitely don't recommend using it live without first trying it locally and backing up your database fully.
The script itself can be ran via cron job or accessed directly via your browser. Either way, it will simply output the number of posts that were modified.
If anybody can test this out and post back results, I would be very glad indeed.