WordPress Plugins and File Fetching
A number of my recent plugins have provided a facility to read files from other sites. However, as I posted about, errors were being reported by some users and so I attempted a change in one such plugin to address this.
Unfortunately, that didn’t quite work as I intended. Kind of. In this case, I swapped to using a different file routine, but one which now only works with PHP 5. So I’ve now published a newer version of the same plugin using another new method, and one that should now be compatible with PHP 4.
The problem here is that there are security implications with reading files externally, so there is a way for hosts to turn this ability off.
My new plugin, I suspect, doesn’t actually resolve this and there isn’t a great amount I can do about this – if your host has decided to prevent you from reading external files then, well, you’re stuffed. My host doesn’t, which might explain why I didn’t recognise the problem at first.
The file system I’ve used now, however, should allow you to specify local file names – at least that way files hosted by yourself should be readable. I’ve not tested it though, so feel free to provide feedback.
I’m now going to upgrade my other plugins with the same code process.
Related posts:
- URL file-access is disabled Many of my plugins read from XML or RSS feeds. In these cases, I read the files using the PHP file_get_contents() command. However, if you...
- Change logs for WordPress plugins The standard readme.txt for WordPress plugins has been updated to allow for changelogs. This is excellent news and has happened at just the right time...
- Getting Help for my Wordpress Plugins If you'd like some help with any of my WordPress plugins then I'm more than happy to help. But please read this post to find...



















Artiss.co.uk is checked by