Changeset 1969694
- Timestamp:
- 11/06/2018 10:11:39 AM (7 years ago)
- Location:
- traveladsnetwork-com/trunk
- Files:
-
- 3 edited
-
classes/traveladsBox.php (modified) (3 diffs)
-
classes/traveladsButton.php (modified) (3 diffs)
-
travelads_plugin.php (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
traveladsnetwork-com/trunk/classes/traveladsBox.php
r1966393 r1969694 1 1 <?php 2 2 3 echo 'TRAVEEL: accessing box.php'; 3 4 if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly 5 echo 'TRAVEEL: accessing box.php 0'; 4 6 5 7 // initialize 6 8 if ( is_admin() ) { 9 echo 'TRAVEEL: accessing box.php 1'; 7 10 add_action('add_meta_boxes', function () { 11 echo 'TRAVEEL: accessing box.php 2'; 8 12 $screens = array ('post', 'page'); 9 13 $args = array ( 10 'public' => true,11 '_builtin' => false14 'public' => true, 15 '_builtin' => false 12 16 ); 13 17 $custom_post_types = get_post_types ($args, 'names', 'and'); … … 29 33 30 34 function tan_add_meta_box_callback($post) { 35 echo 'TRAVEEL: accessing box.php 3'; 31 36 global $wpdb; 32 37 … … 36 41 return; 37 42 43 echo 'TRAVEEL: accessing box.php 4'; 38 44 $code = tan_test_log(); 45 echo 'TRAVEEL: accessing box.php 5'; 39 46 40 47 if($code !== 202){ -
traveladsnetwork-com/trunk/classes/traveladsButton.php
r1969633 r1969694 1 1 <?php 2 2 3 echo 'TRAVEEL: accessing button.php'; 3 4 if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly 5 echo 'TRAVEEL: accessing button.php 1'; 4 6 5 7 // initialize 6 8 if ( is_admin() ) { 7 9 // Add Button to Editor 10 echo 'TRAVEEL: accessing button.php 2'; 8 11 add_action('plugins_loaded', function() { 9 12 add_filter( 'mce_external_plugins','tan_add_button_travel'); … … 14 17 function tan_add_button_travel( $plugin_array ) 15 18 { 19 echo 'TRAVEEL: accessing button.php 3'; 16 20 $plugin_array['TravelAdsNetwork_links'] = plugins_url('assets/js/admin/shortcode-button-tinymce.js', dirname(__FILE__)); 17 21 return $plugin_array; … … 20 24 function tan_register_button_travel( $buttons ) 21 25 { 26 echo 'TRAVEEL: accessing button.php 4'; 22 27 array_push( $buttons, 'TravelAdsNetwork_links' ); 23 28 return $buttons; -
traveladsnetwork-com/trunk/travelads_plugin.php
r1969692 r1969694 93 93 $pageConfig = $res[0]; 94 94 95 echo 'HEERE'.$pageConfig->{'mode'};96 echo $pageConfig->{'mode'} === 0;97 echo 'baababaa';98 echo $pageConfig->{'mode'} === "0";99 echo '"'.$pageConfig->{'mode'}.'"';100 101 95 switch(preg_replace('/\?.*$/', '', $_SERVER['REQUEST_URI'])) 102 96 { … … 183 177 include(travelads_PLUGIN_DIR.'classes/traveladsConfig.php'); 184 178 185 $tra_mode = isset($_COOKIE['TAN_savedConfig'])?stripslashes($_COOKIE['TAN_savedConfig']):'null';186 187 179 // 188 180 // Check Manual from Cookie 189 181 // 190 if(isset(json_decode($tra_mode)->{'mode'}) && json_decode($tra_mode)->{'mode'} === '0') 182 183 global $wpdb; 184 $ID = get_the_ID(); 185 $res = $wpdb->get_results('SELECT * FROM wp_tan_pages_config 186 WHERE `page_id` = "'.$ID.'"'); 187 188 $pageConfig = $res[0]; 189 190 if($pageConfig->{'mode'} === '0') //manual mode 191 192 //$tra_mode = isset($_COOKIE['TAN_savedConfig'])?stripslashes($_COOKIE['TAN_savedConfig']):'null'; 193 //if(isset(json_decode($tra_mode)->{'mode'}) && json_decode($tra_mode)->{'mode'} === '0') 191 194 { 195 echo 'TRAVEEL: invoking phps 0'; 192 196 require_once(travelads_PLUGIN_DIR.'classes/traveladsBox.php'); 193 197 require_once(travelads_PLUGIN_DIR.'classes/traveladsButton.php');
Note: See TracChangeset
for help on using the changeset viewer.