Based on some suggestions here I am using auto_prepend_file for my header/auth page. However, I'm running into the following issues, all based on my header page being attached to pages that I actually don't want it to. For example: - Ajax pages return the header page in their text - Phpmyadmin fails to load
I am wondering whether auto_prepend_file is the right design choice (I'd like it to be that way so that a newly added page mistakenly doesn't allow the user access without logging in). Also, for Ajax pages I am adding logic in the header to skip those pages, but I can't figure out a solution for phpMyAdmin, which seems to dislike the include even though the header returns nothing. The error from phpMyadmin is:
Fatal error: main() [function.main]: The script tried to execute a method or access a property of an incomplete object. Please ensure that the class definition "PMA_Theme_Manager" of the object you are trying to operate on was loaded before unserialize() gets called or provide a __autoload() function to load the class definition in C:\Program Files\Ampps\phpMyAdmin\libraries\common.inc.php on line 661
Any help will be appreciated!
auto_prepend_file is a tool to be used in an emergency or very special situations. It should never be an application design choice. It makes applications less portable and more difficult to analyze and debug. Redo your application to use require or require_once to include the necessary code.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With