Global includes
Since version 2.0.2. there has been an option in phpFanList to share a directory (g_includes) with files that are the same for all fanlists. This feature has been developed more and more over the last versions and we will continue to do so for future versions. The main reason for this is, well ..., convenience. This for both programmers as for fanlist owners. It allows you to change one single file and see the result in all using phpFanList installations. It is also handy when you want to update, want to fix a bug before the next release is out or have limited webspace (171Kbytes isn't much, but when you've got a lot of fanlists, it adds up real quickly, especially with plug-ins).
How do I use it?
Ok, so you're convinced using the g_includes directory's potential is a good thing. Now, how do you use it.
Follow these steps (the order is important):
- Copy the g_includes directory to a central place on your server. (It is not really needed to do so, it's just better practice.)
- Go to the admin page, the settings section of the fanlisting you want using the shared g_includes directory
- Set the "Global Includes Directory" to the newly copied directory. Now, be carefull. The directory needs to end with a / and can be relative or absolute (relative is something like this: "../g_includes/"; where absolute is something like this: "/home/accountname/public_html/fanlistings/g_includes/").
- Click the update button and you're done.
Please note that we are not responsible for your fanlisting not working anymore. If you don't know what you're doing, ask for help!
Recovering
There is only one problem with this technique. If you set it up wrong, your fanlists doesn't work anymore. This also means that the directory you entered in the admin section was wrong (duh!). Now, probably the question you're asking yourself, how do I restore it?
Easy, put the g_includes directory back where it was, download and open this g_reset.php script from the fanlist directory. It will only do one thing and that's setting the setting back to its default value.