07-13-2017, 05:46 PM
well thats where its quite cool, the autoload class loads only if not loaded, I've tested the autoload required at the top of init.php along with the classes manual required at the same time and all good not issues,
in an update we can have a patch file that works like your db patch files which will hold this which places the require to the top of init.php:
<pre></pre>
in an update we can have a patch file that works like your db patch files which will hold this which places the require to the top of init.php:
<pre>
Code:
<?php
//:: This will patch your init.php from v4.2.9 :://
//:: WARNING ! BACKUP YOUR INIT.PHP BEFORE RUNNING THIS PATCH :://
require_once 'init.php';
require_once 'includes/header.php';
require_once 'includes/navigation.php';
$init = 'init.php';
$AutoLoad = '<?php require_once \'classes/class.autoloader.php\';';
$contents = file_get_contents($init);
$line = '<?php';
$contents = str_replace($line, '', $contents);
file_put_contents($init, $contents);
$lines = file($init);
$fopen = fopen($init, "w+");
fwrite( $fopen, $AutoLoad );
foreach( $lines as $line ) {
fwrite( $fopen, "$line");
}
fclose ($fopen);
bold("<br><br>You're good to go. Delete patch file and bask in the glory.");
?>