bouchnina

autoloader decoded

Feb 9th, 2015
686
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 1.88 KB | None | 0 0
  1. <?php
  2.  
  3.  
  4.     include( 'config.php' );
  5.  
  6.     if (( !mysql_connect( $host, $dbusername, $dbpassword ) && !mysql_select_db( $db_name ) )) {
  7.         exit( 'The Script isn\'t installed. Gor to <b><a href="install/install.php">Installation Process</a></b>' );
  8.     }
  9.  
  10.     include( 'connect.php' );
  11.     include( 'functions.php' );
  12.     include( 'setting.php' );
  13.     include( 'general.class.php' );
  14.  
  15.     if (!empty( $general_setting['script_theme'] )) {
  16.         $theme_dir = $general_setting['script_theme'];
  17.     }
  18. else {
  19.         $theme_dir = 'default';
  20.     }
  21.  
  22.     require_once( 'libs/Smarty.class.php' );
  23.     $smarty = new Smarty(  );
  24.     $smarty->compile_dir = 'cache/';
  25.     $smarty->template_dir = 'themes/' . $theme_dir;
  26.     $smarty->force_compile = true;
  27.     foreach ($setting_row as $key => $value) {
  28.         $decode_value = unserialize( base64_decode( $value ) );
  29.  
  30.         if (!empty( $decode_value )) {
  31.             foreach ($decode_value as $key2 => $value2) {
  32.                 $smarty->assign( $key . '_' . $key2, $value2 );
  33.             }
  34.  
  35.             continue;
  36.         }
  37.     }
  38.  
  39.     $smarty->assign( 'ad_slot_1', $ad_slot_1 );
  40.     $smarty->assign( 'ad_slot_2', $ad_slot_2 );
  41.     $smarty->assign( 'ad_slot_3', $ad_slot_3 );
  42.  
  43.     if (strpos( file_get_contents( 'themes/' . $theme_dir . '/footer.html' ), 'pluscss.com' )  = false) {
  44.         exit( 'you don\'t have permission to remove copyrights. <a href="http://www.pluscss.com/contact">Contact us if you want to remove the copyright link</a>' );
  45.     }
  46.  
  47.  
  48.     if (is_dir( 'install/' )) {
  49.         exit( 'The <b>Install</b> folder is exists. Please delete the <b>Install</b> folder or rename it.' );
  50.     }
  51.  
  52.  
  53.     if (!empty( $general_setting['script_language'] )) {
  54.         $language_dir = $general_setting['script_language'];
  55.     }
  56. else {
  57.         $language_dir = 'english';
  58.     }
  59.  
  60.     include( 'languages/' . $language_dir . '/' . $language_dir . '.php' );
  61.     $smarty->assign( 'language', $language );
  62.     foreach ($language as $key => $value) {
  63.         $smarty->assign( 'language_' . $key, $value );
  64.     }
  65.  
  66. ?>
Advertisement
Add Comment
Please, Sign In to add comment