Completed
Push — master ( e21aca...50b935 )
by
unknown
13:22
created
includes/modules/wps-modal/templates/frontend/modal.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -1,4 +1,4 @@
 block discarded – undo
1
-<?php if ( !defined( 'ABSPATH' ) ) exit;
1
+<?php if (!defined('ABSPATH')) exit;
2 2
 ?>
3 3
 <div class="wps-modal-overlay"></div>
4 4
 <div class="wps-modal-wrapper">	
Please login to merge, or discard this patch.
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -1,4 +1,6 @@
 block discarded – undo
1
-<?php if ( !defined( 'ABSPATH' ) ) exit;
1
+<?php if ( !defined( 'ABSPATH' ) ) {
2
+	exit;
3
+}
2 4
 ?>
3 5
 <div class="wps-modal-overlay"></div>
4 6
 <div class="wps-modal-wrapper">	
Please login to merge, or discard this patch.
includes/modules/wps-modal/wps-modal.php 3 patches
Indentation   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -14,8 +14,8 @@
 block discarded – undo
14 14
 
15 15
 	class wps_modal {
16 16
 		/** Define the main directory containing the template for the current plugin
17
-		* @var string
18
-		*/
17
+		 * @var string
18
+		 */
19 19
 		private $template_dir;
20 20
 		/**
21 21
 		 * Define the directory name for the module in order to check into frontend
Please login to merge, or discard this patch.
Spacing   +10 added lines, -10 removed lines patch added patch discarded remove patch
@@ -1,4 +1,4 @@  discard block
 block discarded – undo
1
-<?php if ( !defined( 'ABSPATH' ) ) exit;
1
+<?php if (!defined('ABSPATH')) exit;
2 2
 
3 3
 /**
4 4
  * Bootstrap file
@@ -6,11 +6,11 @@  discard block
 block discarded – undo
6 6
  * @version 1.0
7 7
  */
8 8
 
9
-if ( !class_exists('wps_modal') ) {
9
+if (!class_exists('wps_modal')) {
10 10
 	/** Template Global vars **/
11 11
 	DEFINE('WPS_MODAL_DIR', basename(dirname(__FILE__)));
12
-	DEFINE('WPS_MODAL_PATH', str_replace( "\\", "/", str_replace( WPS_MODAL_DIR, "", dirname( __FILE__ ) ) ) );
13
-	DEFINE('WPS_MODAL_URL', str_replace( str_replace( "\\", "/", ABSPATH), site_url() . '/', WPS_MODAL_PATH ) );
12
+	DEFINE('WPS_MODAL_PATH', str_replace("\\", "/", str_replace(WPS_MODAL_DIR, "", dirname(__FILE__))));
13
+	DEFINE('WPS_MODAL_URL', str_replace(str_replace("\\", "/", ABSPATH), site_url() . '/', WPS_MODAL_PATH));
14 14
 
15 15
 	class wps_modal {
16 16
 		/** Define the main directory containing the template for the current plugin
@@ -26,19 +26,19 @@  discard block
 block discarded – undo
26 26
 		function __construct() {
27 27
 			/** Template Load **/
28 28
 			$this->template_dir = WPS_MODAL_PATH . WPS_MODAL_DIR . "/templates/";
29
-			add_action('wp_enqueue_scripts', array( $this, 'add_scripts') );
30
-			add_action( 'wp_footer', array( $this, 'display_modal') );
29
+			add_action('wp_enqueue_scripts', array($this, 'add_scripts'));
30
+			add_action('wp_footer', array($this, 'display_modal'));
31 31
 		}
32 32
 
33 33
 		function add_scripts() {
34
-			wp_enqueue_script( 'jquery' );
35
-			wp_enqueue_script( 'wps_modal_script', plugins_url( 'assets/js/wps_modal.js' , __FILE__ ) );
34
+			wp_enqueue_script('jquery');
35
+			wp_enqueue_script('wps_modal_script', plugins_url('assets/js/wps_modal.js', __FILE__));
36 36
 		}
37 37
 
38 38
 		function display_modal() {
39 39
 			$output = '';
40 40
 			ob_start();
41
-			require_once( wpshop_tools::get_template_part( WPS_MODAL_DIR, $this->template_dir, "frontend", "modal") );
41
+			require_once(wpshop_tools::get_template_part(WPS_MODAL_DIR, $this->template_dir, "frontend", "modal"));
42 42
 			$output = ob_get_contents();
43 43
 			ob_end_clean();
44 44
 			echo $output;
@@ -46,6 +46,6 @@  discard block
 block discarded – undo
46 46
 	}
47 47
 
48 48
 }
49
-if ( class_exists('wps_modal') ) {
49
+if (class_exists('wps_modal')) {
50 50
 	$wps_modal = new wps_modal();
51 51
 }
Please login to merge, or discard this patch.
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -1,4 +1,6 @@
 block discarded – undo
1
-<?php if ( !defined( 'ABSPATH' ) ) exit;
1
+<?php if ( !defined( 'ABSPATH' ) ) {
2
+	exit;
3
+}
2 4
 
3 5
 /**
4 6
  * Bootstrap file
Please login to merge, or discard this patch.
includes/modules/wps_dashboard/config/config.php 2 patches
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -1,4 +1,4 @@  discard block
 block discarded – undo
1
-<?php if ( !defined( 'ABSPATH' ) ) exit;
1
+<?php if (!defined('ABSPATH')) exit;
2 2
 /**
3 3
  * Main plugin configuration file
4 4
  *
@@ -9,16 +9,16 @@  discard block
 block discarded – undo
9 9
  */
10 10
 
11 11
 /** Check if the plugin version is defined. If not defined script will be stopped here	*/
12
-if ( !defined( 'WPS_DASHBOARD_VERSION' ) ) {
13
-	die( __("You are not allowed to use this service.", 'wps_installer') );
12
+if (!defined('WPS_DASHBOARD_VERSION')) {
13
+	die(__("You are not allowed to use this service.", 'wps_installer'));
14 14
 }
15 15
 
16 16
 /** Define librairies directory */
17
-DEFINE( 'WPSDASHBOARD_LIBS_DIR', plugin_dir_path( __FILE__ ) . '/' . WPS_DASHBOARD_DIR . '/');
17
+DEFINE('WPSDASHBOARD_LIBS_DIR', plugin_dir_path(__FILE__) . '/' . WPS_DASHBOARD_DIR . '/');
18 18
 
19 19
 /** Define template directory */
20
-DEFINE( 'WPSDASHBOARD_TPL_DIR', WPS_DASHBOARD_PATH . WPS_DASHBOARD_DIR . '/templates/');
21
-DEFINE( 'WPSDASHBOARD_TPL_URL', WPS_DASHBOARD_URL . WPS_DASHBOARD_DIR . '/templates/');
20
+DEFINE('WPSDASHBOARD_TPL_DIR', WPS_DASHBOARD_PATH . WPS_DASHBOARD_DIR . '/templates/');
21
+DEFINE('WPSDASHBOARD_TPL_URL', WPS_DASHBOARD_URL . WPS_DASHBOARD_DIR . '/templates/');
22 22
 
23 23
 
24 24
 ?>
25 25
\ No newline at end of file
Please login to merge, or discard this patch.
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -1,4 +1,6 @@
 block discarded – undo
1
-<?php if ( !defined( 'ABSPATH' ) ) exit;
1
+<?php if ( !defined( 'ABSPATH' ) ) {
2
+	exit;
3
+}
2 4
 /**
3 5
  * Main plugin configuration file
4 6
  *
Please login to merge, or discard this patch.
includes/modules/wps_dashboard/controller/wps_dashboard_ctr.php 2 patches
Braces   +7 added lines, -9 removed lines patch added patch discarded remove patch
@@ -1,4 +1,6 @@  discard block
 block discarded – undo
1
-<?php if ( !defined( 'ABSPATH' ) ) exit;
1
+<?php if ( !defined( 'ABSPATH' ) ) {
2
+	exit;
3
+}
2 4
 /**
3 5
  * File for installer control class definition
4 6
  *
@@ -70,15 +72,13 @@  discard block
 block discarded – undo
70 72
 		if( ! is_wp_error( $rss ) ){
71 73
 			$maxitems = $rss->get_item_quantity( 4 );
72 74
 			$rss_items = $rss->get_items( 0, $maxitems );
73
-		}
74
-		else {
75
+		} else {
75 76
 			$output .= '<p>' . __('WPShop News cannot be loaded', 'wpshop') . '</p>';
76 77
 		}
77 78
 
78 79
 		if ( $maxitems == 0 ) {
79 80
 			$output .= '<p>' . __('No WPShop new has been found', 'wpshop') . '</p>';
80
-		}
81
-		else {
81
+		} else {
82 82
 			$output .= '<ul class="recent-orders">';
83 83
 			foreach ( $rss_items as $item ) {
84 84
 				$output .= '<li><a href="' .$item->get_permalink() . '" title="' .$item->get_title(). '" target="_blank">' .$item->get_title(). '</a><br/>';
@@ -108,12 +108,10 @@  discard block
 block discarded – undo
108 108
 				require_once( wpshop_tools::get_template_part( WPS_DASHBOARD_DIR, WPSDASHBOARD_TPL_DIR, "backend", "dashboard", "videos" ) );
109 109
 				$output = ob_get_contents();
110 110
 				ob_end_clean();
111
-			}
112
-			else {
111
+			} else {
113 112
 				$output = __('No tutorial videos can be loaded', 'wpshop' );
114 113
 			}
115
-		}
116
-		else {
114
+		} else {
117 115
 			$output = __( 'Your servor doesn\'t allow to open external files', 'wpshop');
118 116
 		}
119 117
 
Please login to merge, or discard this patch.
Spacing   +42 added lines, -42 removed lines patch added patch discarded remove patch
@@ -1,4 +1,4 @@  discard block
 block discarded – undo
1
-<?php if ( !defined( 'ABSPATH' ) ) exit;
1
+<?php if (!defined('ABSPATH')) exit;
2 2
 /**
3 3
  * File for installer control class definition
4 4
  *
@@ -24,7 +24,7 @@  discard block
 block discarded – undo
24 24
 	}
25 25
 
26 26
 	function add_scripts() {
27
-		add_action( 'admin_print_scripts', array($this, 'admin_print_script') );
27
+		add_action('admin_print_scripts', array($this, 'admin_print_script'));
28 28
 	}
29 29
 
30 30
 	function admin_print_script() {
@@ -45,15 +45,15 @@  discard block
 block discarded – undo
45 45
 		global $order_status, $wpdb;
46 46
 
47 47
 		$this->add_dashboard_metaboxes();
48
-		require_once( wpshop_tools::get_template_part( WPS_DASHBOARD_DIR, WPSDASHBOARD_TPL_DIR, "backend", "dashboard" ) );
48
+		require_once(wpshop_tools::get_template_part(WPS_DASHBOARD_DIR, WPSDASHBOARD_TPL_DIR, "backend", "dashboard"));
49 49
 	}
50 50
 
51 51
 	function wpshop_dashboard_orders() {
52 52
 		$output = '';
53
-		$orders = get_posts( array( 'posts_per_page' => 10, 'post_type' => WPSHOP_NEWTYPE_IDENTIFIER_ORDER, 'post_status' => 'publish', 'orderby' => 'post_date', 'order' => 'DESC') );
53
+		$orders = get_posts(array('posts_per_page' => 10, 'post_type' => WPSHOP_NEWTYPE_IDENTIFIER_ORDER, 'post_status' => 'publish', 'orderby' => 'post_date', 'order' => 'DESC'));
54 54
 		// Display orders
55 55
 		ob_start();
56
-		require_once( wpshop_tools::get_template_part( WPS_DASHBOARD_DIR, WPSDASHBOARD_TPL_DIR, "backend", "wps_orders_on_dashboard" ) );
56
+		require_once(wpshop_tools::get_template_part(WPS_DASHBOARD_DIR, WPSDASHBOARD_TPL_DIR, "backend", "wps_orders_on_dashboard"));
57 57
 		$output = ob_get_contents();
58 58
 		ob_end_clean();
59 59
 
@@ -63,24 +63,24 @@  discard block
 block discarded – undo
63 63
 
64 64
 	function wpshop_rss_feed() {
65 65
 		$output = '';
66
-		include_once( ABSPATH . WPINC . '/feed.php' );
66
+		include_once(ABSPATH . WPINC . '/feed.php');
67 67
 
68
-		$rss = fetch_feed( 'http://www.wpshop.fr/feed/' );
69
-		if( ! is_wp_error( $rss ) ){
70
-			$maxitems = $rss->get_item_quantity( 4 );
71
-			$rss_items = $rss->get_items( 0, $maxitems );
68
+		$rss = fetch_feed('http://www.wpshop.fr/feed/');
69
+		if (!is_wp_error($rss)) {
70
+			$maxitems = $rss->get_item_quantity(4);
71
+			$rss_items = $rss->get_items(0, $maxitems);
72 72
 		}
73 73
 		else {
74 74
 			$output .= '<p>' . __('WPShop News cannot be loaded', 'wpshop') . '</p>';
75 75
 		}
76 76
 
77
-		if ( $maxitems == 0 ) {
77
+		if ($maxitems == 0) {
78 78
 			$output .= '<p>' . __('No WPShop new has been found', 'wpshop') . '</p>';
79 79
 		}
80 80
 		else {
81 81
 			$output .= '<ul class="recent-orders">';
82
-			foreach ( $rss_items as $item ) {
83
-				$output .= '<li><a href="' .$item->get_permalink() . '" title="' .$item->get_title(). '" target="_blank">' .$item->get_title(). '</a><br/>';
82
+			foreach ($rss_items as $item) {
83
+				$output .= '<li><a href="' . $item->get_permalink() . '" title="' . $item->get_title() . '" target="_blank">' . $item->get_title() . '</a><br/>';
84 84
 				$output .= $item->get_content();
85 85
 				$output .= '</li>';
86 86
 			}
@@ -90,40 +90,40 @@  discard block
 block discarded – undo
90 90
 	}
91 91
 
92 92
 	function wpshop_rss_tutorial_videos() {
93
-		$ini_get_checking = ini_get( 'allow_url_fopen' );
93
+		$ini_get_checking = ini_get('allow_url_fopen');
94 94
 
95
-		if ( $ini_get_checking != 0 ) {
96
-			$content = @file_get_contents( 'http://www.wpshop.fr/rss_video.xml' );
97
-			$videos_rss = ( $content !== false ) ? new SimpleXmlElement( $content ) : null;
98
-			if ( !empty($videos_rss) && !empty($videos_rss->channel) ) {
95
+		if ($ini_get_checking != 0) {
96
+			$content = @file_get_contents('http://www.wpshop.fr/rss_video.xml');
97
+			$videos_rss = ($content !== false) ? new SimpleXmlElement($content) : null;
98
+			if (!empty($videos_rss) && !empty($videos_rss->channel)) {
99 99
 				$videos_items = array();
100
-				foreach( $videos_rss->channel->item as $i => $item ) {
100
+				foreach ($videos_rss->channel->item as $i => $item) {
101 101
 					$videos_items[] = $item;
102 102
 				}
103
-				$rand_element = array_rand( $videos_items );
103
+				$rand_element = array_rand($videos_items);
104 104
 
105 105
 				ob_start();
106
-				require_once( wpshop_tools::get_template_part( WPS_DASHBOARD_DIR, WPSDASHBOARD_TPL_DIR, "backend", "dashboard", "videos" ) );
106
+				require_once(wpshop_tools::get_template_part(WPS_DASHBOARD_DIR, WPSDASHBOARD_TPL_DIR, "backend", "dashboard", "videos"));
107 107
 				$output = ob_get_contents();
108 108
 				ob_end_clean();
109 109
 			}
110 110
 			else {
111
-				$output = __('No tutorial videos can be loaded', 'wpshop' );
111
+				$output = __('No tutorial videos can be loaded', 'wpshop');
112 112
 			}
113 113
 		}
114 114
 		else {
115
-			$output = __( 'Your servor doesn\'t allow to open external files', 'wpshop');
115
+			$output = __('Your servor doesn\'t allow to open external files', 'wpshop');
116 116
 		}
117 117
 
118 118
 		echo $output;
119 119
 	}
120 120
 
121 121
 	function wpshop_dashboard_get_changelog() {
122
-		$readme_file = fopen( WPSHOP_DIR.'/readme.txt', 'r' );
123
-		if ( $readme_file ) {
124
-			$txt = file_get_contents( WPSHOP_DIR.'/readme.txt' );
125
-			$pre_change_log = explode( '== Changelog ==', $txt );
126
-			$versions = explode( '= Version', $pre_change_log[1] );
122
+		$readme_file = fopen(WPSHOP_DIR . '/readme.txt', 'r');
123
+		if ($readme_file) {
124
+			$txt = file_get_contents(WPSHOP_DIR . '/readme.txt');
125
+			$pre_change_log = explode('== Changelog ==', $txt);
126
+			$versions = explode('= Version', $pre_change_log[1]);
127 127
 
128 128
 			echo $versions[1];
129 129
 		}
@@ -133,16 +133,16 @@  discard block
 block discarded – undo
133 133
 	 * Add custom metaboxes to WPShop dashboard
134 134
 	 */
135 135
 	function add_dashboard_metaboxes() {
136
-		add_meta_box( 'wps-right-now', '<i class="dashicons dashicons-info"></i>' . esc_html( 'Right Now', 'wpshop' ), array( $this, 'wps_dashboard_right_now' ), 'wpshop_dashboard', 'left_column' );
137
-		add_meta_box( 'wps-dashboard-quick-links', '<i class="dashicons dashicons-performance"></i>' . esc_html( 'Quick Links', 'wpshop' ), array( $this, 'wps_dashboard_quick_links' ), 'wpshop_dashboard', 'left_column' );
136
+		add_meta_box('wps-right-now', '<i class="dashicons dashicons-info"></i>' . esc_html('Right Now', 'wpshop'), array($this, 'wps_dashboard_right_now'), 'wpshop_dashboard', 'left_column');
137
+		add_meta_box('wps-dashboard-quick-links', '<i class="dashicons dashicons-performance"></i>' . esc_html('Quick Links', 'wpshop'), array($this, 'wps_dashboard_quick_links'), 'wpshop_dashboard', 'left_column');
138 138
 		// add_meta_box( 'wps-dashboard-customer-stats', '<i class="dashicons dashicons-chart-pie"></i>' . esc_html( 'Customers stats', 'wpshop' ), array( $this, 'wps_dashboard_customer_stats' ), 'wpshop_dashboard', 'left_column' );
139
-		add_meta_box( 'wps-dashboard-export', '<i class="dashicons dashicons-download"></i>' . esc_html( 'CSV export', 'wpshop' ), array( $this, 'wps_dashboard_export' ), 'wpshop_dashboard', 'left_column' );
140
-		add_meta_box( 'wps-dashboard-orders', '<i class="dashicons dashicons-cart"></i>' . esc_html( 'Recent Orders', 'wpshop' ), array( $this, 'wps_dashboard_orders' ), 'wpshop_dashboard', 'left_column' );
139
+		add_meta_box('wps-dashboard-export', '<i class="dashicons dashicons-download"></i>' . esc_html('CSV export', 'wpshop'), array($this, 'wps_dashboard_export'), 'wpshop_dashboard', 'left_column');
140
+		add_meta_box('wps-dashboard-orders', '<i class="dashicons dashicons-cart"></i>' . esc_html('Recent Orders', 'wpshop'), array($this, 'wps_dashboard_orders'), 'wpshop_dashboard', 'left_column');
141 141
 
142
-		add_meta_box( 'wps-dashboard-statistics', '<i class="dashicons dashicons-chart-area"></i>' . esc_html( 'Statistics', 'wpshop' ), array( $this, 'wps_dashboard_statistics' ), 'wpshop_dashboard', 'right_column' );
142
+		add_meta_box('wps-dashboard-statistics', '<i class="dashicons dashicons-chart-area"></i>' . esc_html('Statistics', 'wpshop'), array($this, 'wps_dashboard_statistics'), 'wpshop_dashboard', 'right_column');
143 143
 
144
-		add_meta_box( 'wps-dashboard-infos', '<i class="dashicons dashicons-heart"></i>' . esc_html( 'WPShop : WordPress e-commerce', 'wpshop' ), array( $this, 'wps_dashboard_infos' ), 'wpshop_dashboard', 'right_column' );
145
-		add_meta_box( 'wps-dashboard-feed', '<i class="dashicons dashicons-format-status"></i>' . esc_html( 'WPShop News', 'wpshop' ), array( $this, 'wps_dashboard_feed' ), 'wpshop_dashboard', 'right_column' );
144
+		add_meta_box('wps-dashboard-infos', '<i class="dashicons dashicons-heart"></i>' . esc_html('WPShop : WordPress e-commerce', 'wpshop'), array($this, 'wps_dashboard_infos'), 'wpshop_dashboard', 'right_column');
145
+		add_meta_box('wps-dashboard-feed', '<i class="dashicons dashicons-format-status"></i>' . esc_html('WPShop News', 'wpshop'), array($this, 'wps_dashboard_feed'), 'wpshop_dashboard', 'right_column');
146 146
 	}
147 147
 
148 148
 	/**
@@ -150,14 +150,14 @@  discard block
 block discarded – undo
150 150
 	 */
151 151
 	function wps_dashboard_right_now() {
152 152
 		global $wpdb;
153
-		require_once( wpshop_tools::get_template_part( WPS_DASHBOARD_DIR, WPSDASHBOARD_TPL_DIR, 'backend', 'metabox', 'right_now' ) );
153
+		require_once(wpshop_tools::get_template_part(WPS_DASHBOARD_DIR, WPSDASHBOARD_TPL_DIR, 'backend', 'metabox', 'right_now'));
154 154
 	}
155 155
 
156 156
 	/**
157 157
 	 * Display metabox with quick links
158 158
 	 */
159 159
 	function wps_dashboard_quick_links() {
160
-		require_once( wpshop_tools::get_template_part( WPS_DASHBOARD_DIR, WPSDASHBOARD_TPL_DIR, 'backend', 'metabox', 'quicklinks' ) );
160
+		require_once(wpshop_tools::get_template_part(WPS_DASHBOARD_DIR, WPSDASHBOARD_TPL_DIR, 'backend', 'metabox', 'quicklinks'));
161 161
 	}
162 162
 
163 163
 	/**
@@ -173,7 +173,7 @@  discard block
 block discarded – undo
173 173
 	function wps_dashboard_statistics() {
174 174
 		global $wpdb;
175 175
 
176
-		require_once( wpshop_tools::get_template_part( WPS_DASHBOARD_DIR, WPSDASHBOARD_TPL_DIR, 'backend', 'metabox', 'statistics' ) );
176
+		require_once(wpshop_tools::get_template_part(WPS_DASHBOARD_DIR, WPSDASHBOARD_TPL_DIR, 'backend', 'metabox', 'statistics'));
177 177
 	}
178 178
 
179 179
 	/**
@@ -181,28 +181,28 @@  discard block
 block discarded – undo
181 181
 	 */
182 182
 	function wps_dashboard_infos() {
183 183
 		global $wpdb;
184
-		require_once( wpshop_tools::get_template_part( WPS_DASHBOARD_DIR, WPSDASHBOARD_TPL_DIR, 'backend', 'metabox', 'infos' ) );
184
+		require_once(wpshop_tools::get_template_part(WPS_DASHBOARD_DIR, WPSDASHBOARD_TPL_DIR, 'backend', 'metabox', 'infos'));
185 185
 	}
186 186
 
187 187
 	/**
188 188
 	 * Display metabox with shop main statistics
189 189
 	 */
190 190
 	function wps_dashboard_feed() {
191
-		require_once( wpshop_tools::get_template_part( WPS_DASHBOARD_DIR, WPSDASHBOARD_TPL_DIR, 'backend', 'metabox', 'feed' ) );
191
+		require_once(wpshop_tools::get_template_part(WPS_DASHBOARD_DIR, WPSDASHBOARD_TPL_DIR, 'backend', 'metabox', 'feed'));
192 192
 	}
193 193
 
194 194
 	/**
195 195
 	 * Display metabox with recent orders list
196 196
 	 */
197 197
 	function wps_dashboard_orders() {
198
-		require_once( wpshop_tools::get_template_part( WPS_DASHBOARD_DIR, WPSDASHBOARD_TPL_DIR, 'backend', 'metabox', 'orders' ) );
198
+		require_once(wpshop_tools::get_template_part(WPS_DASHBOARD_DIR, WPSDASHBOARD_TPL_DIR, 'backend', 'metabox', 'orders'));
199 199
 	}
200 200
 
201 201
 	/**
202 202
 	 * Display metabox for export
203 203
 	 */
204 204
 	function wps_dashboard_export() {
205
-		if ( class_exists( 'wps_export_ctr' ) ) {
205
+		if (class_exists('wps_export_ctr')) {
206 206
 			$wps_export = new wps_export_ctr();
207 207
 			$wps_export->wps_export_tpl();
208 208
 		}
Please login to merge, or discard this patch.
includes/modules/wps_dashboard/templates/backend/dashboard-videos.php 2 patches
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -1,7 +1,7 @@
 block discarded – undo
1
-<?php if ( !defined( 'ABSPATH' ) ) exit;
1
+<?php if (!defined('ABSPATH')) exit;
2 2
 ?>
3 3
 <div>
4
-	<div class="wps-h6"><?php echo $videos_items[ $rand_element ]->title; ?></div>
5
-	<div><center><iframe width="400" height="290" src="<?php echo $videos_items[ $rand_element ]->embed_link; ?>" frameborder="0" allowfullscreen></iframe></center></div>
6
-	<div><?php echo $videos_items[ $rand_element ]->description; ?></div>
4
+	<div class="wps-h6"><?php echo $videos_items[$rand_element]->title; ?></div>
5
+	<div><center><iframe width="400" height="290" src="<?php echo $videos_items[$rand_element]->embed_link; ?>" frameborder="0" allowfullscreen></iframe></center></div>
6
+	<div><?php echo $videos_items[$rand_element]->description; ?></div>
7 7
 </div>
8 8
\ No newline at end of file
Please login to merge, or discard this patch.
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -1,4 +1,6 @@
 block discarded – undo
1
-<?php if ( !defined( 'ABSPATH' ) ) exit;
1
+<?php if ( !defined( 'ABSPATH' ) ) {
2
+	exit;
3
+}
2 4
 ?>
3 5
 <div>
4 6
 	<div class="wps-h6"><?php echo $videos_items[ $rand_element ]->title; ?></div>
Please login to merge, or discard this patch.
includes/modules/wps_dashboard/wps_dashboard.php 2 patches
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -1,4 +1,4 @@  discard block
 block discarded – undo
1
-<?php if ( !defined( 'ABSPATH' ) ) exit;
1
+<?php if (!defined('ABSPATH')) exit;
2 2
 /**
3 3
  * Module bootstrap file
4 4
  * @author Development team <[email protected]>
@@ -13,13 +13,13 @@  discard block
 block discarded – undo
13 13
 
14 14
 /** Template Global vars **/
15 15
 DEFINE('WPS_DASHBOARD_DIR', basename(dirname(__FILE__)));
16
-DEFINE('WPS_DASHBOARD_PATH_TO_MODULE', str_replace( str_replace( "\\", "/", WP_PLUGIN_DIR ), "", str_replace( "\\", "/", plugin_dir_path( __FILE__ ) ) ) );
17
-DEFINE('WPS_DASHBOARD_PATH', str_replace( "\\", "/", str_replace( WPS_DASHBOARD_DIR, "", dirname( __FILE__ ) ) ) );
18
-DEFINE('WPS_DASHBOARD_URL', str_replace( str_replace( "\\", "/", ABSPATH), site_url() . '/', WPS_DASHBOARD_PATH ) );
16
+DEFINE('WPS_DASHBOARD_PATH_TO_MODULE', str_replace(str_replace("\\", "/", WP_PLUGIN_DIR), "", str_replace("\\", "/", plugin_dir_path(__FILE__))));
17
+DEFINE('WPS_DASHBOARD_PATH', str_replace("\\", "/", str_replace(WPS_DASHBOARD_DIR, "", dirname(__FILE__))));
18
+DEFINE('WPS_DASHBOARD_URL', str_replace(str_replace("\\", "/", ABSPATH), site_url() . '/', WPS_DASHBOARD_PATH));
19 19
 
20
-include( WPS_DASHBOARD_PATH . WPS_DASHBOARD_DIR . '/config/config.php' );
20
+include(WPS_DASHBOARD_PATH . WPS_DASHBOARD_DIR . '/config/config.php');
21 21
 
22
-include( WPS_DASHBOARD_PATH . WPS_DASHBOARD_DIR . '/controller/wps_dashboard_ctr.php' );
22
+include(WPS_DASHBOARD_PATH . WPS_DASHBOARD_DIR . '/controller/wps_dashboard_ctr.php');
23 23
 
24 24
 global $wps_dashboard_ctr;
25 25
 $wps_dashboard_ctr = new wps_dashboard_ctr();
Please login to merge, or discard this patch.
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -1,4 +1,6 @@
 block discarded – undo
1
-<?php if ( !defined( 'ABSPATH' ) ) exit;
1
+<?php if ( !defined( 'ABSPATH' ) ) {
2
+	exit;
3
+}
2 4
 /**
3 5
  * Module bootstrap file
4 6
  * @author Development team <[email protected]>
Please login to merge, or discard this patch.
includes/modules/wps_installer/wps_installer.php 2 patches
Spacing   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -1,4 +1,4 @@  discard block
 block discarded – undo
1
-<?php if ( !defined( 'ABSPATH' ) ) exit;
1
+<?php if (!defined('ABSPATH')) exit;
2 2
 /**
3 3
  * Module bootstrap file
4 4
  * @author Development team <[email protected]>
@@ -13,17 +13,17 @@  discard block
 block discarded – undo
13 13
 
14 14
 /** Template Global vars **/
15 15
 DEFINE('WPS_INSTALLER_DIR', basename(dirname(__FILE__)));
16
-DEFINE('WPS_INSTALLER_PATH_TO_MODULE', str_replace( str_replace( "\\", "/", WP_PLUGIN_DIR ), "", str_replace( "\\", "/", plugin_dir_path( __FILE__ ) ) ) );
17
-DEFINE('WPS_INSTALLER_PATH', str_replace( "\\", "/", str_replace( WPS_INSTALLER_DIR, "", dirname( __FILE__ ) ) ) );
18
-DEFINE('WPS_INSTALLER_URL', str_replace( str_replace( "\\", "/", ABSPATH), site_url() . '/', WPS_INSTALLER_PATH ) );
16
+DEFINE('WPS_INSTALLER_PATH_TO_MODULE', str_replace(str_replace("\\", "/", WP_PLUGIN_DIR), "", str_replace("\\", "/", plugin_dir_path(__FILE__))));
17
+DEFINE('WPS_INSTALLER_PATH', str_replace("\\", "/", str_replace(WPS_INSTALLER_DIR, "", dirname(__FILE__))));
18
+DEFINE('WPS_INSTALLER_URL', str_replace(str_replace("\\", "/", ABSPATH), site_url() . '/', WPS_INSTALLER_PATH));
19 19
 
20
-load_plugin_textdomain( 'wps_installer', false, dirname(plugin_basename(__FILE__)).'/languages/');
20
+load_plugin_textdomain('wps_installer', false, dirname(plugin_basename(__FILE__)) . '/languages/');
21 21
 
22
-include( WPS_INSTALLER_PATH . WPS_INSTALLER_DIR . '/config/config.php' );
22
+include(WPS_INSTALLER_PATH . WPS_INSTALLER_DIR . '/config/config.php');
23 23
 
24
-include( WPS_INSTALLER_PATH . WPS_INSTALLER_DIR . '/controller/wps_installer_ctr.php' );
25
-include( WPS_INSTALLER_PATH . WPS_INSTALLER_DIR . '/model/wps_installer_model.php' );
24
+include(WPS_INSTALLER_PATH . WPS_INSTALLER_DIR . '/controller/wps_installer_ctr.php');
25
+include(WPS_INSTALLER_PATH . WPS_INSTALLER_DIR . '/model/wps_installer_model.php');
26 26
 
27
-$wps_installer_ctr  = new wps_installer_ctr();
27
+$wps_installer_ctr = new wps_installer_ctr();
28 28
 
29 29
 ?>
Please login to merge, or discard this patch.
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -1,4 +1,6 @@
 block discarded – undo
1
-<?php if ( !defined( 'ABSPATH' ) ) exit;
1
+<?php if ( !defined( 'ABSPATH' ) ) {
2
+	exit;
3
+}
2 4
 /**
3 5
  * Module bootstrap file
4 6
  * @author Development team <[email protected]>
Please login to merge, or discard this patch.
includes/modules/wps_installer/config/config.php 2 patches
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -1,4 +1,4 @@  discard block
 block discarded – undo
1
-<?php if ( !defined( 'ABSPATH' ) ) exit;
1
+<?php if (!defined('ABSPATH')) exit;
2 2
 /**
3 3
  * Main plugin configuration file
4 4
  *
@@ -9,14 +9,14 @@  discard block
 block discarded – undo
9 9
  */
10 10
 
11 11
 /** Define librairies directory */
12
-DEFINE( 'WPSINSTALLER_LIBS_DIR', plugin_dir_path( __FILE__ ) . '/' . WPS_INSTALLER_DIR . '/');
12
+DEFINE('WPSINSTALLER_LIBS_DIR', plugin_dir_path(__FILE__) . '/' . WPS_INSTALLER_DIR . '/');
13 13
 
14 14
 /** Define template directory */
15
-DEFINE( 'WPSINSTALLER_TPL_DIR', WPS_INSTALLER_PATH . WPS_INSTALLER_DIR . '/templates/');
16
-DEFINE( 'WPSINSTALLER_TPL_URL', WPS_INSTALLER_URL . WPS_INSTALLER_DIR . '/templates/');
15
+DEFINE('WPSINSTALLER_TPL_DIR', WPS_INSTALLER_PATH . WPS_INSTALLER_DIR . '/templates/');
16
+DEFINE('WPSINSTALLER_TPL_URL', WPS_INSTALLER_URL . WPS_INSTALLER_DIR . '/templates/');
17 17
 
18
-$installation_step = array( __( 'Your society informations', 'wpshop'), __( 'Shop type', 'wpshop'), __( 'Have fun', 'wpshop') );
19
-DEFINE( 'WPSINSTALLER_STEPS', serialize( $installation_step ) );
20
-DEFINE( 'WPSINSTALLER_STEPS_COUNT', count( $installation_step ) );
18
+$installation_step = array(__('Your society informations', 'wpshop'), __('Shop type', 'wpshop'), __('Have fun', 'wpshop'));
19
+DEFINE('WPSINSTALLER_STEPS', serialize($installation_step));
20
+DEFINE('WPSINSTALLER_STEPS_COUNT', count($installation_step));
21 21
 
22 22
 ?>
Please login to merge, or discard this patch.
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -1,4 +1,6 @@
 block discarded – undo
1
-<?php if ( !defined( 'ABSPATH' ) ) exit;
1
+<?php if ( !defined( 'ABSPATH' ) ) {
2
+	exit;
3
+}
2 4
 /**
3 5
  * Main plugin configuration file
4 6
  *
Please login to merge, or discard this patch.
includes/modules/wps_installer/templates/backend/step_one.php 2 patches
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -1,13 +1,13 @@
 block discarded – undo
1
-<?php if ( !defined( 'ABSPATH' ) ) exit;
1
+<?php if (!defined('ABSPATH')) exit;
2 2
 ?>
3
-<h4><?php _e( 'Those informations will be used into invoice and to display your contact informations', 'wpshop'); ?></h4>
3
+<h4><?php _e('Those informations will be used into invoice and to display your contact informations', 'wpshop'); ?></h4>
4 4
 <?php
5
-	do_settings_sections( 'wpshop_company_info' );
5
+	do_settings_sections('wpshop_company_info');
6 6
 ?>
7 7
 
8 8
 <table class="form-table" >
9 9
 	<tr>
10
-		<th><?php _e( 'The logo for emails and invoices', 'wpshop'); ?></th>
10
+		<th><?php _e('The logo for emails and invoices', 'wpshop'); ?></th>
11 11
 		<td><?php wpshop_general_options::wpshop_logo_field(); ?></td>
12 12
 	</tr>
13 13
 </table>
Please login to merge, or discard this patch.
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -1,4 +1,6 @@
 block discarded – undo
1
-<?php if ( !defined( 'ABSPATH' ) ) exit;
1
+<?php if ( !defined( 'ABSPATH' ) ) {
2
+	exit;
3
+}
2 4
 ?>
3 5
 <h4><?php _e( 'Those informations will be used into invoice and to display your contact informations', 'wpshop'); ?></h4>
4 6
 <?php
Please login to merge, or discard this patch.