GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.
Completed
Push — master ( 165b67...57aaae )
by Liuta
02:24
created
admin/partials/xcloner_scheduled_backups_page.php 1 patch
Spacing   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -4,7 +4,7 @@  discard block
 block discarded – undo
4 4
 $xcloner_remote_storage = $this->get_xcloner_container()->get_xcloner_remote_storage();
5 5
 $available_storages = $xcloner_remote_storage->get_available_storages();
6 6
 ?>
7
-<?php if(!defined("DISABLE_WP_CRON") || !DISABLE_WP_CRON): ?>
7
+<?php if (!defined("DISABLE_WP_CRON") || !DISABLE_WP_CRON): ?>
8 8
 	<div id="setting-error-" class="error settings-error notice is-dismissible"> 
9 9
 		<p><strong>
10 10
 			<?php echo sprintf(__('We have noticed that DISABLE_WP_CRON is disabled, we recommend enabling that and setting up wp-cron.php to run manually through your hosting account scheduler as explained <a href="%s" target="_blank">here</a>', 'xcloner-backup-and-restore'), "http://www.inmotionhosting.com/support/website/wordpress/disabling-the-wp-cronphp-in-wordpress") ?>
@@ -48,7 +48,7 @@  discard block
 block discarded – undo
48 48
 
49 49
 <div class="row">
50 50
 	<div class="col s12 m6 offset-m6 teal lighten-1" id="server_time">
51
-		<h2><?php echo __('Current Server Time', 'xcloner-backup-and-restore')?>: <span class="right"><?php echo current_time('mysql');?></span></h2>
51
+		<h2><?php echo __('Current Server Time', 'xcloner-backup-and-restore')?>: <span class="right"><?php echo current_time('mysql'); ?></span></h2>
52 52
 	</div>
53 53
 </div>
54 54
 
@@ -94,11 +94,11 @@  discard block
 block discarded – undo
94 94
 					</div>
95 95
 					<!--<div class="input-field inline col s12 l6">
96 96
 						<select id="backup_type" class="" name="backup_type" id="backup_type">
97
-							<option value=""><?php echo __("Full Backup","xcloner-backup-and-restore");?></option>
98
-							<option value="diff"><?php echo __("Differential Backups","xcloner-backup-and-restore");?></option>
99
-							<option value="full_diff"><?php echo __("Full Backup + Differential Backups","xcloner-backup-and-restore");?></option>
97
+							<option value=""><?php echo __("Full Backup", "xcloner-backup-and-restore"); ?></option>
98
+							<option value="diff"><?php echo __("Differential Backups", "xcloner-backup-and-restore"); ?></option>
99
+							<option value="full_diff"><?php echo __("Full Backup + Differential Backups", "xcloner-backup-and-restore"); ?></option>
100 100
 						</select>
101
-						<label for="backup_type"><?php echo __('Scheduled Backup Type','xcloner-backup-and-restore')?></label>
101
+						<label for="backup_type"><?php echo __('Scheduled Backup Type', 'xcloner-backup-and-restore')?></label>
102 102
 					</div>-->
103 103
 				</div>
104 104
 				
@@ -114,7 +114,7 @@  discard block
 block discarded – undo
114 114
 							<?php
115 115
 							$schedules = $xcloner_scheduler->get_available_intervals();
116 116
 							
117
-							foreach($schedules as $key=>$schedule)
117
+							foreach ($schedules as $key=>$schedule)
118 118
 							{
119 119
 							?>
120 120
 								<option value="<?php echo $key?>"><?php echo $schedule['display']?></option>
@@ -125,12 +125,12 @@  discard block
 block discarded – undo
125 125
 					</div>
126 126
 				</div>
127 127
 				
128
-				<?php if(sizeof($available_storages)):?>
128
+				<?php if (sizeof($available_storages)):?>
129 129
 				<div class="row">
130 130
 					<div class="input-field col s12 l12">
131 131
 						<select name="schedule_storage" id="schedule_storage" class="validate" >
132 132
 							<option value="" selected><?php echo __('none', 'xcloner-backup-and-restore') ?></option>
133
-							<?php foreach($available_storages as $storage=>$text):?>
133
+							<?php foreach ($available_storages as $storage=>$text):?>
134 134
 								<option value="<?php echo $storage?>"><?php echo $text?></option>
135 135
 							<?php endforeach?>
136 136
 						</select>
Please login to merge, or discard this patch.
includes/class-xcloner-scheduler.php 3 patches
Doc Comments   +3 added lines patch added patch discarded remove patch
@@ -334,6 +334,9 @@
 block discarded – undo
334 334
 		$this->xcloner_file_system->backup_storage_cleanup();
335 335
 	}
336 336
 	
337
+	/**
338
+	 * @param integer $id
339
+	 */
337 340
 	public function xcloner_scheduler_callback($id, $schedule = "")
338 341
 	{
339 342
 		if($id)
Please login to merge, or discard this patch.
Spacing   +70 added lines, -70 removed lines patch added patch discarded remove patch
@@ -1,6 +1,6 @@  discard block
 block discarded – undo
1 1
 <?php
2 2
 
3
-class Xcloner_Scheduler{
3
+class Xcloner_Scheduler {
4 4
 	
5 5
 	private $db;
6 6
 	private $scheduler_table = "xcloner_scheduler";
@@ -21,8 +21,8 @@  discard block
 block discarded – undo
21 21
 	{
22 22
 		global $wpdb;
23 23
 		
24
-		$this->db 					= $wpdb;
25
-		$wpdb->show_errors			= false;
24
+		$this->db = $wpdb;
25
+		$wpdb->show_errors = false;
26 26
 		
27 27
 		$this->xcloner_container	= $xcloner_container;
28 28
 		$this->xcloner_settings 	= $xcloner_container->get_xcloner_settings();
@@ -40,18 +40,18 @@  discard block
 block discarded – undo
40 40
 		$this->xcloner_container = $container;
41 41
 	}
42 42
 	
43
-	public function get_scheduler_list($return_only_enabled = 0 )
43
+	public function get_scheduler_list($return_only_enabled = 0)
44 44
 	{
45 45
 		$list = $this->db->get_results("SELECT * FROM ".$this->scheduler_table);
46 46
 		
47
-		if($return_only_enabled)
47
+		if ($return_only_enabled)
48 48
 		{
49
-			$new_list= array();
49
+			$new_list = array();
50 50
 			
51
-			foreach($list as $res)
52
-				if($res->status)
51
+			foreach ($list as $res)
52
+				if ($res->status)
53 53
 				{
54
-					$res->next_run_time = wp_next_scheduled('xcloner_scheduler_'.$res->id, array($res->id))+(get_option( 'gmt_offset' ) * HOUR_IN_SECONDS);
54
+					$res->next_run_time = wp_next_scheduled('xcloner_scheduler_'.$res->id, array($res->id)) + (get_option('gmt_offset') * HOUR_IN_SECONDS);
55 55
 					$new_list[] = $res;
56 56
 				}
57 57
 			$list = $new_list;	
@@ -77,7 +77,7 @@  discard block
 block discarded – undo
77 77
 	{
78 78
 		$data = $this->db->get_row("SELECT * FROM ".$this->scheduler_table." WHERE id=".$id, ARRAY_A);
79 79
 		
80
-		if(!$data)
80
+		if (!$data)
81 81
 			return false;
82 82
 		
83 83
 		$params = json_decode($data['params']);
@@ -94,10 +94,10 @@  discard block
 block discarded – undo
94 94
 	
95 95
 	public function delete_schedule_by_id($id)
96 96
 	{
97
-		$hook =  'xcloner_scheduler_'.$id;
98
-		wp_clear_scheduled_hook( $hook, array($id) );
97
+		$hook = 'xcloner_scheduler_'.$id;
98
+		wp_clear_scheduled_hook($hook, array($id));
99 99
 		
100
-		$data = $this->db->delete( $this->scheduler_table , array( 'id' => $id ) );
100
+		$data = $this->db->delete($this->scheduler_table, array('id' => $id));
101 101
 		
102 102
 		return $data;
103 103
 	}
@@ -106,12 +106,12 @@  discard block
 block discarded – undo
106 106
 	{
107 107
 		$list = $this->get_scheduler_list();
108 108
 		
109
-		foreach($list as $schedule)
109
+		foreach ($list as $schedule)
110 110
 		{
111
-			$hook =  'xcloner_scheduler_'.$schedule->id;
111
+			$hook = 'xcloner_scheduler_'.$schedule->id;
112 112
 			
113
-			$timestamp = wp_next_scheduled( $hook , array($schedule->id) );
114
-			wp_unschedule_event( $timestamp, $hook, array($schedule->id) );
113
+			$timestamp = wp_next_scheduled($hook, array($schedule->id));
114
+			wp_unschedule_event($timestamp, $hook, array($schedule->id));
115 115
 		}
116 116
 	}
117 117
 	
@@ -119,26 +119,26 @@  discard block
 block discarded – undo
119 119
 	{
120 120
 		$list = $this->get_scheduler_list();
121 121
 		
122
-		foreach($list as $schedule)
122
+		foreach ($list as $schedule)
123 123
 		{
124
-			$hook =  'xcloner_scheduler_'.$schedule->id;
124
+			$hook = 'xcloner_scheduler_'.$schedule->id;
125 125
 			
126 126
 			//adding the xcloner_scheduler hook with xcloner_scheduler_callback callback
127
-			add_action( $hook, array($this, 'xcloner_scheduler_callback'), 10,  1 );
127
+			add_action($hook, array($this, 'xcloner_scheduler_callback'), 10, 1);
128 128
 			
129
-			if ( ! wp_next_scheduled( $hook, array($schedule->id) ) and $schedule->status) {
129
+			if (!wp_next_scheduled($hook, array($schedule->id)) and $schedule->status) {
130 130
 				
131
-				if($schedule->recurrence == "single")
131
+				if ($schedule->recurrence == "single")
132 132
 				{
133
-					wp_schedule_single_event( strtotime($schedule->start_at), $hook, array($schedule->id));
134
-				}else{	
135
-					wp_schedule_event( strtotime($schedule->start_at), $schedule->recurrence, $hook, array($schedule->id) );
133
+					wp_schedule_single_event(strtotime($schedule->start_at), $hook, array($schedule->id));
134
+				} else {	
135
+					wp_schedule_event(strtotime($schedule->start_at), $schedule->recurrence, $hook, array($schedule->id));
136 136
 				}
137 137
 					
138
-			}elseif(!$schedule->status)
138
+			}elseif (!$schedule->status)
139 139
 			{
140
-				$timestamp = wp_next_scheduled( $hook , array($schedule->id) );
141
-				wp_unschedule_event( $timestamp, $hook, array($schedule->id) );
140
+				$timestamp = wp_next_scheduled($hook, array($schedule->id));
141
+				wp_unschedule_event($timestamp, $hook, array($schedule->id));
142 142
 			}
143 143
 		}
144 144
 	
@@ -147,18 +147,18 @@  discard block
 block discarded – undo
147 147
 	public function update_cron_hook($id)
148 148
 	{
149 149
 		$schedule = $this->get_schedule_by_id_object($id);
150
-		$hook =  'xcloner_scheduler_'.$schedule->id;
150
+		$hook = 'xcloner_scheduler_'.$schedule->id;
151 151
 		
152
-		$timestamp = wp_next_scheduled( $hook , array($schedule->id) );
153
-		wp_unschedule_event( $timestamp, $hook, array($schedule->id) );
152
+		$timestamp = wp_next_scheduled($hook, array($schedule->id));
153
+		wp_unschedule_event($timestamp, $hook, array($schedule->id));
154 154
 		
155 155
 		if ($schedule->status) {
156 156
 			
157
-			if($schedule->recurrence == "single")
157
+			if ($schedule->recurrence == "single")
158 158
 			{
159
-				wp_schedule_single_event( strtotime($schedule->start_at), $hook, array($schedule->id));
160
-			}else{	
161
-				wp_schedule_event( strtotime($schedule->start_at), $schedule->recurrence, $hook, array($schedule->id) );
159
+				wp_schedule_single_event(strtotime($schedule->start_at), $hook, array($schedule->id));
160
+			} else {	
161
+				wp_schedule_event(strtotime($schedule->start_at), $schedule->recurrence, $hook, array($schedule->id));
162 162
 			}
163 163
 				
164 164
 		}
@@ -166,16 +166,16 @@  discard block
 block discarded – undo
166 166
 	
167 167
 	public function disable_single_cron($schedule_id)
168 168
 	{
169
-		$hook =  'xcloner_scheduler_'.$schedule_id;
170
-		$timestamp = wp_next_scheduled( $hook , array($schedule_id) );
171
-		wp_unschedule_event( $timestamp, $hook, array($schedule_id) );
169
+		$hook = 'xcloner_scheduler_'.$schedule_id;
170
+		$timestamp = wp_next_scheduled($hook, array($schedule_id));
171
+		wp_unschedule_event($timestamp, $hook, array($schedule_id));
172 172
 		
173 173
 		$schedule['status'] = 0;
174 174
 		
175 175
 		$update = $this->db->update( 
176 176
 				$this->scheduler_table, 
177 177
 				$schedule, 
178
-				array( 'id' => $schedule_id ), 
178
+				array('id' => $schedule_id), 
179 179
 				array( 
180 180
 					'%s', 
181 181
 					'%s' 
@@ -191,7 +191,7 @@  discard block
 block discarded – undo
191 191
 		$update = $this->db->update( 
192 192
 				$this->scheduler_table, 
193 193
 				$schedule, 
194
-				array( 'id' => $schedule_id ), 
194
+				array('id' => $schedule_id), 
195 195
 				array( 
196 196
 					'%s', 
197 197
 					'%s' 
@@ -207,7 +207,7 @@  discard block
 block discarded – undo
207 207
 		$update = $this->db->update( 
208 208
 				$this->scheduler_table, 
209 209
 				$schedule, 
210
-				array( 'id' => $schedule_id ), 
210
+				array('id' => $schedule_id), 
211 211
 				array( 
212 212
 					'%s', 
213 213
 					'%s' 
@@ -228,25 +228,25 @@  discard block
 block discarded – undo
228 228
 		#$this->get_xcloner_container()->get_xcloner_settings()->set_hash($hash);
229 229
 		
230 230
 		//$this->xcloner_settings 		= $this->get_xcloner_container()->get_xcloner_settings();		
231
-		$this->xcloner_file_system 		= $this->get_xcloner_container()->get_xcloner_filesystem();
232
-		$this->xcloner_database 		= $this->get_xcloner_container()->get_xcloner_database();
233
-		$this->archive_system 			= $this->get_xcloner_container()->get_archive_system();
234
-		$this->logger 					= $this->get_xcloner_container()->get_xcloner_logger()->withName("xcloner_scheduler");
235
-		$this->xcloner_remote_storage 	= $this->get_xcloner_container()->get_xcloner_remote_storage();
231
+		$this->xcloner_file_system = $this->get_xcloner_container()->get_xcloner_filesystem();
232
+		$this->xcloner_database = $this->get_xcloner_container()->get_xcloner_database();
233
+		$this->archive_system = $this->get_xcloner_container()->get_archive_system();
234
+		$this->logger = $this->get_xcloner_container()->get_xcloner_logger()->withName("xcloner_scheduler");
235
+		$this->xcloner_remote_storage = $this->get_xcloner_container()->get_xcloner_remote_storage();
236 236
 		
237 237
 		$this->logger->info(sprintf("New schedule hash is %s", $this->xcloner_settings->get_hash()));
238 238
 		
239
-		if(isset($schedule['backup_params']->diff_start_date) && $schedule['backup_params']->diff_start_date)
239
+		if (isset($schedule['backup_params']->diff_start_date) && $schedule['backup_params']->diff_start_date)
240 240
 		{
241 241
 			$this->xcloner_file_system->set_diff_timestamp_start($schedule['backup_params']->diff_start_date);
242 242
 		}
243 243
 				
244
-		if($schedule['recurrence'] == "single")
244
+		if ($schedule['recurrence'] == "single")
245 245
 		{
246 246
 			$this->disable_single_cron($schedule['id']);
247 247
 		}
248 248
 		
249
-		if(!$schedule)
249
+		if (!$schedule)
250 250
 		{
251 251
 			$this->logger->info(sprintf("Could not load schedule with id'%s'", $id), array("CRON"));
252 252
 			return;
@@ -263,7 +263,7 @@  discard block
 block discarded – undo
263 263
 		$init = 1;
264 264
 		$continue = 1;
265 265
 
266
-		while($continue)
266
+		while ($continue)
267 267
 		{
268 268
 			$continue = $this->xcloner_file_system->start_file_recursion($init);
269 269
 			
@@ -277,9 +277,9 @@  discard block
 block discarded – undo
277 277
 		$init = 1;
278 278
 		$return['finished'] = 0;
279 279
 		
280
-		while(!$return['finished'])
280
+		while (!$return['finished'])
281 281
 		{
282
-			$return  = $this->xcloner_database->start_database_recursion((array)json_decode($schedule['table_params']), $return, $init);
282
+			$return = $this->xcloner_database->start_database_recursion((array)json_decode($schedule['table_params']), $return, $init);
283 283
 			$init = 0;
284 284
 		}
285 285
 		
@@ -291,7 +291,7 @@  discard block
 block discarded – undo
291 291
 		$return['finished'] = 0;
292 292
 		$return['extra'] = array();
293 293
 		
294
-		while(!$return['finished'])
294
+		while (!$return['finished'])
295 295
 		{
296 296
 			$return = $this->archive_system->start_incremental_backup((array)$schedule['backup_params'], $return['extra'], $init);
297 297
 			$init = 0;
@@ -300,38 +300,38 @@  discard block
 block discarded – undo
300 300
 		
301 301
 		//getting the last backup archive file
302 302
 		$return['extra']['backup_parent'] = $this->archive_system->get_archive_name_with_extension();
303
-		if($this->xcloner_file_system->is_part($this->archive_system->get_archive_name_with_extension()))
303
+		if ($this->xcloner_file_system->is_part($this->archive_system->get_archive_name_with_extension()))
304 304
 				$return['extra']['backup_parent'] = $this->archive_system->get_archive_name_multipart();
305 305
 				
306 306
 		$this->update_last_backup($schedule['id'], $return['extra']['backup_parent']);
307 307
 		
308
-		if(isset($schedule['remote_storage']) && $schedule['remote_storage'] && array_key_exists($schedule['remote_storage'], $this->xcloner_remote_storage->get_available_storages()))
308
+		if (isset($schedule['remote_storage']) && $schedule['remote_storage'] && array_key_exists($schedule['remote_storage'], $this->xcloner_remote_storage->get_available_storages()))
309 309
 		{
310 310
 			$backup_file = $return['extra']['backup_parent'];
311 311
 			
312 312
 			$this->logger->info(sprintf("Transferring backup to remote storage %s", strtoupper($schedule['remote_storage'])), array("CRON"));
313 313
 			
314
-			if(method_exists($this->xcloner_remote_storage, "upload_backup_to_storage"))
314
+			if (method_exists($this->xcloner_remote_storage, "upload_backup_to_storage"))
315 315
 				call_user_func_array(array($this->xcloner_remote_storage, "upload_backup_to_storage"), array($backup_file, $schedule['remote_storage']));
316 316
 		}
317 317
 		
318
-		if(isset($schedule['backup_params']->email_notification) and $to=$schedule['backup_params']->email_notification)
318
+		if (isset($schedule['backup_params']->email_notification) and $to = $schedule['backup_params']->email_notification)
319 319
 		{	
320
-			try{
320
+			try {
321 321
 				$from = "";
322 322
 				$additional['lines_total'] = $return['extra']['lines_total'];
323
-				$subject = sprintf(__("%s - new backup generated %s") , $schedule['name'], $return['extra']['backup_parent']);
323
+				$subject = sprintf(__("%s - new backup generated %s"), $schedule['name'], $return['extra']['backup_parent']);
324 324
 				
325 325
 				$this->archive_system->send_notification($to, $from, $subject, $return['extra']['backup_parent'], $schedule, "", $additional);
326 326
 				
327 327
 				//CHECK IF WE SHOULD DELETE BACKUP AFTER REMOTE TRANSFER IS DONE
328
-				if($this->xcloner_settings->get_xcloner_option('xcloner_cleanup_delete_after_remote_transfer'))
328
+				if ($this->xcloner_settings->get_xcloner_option('xcloner_cleanup_delete_after_remote_transfer'))
329 329
 				{
330
-					$this->logger->info(sprintf("Deleting %s from local storage matching rule xcloner_cleanup_delete_after_remote_transfer",$return['extra']['backup_parent']));
330
+					$this->logger->info(sprintf("Deleting %s from local storage matching rule xcloner_cleanup_delete_after_remote_transfer", $return['extra']['backup_parent']));
331 331
 					$this->xcloner_file_system->delete_backup_by_name($return['extra']['backup_parent']);
332 332
 					
333 333
 				}
334
-			}catch(Exception $e)
334
+			}catch (Exception $e)
335 335
 			{
336 336
 				$this->logger->error($e->getMessage());
337 337
 			}
@@ -344,27 +344,27 @@  discard block
 block discarded – undo
344 344
 	
345 345
 	public function xcloner_scheduler_callback($id, $schedule = "")
346 346
 	{
347
-		if($id)
347
+		if ($id)
348 348
 		{
349 349
 			$schedule = $this->get_schedule_by_id($id);
350 350
 		}
351 351
 		
352
-		try{
352
+		try {
353 353
 
354 354
 			$this->__xcloner_scheduler_callback($id, $schedule);
355 355
 			
356
-		}catch(Exception $e){
356
+		}catch (Exception $e) {
357 357
 			
358 358
 			//send email to site admin if email notification is not set in the scheduler
359
-			if(!isset($schedule['backup_params']->email_notification) || !$schedule['backup_params']->email_notification)
359
+			if (!isset($schedule['backup_params']->email_notification) || !$schedule['backup_params']->email_notification)
360 360
 			{
361 361
 				$schedule['backup_params']->email_notification = get_option('admin_email');
362 362
 			}
363 363
 				
364
-			if(isset($schedule['backup_params']->email_notification) && $to=$schedule['backup_params']->email_notification)
364
+			if (isset($schedule['backup_params']->email_notification) && $to = $schedule['backup_params']->email_notification)
365 365
 			{
366 366
 				$from = "";
367
-				$this->archive_system->send_notification($to, $from, $schedule['name']." - backup error","", "", $e->getMessage());
367
+				$this->archive_system->send_notification($to, $from, $schedule['name']." - backup error", "", "", $e->getMessage());
368 368
 			}
369 369
 			
370 370
 		}
@@ -377,10 +377,10 @@  discard block
 block discarded – undo
377 377
 		$new_schedules = array();
378 378
 		
379 379
 		foreach ($schedules as $key => $row) {
380
-			if(in_array($key, $this->allowed_schedules))
380
+			if (in_array($key, $this->allowed_schedules))
381 381
 			{
382 382
 				$new_schedules[$key] = $row;
383
-				$intervals[$key]  = $row['interval'];
383
+				$intervals[$key] = $row['interval'];
384 384
 			}
385 385
 		}
386 386
 		
Please login to merge, or discard this patch.
Braces   +17 added lines, -13 removed lines patch added patch discarded remove patch
@@ -48,10 +48,11 @@  discard block
 block discarded – undo
48 48
 		{
49 49
 			$new_list= array();
50 50
 			
51
-			foreach($list as $res)
52
-				if($res->status)
51
+			foreach($list as $res) {
52
+							if($res->status)
53 53
 				{
54 54
 					$res->next_run_time = wp_next_scheduled('xcloner_scheduler_'.$res->id, array($res->id))+(get_option( 'gmt_offset' ) * HOUR_IN_SECONDS);
55
+			}
55 56
 					$new_list[] = $res;
56 57
 				}
57 58
 			$list = $new_list;	
@@ -77,8 +78,9 @@  discard block
 block discarded – undo
77 78
 	{
78 79
 		$data = $this->db->get_row("SELECT * FROM ".$this->scheduler_table." WHERE id=".$id, ARRAY_A);
79 80
 		
80
-		if(!$data)
81
-			return false;
81
+		if(!$data) {
82
+					return false;
83
+		}
82 84
 		
83 85
 		$params = json_decode($data['params']);
84 86
 		
@@ -131,11 +133,11 @@  discard block
 block discarded – undo
131 133
 				if($schedule->recurrence == "single")
132 134
 				{
133 135
 					wp_schedule_single_event( strtotime($schedule->start_at), $hook, array($schedule->id));
134
-				}else{	
136
+				} else{	
135 137
 					wp_schedule_event( strtotime($schedule->start_at), $schedule->recurrence, $hook, array($schedule->id) );
136 138
 				}
137 139
 					
138
-			}elseif(!$schedule->status)
140
+			} elseif(!$schedule->status)
139 141
 			{
140 142
 				$timestamp = wp_next_scheduled( $hook , array($schedule->id) );
141 143
 				wp_unschedule_event( $timestamp, $hook, array($schedule->id) );
@@ -157,7 +159,7 @@  discard block
 block discarded – undo
157 159
 			if($schedule->recurrence == "single")
158 160
 			{
159 161
 				wp_schedule_single_event( strtotime($schedule->start_at), $hook, array($schedule->id));
160
-			}else{	
162
+			} else{	
161 163
 				wp_schedule_event( strtotime($schedule->start_at), $schedule->recurrence, $hook, array($schedule->id) );
162 164
 			}
163 165
 				
@@ -300,8 +302,9 @@  discard block
 block discarded – undo
300 302
 		
301 303
 		//getting the last backup archive file
302 304
 		$return['extra']['backup_parent'] = $this->archive_system->get_archive_name_with_extension();
303
-		if($this->xcloner_file_system->is_part($this->archive_system->get_archive_name_with_extension()))
304
-				$return['extra']['backup_parent'] = $this->archive_system->get_archive_name_multipart();
305
+		if($this->xcloner_file_system->is_part($this->archive_system->get_archive_name_with_extension())) {
306
+						$return['extra']['backup_parent'] = $this->archive_system->get_archive_name_multipart();
307
+		}
305 308
 				
306 309
 		$this->update_last_backup($schedule['id'], $return['extra']['backup_parent']);
307 310
 		
@@ -311,8 +314,9 @@  discard block
 block discarded – undo
311 314
 			
312 315
 			$this->logger->info(sprintf("Transferring backup to remote storage %s", strtoupper($schedule['remote_storage'])), array("CRON"));
313 316
 			
314
-			if(method_exists($this->xcloner_remote_storage, "upload_backup_to_storage"))
315
-				call_user_func_array(array($this->xcloner_remote_storage, "upload_backup_to_storage"), array($backup_file, $schedule['remote_storage']));
317
+			if(method_exists($this->xcloner_remote_storage, "upload_backup_to_storage")) {
318
+							call_user_func_array(array($this->xcloner_remote_storage, "upload_backup_to_storage"), array($backup_file, $schedule['remote_storage']));
319
+			}
316 320
 		}
317 321
 		
318 322
 		if(isset($schedule['backup_params']->email_notification) and $to=$schedule['backup_params']->email_notification)
@@ -331,7 +335,7 @@  discard block
 block discarded – undo
331 335
 					$this->xcloner_file_system->delete_backup_by_name($return['extra']['backup_parent']);
332 336
 					
333 337
 				}
334
-			}catch(Exception $e)
338
+			} catch(Exception $e)
335 339
 			{
336 340
 				$this->logger->error($e->getMessage());
337 341
 			}
@@ -353,7 +357,7 @@  discard block
 block discarded – undo
353 357
 
354 358
 			$this->__xcloner_scheduler_callback($id, $schedule);
355 359
 			
356
-		}catch(Exception $e){
360
+		} catch(Exception $e){
357 361
 			
358 362
 			//send email to site admin if email notification is not set in the scheduler
359 363
 			if(!isset($schedule['backup_params']->email_notification) || !$schedule['backup_params']->email_notification)
Please login to merge, or discard this patch.
admin/partials/xcloner_restore_page.php 1 patch
Spacing   +65 added lines, -65 removed lines patch added patch discarded remove patch
@@ -1,11 +1,11 @@  discard block
 block discarded – undo
1 1
 <?php
2 2
 
3
-$xcloner_settings 		= $this->get_xcloner_container()->get_xcloner_settings();
4
-$logger					= $this->get_xcloner_container()->get_xcloner_logger();
5
-$xcloner_file_system 	= $this->get_xcloner_container()->get_xcloner_filesystem();
6
-$xcloner_file_transfer 	= $this->get_xcloner_container()->get_xcloner_file_transfer();
3
+$xcloner_settings = $this->get_xcloner_container()->get_xcloner_settings();
4
+$logger = $this->get_xcloner_container()->get_xcloner_logger();
5
+$xcloner_file_system = $this->get_xcloner_container()->get_xcloner_filesystem();
6
+$xcloner_file_transfer = $this->get_xcloner_container()->get_xcloner_file_transfer();
7 7
 
8
-$start = 0 ;
8
+$start = 0;
9 9
 
10 10
 $backup_list = $xcloner_file_system->get_latest_backups();
11 11
 
@@ -21,24 +21,24 @@  discard block
 block discarded – undo
21 21
 	<div class="col s12">
22 22
 		<ul class="collapsible xcloner-restore " data-collapsible="accordion">
23 23
 			<li data-step="1" class="restore-script-upload-step steps active show">
24
-				<div class="collapsible-header active"><i class="material-icons">settings_remote</i><?php echo __("Restore Script Upload",'xcloner-backup-and-restore')?></div>
24
+				<div class="collapsible-header active"><i class="material-icons">settings_remote</i><?php echo __("Restore Script Upload", 'xcloner-backup-and-restore')?></div>
25 25
 				<div class="collapsible-body row">
26 26
 						
27 27
 						<ul class="text-steps">
28
-							<li><?php echo __("If you want to do a <strong>Local Target System Restore</strong>, leave Url field below empty and click 'Check Connection', you can skip the next steps.",'xcloner-backup-and-restore')?> 
28
+							<li><?php echo __("If you want to do a <strong>Local Target System Restore</strong>, leave Url field below empty and click 'Check Connection', you can skip the next steps.", 'xcloner-backup-and-restore')?> 
29 29
 							</li>	
30
-							<li><?php echo __("If you want to do a <strong>Remote Target System Restore</strong>, please download the restore script from",'xcloner-backup-and-restore')?> <a href='#' onclick="window.location=ajaxurl+'?action=download_restore_script&phar=true'"><strong><?php echo __("here",'xcloner-backup-and-restore')?></strong></a>
30
+							<li><?php echo __("If you want to do a <strong>Remote Target System Restore</strong>, please download the restore script from", 'xcloner-backup-and-restore')?> <a href='#' onclick="window.location=ajaxurl+'?action=download_restore_script&phar=true'"><strong><?php echo __("here", 'xcloner-backup-and-restore')?></strong></a>
31 31
 							</li>	
32 32
 							<li>
33
-							<?php echo __("Extract the restore script archive files on your new host",'xcloner-backup-and-restore')?>
33
+							<?php echo __("Extract the restore script archive files on your new host", 'xcloner-backup-and-restore')?>
34 34
 							</li>
35 35
 							<li>
36
-							<?php echo __("Provide url below to the <u>xcloner_restore.php</u> restore script, like http://my_restore_site.com/xcloner_restore.php",'xcloner-backup-and-restore')?>
36
+							<?php echo __("Provide url below to the <u>xcloner_restore.php</u> restore script, like http://my_restore_site.com/xcloner_restore.php", 'xcloner-backup-and-restore')?>
37 37
 							</li>
38 38
 							<li>
39
-							<?php echo __("If your server is not web accessible, like a localhost computer, you can use a DynDNS service or install a blank copy of Wordpress with XCloner in the same environment and start the restore from there.",'xcloner-backup-and-restore')?>
39
+							<?php echo __("If your server is not web accessible, like a localhost computer, you can use a DynDNS service or install a blank copy of Wordpress with XCloner in the same environment and start the restore from there.", 'xcloner-backup-and-restore')?>
40 40
 							</li>
41
-							<?php if(is_ssl()):?>
41
+							<?php if (is_ssl()):?>
42 42
 							<li class="warning">
43 43
 								<?php echo __("We have detected your connection to the site as being secure, so your restore script address must start with https://.")?>
44 44
 							</li>
@@ -47,12 +47,12 @@  discard block
 block discarded – undo
47 47
 						</ul>	
48 48
 						
49 49
 						<div class="input-field col l9 s12">
50
-							<input value="<?php echo (is_ssl())?"https://":""?>" id="restore_script_url" type="text" class="validate" placeholder="Url to XCloner Restore Script, example http://myddns.com/xcloner/xcloner_restore.php" >
50
+							<input value="<?php echo (is_ssl()) ? "https://" : ""?>" id="restore_script_url" type="text" class="validate" placeholder="Url to XCloner Restore Script, example http://myddns.com/xcloner/xcloner_restore.php" >
51 51
 							<label for="restore_script_url"></label>
52 52
 							<div id="url_validation_status" class="status"></div>
53 53
 				        </div>
54 54
 				        <div class="col l3 s12 right-align">
55
-							<button class="btn waves-effect waves-light" type="submit" id="validate_url" name="action"><?php echo __("Check Connection",'xcloner-backup-and-restore')?>
55
+							<button class="btn waves-effect waves-light" type="submit" id="validate_url" name="action"><?php echo __("Check Connection", 'xcloner-backup-and-restore')?>
56 56
 							    <i class="material-icons right">send</i>
57 57
 							</button>
58 58
 				        </div>
@@ -60,15 +60,15 @@  discard block
 block discarded – undo
60 60
 			</li>
61 61
 			
62 62
 			<li data-step="2" class="backup-upload-step steps">
63
-				<div class="collapsible-header active"><i class="material-icons">file_upload</i><?php echo __("Upload Local Backup Archive To Target Host",'xcloner-backup-and-restore')?>
63
+				<div class="collapsible-header active"><i class="material-icons">file_upload</i><?php echo __("Upload Local Backup Archive To Target Host", 'xcloner-backup-and-restore')?>
64 64
 				</div>
65 65
 				<div class="collapsible-body row">
66
-					<p><?php echo __("You can skip this step if you want to transfer the archive in some other way, make sure you upload it in the same directory as the restore script from the previous step.",'xcloner-backup-and-restore')?></p>
66
+					<p><?php echo __("You can skip this step if you want to transfer the archive in some other way, make sure you upload it in the same directory as the restore script from the previous step.", 'xcloner-backup-and-restore')?></p>
67 67
 					<div class="input-field col s12 l7">
68 68
 						<select id="backup_file" name="backup_file" class="browser-default">
69
-					      <option value="" disabled selected><?php echo __("Please select a local backup archive to upload to target host",'xcloner-backup-and-restore')?></option>
70
-					      <?php if(is_array($backup_list)):?>
71
-							<?php foreach($backup_list as $file):?>
69
+					      <option value="" disabled selected><?php echo __("Please select a local backup archive to upload to target host", 'xcloner-backup-and-restore')?></option>
70
+					      <?php if (is_array($backup_list)):?>
71
+							<?php foreach ($backup_list as $file):?>
72 72
 								<option value="<?php echo $file['basename']?>">
73 73
 								<?php echo $file['basename']?> (<?php echo size_format($file['size'])?>)
74 74
 								</option>
@@ -84,14 +84,14 @@  discard block
 block discarded – undo
84 84
 					</div>
85 85
 					<div class="col s12 l5 right-align">
86 86
 						<div class="toggler">
87
-							<button class="btn waves-effect waves-light upload-backup normal" type="submit" id="" name="action"><?php echo __("Upload",'xcloner-backup-and-restore')?>
87
+							<button class="btn waves-effect waves-light upload-backup normal" type="submit" id="" name="action"><?php echo __("Upload", 'xcloner-backup-and-restore')?>
88 88
 							    <i class="material-icons left">navigate_before</i>
89 89
 							</button>
90
-							<button class="btn waves-effect waves-light red upload-backup cancel" type="submit" id="" name="action"><?php echo __("Cancel",'xcloner-backup-and-restore')?>
90
+							<button class="btn waves-effect waves-light red upload-backup cancel" type="submit" id="" name="action"><?php echo __("Cancel", 'xcloner-backup-and-restore')?>
91 91
 							    <i class="material-icons right">close</i>
92 92
 							</button>
93 93
 						</div>
94
-						<button class="btn waves-effect waves-light grey" type="submit" title="<?php echo __("Skip Next",'xcloner-backup-and-restore')?>" id="skip_upload_backup" name="action"><?php echo __("Skip Next",'xcloner-backup-and-restore')?>
94
+						<button class="btn waves-effect waves-light grey" type="submit" title="<?php echo __("Skip Next", 'xcloner-backup-and-restore')?>" id="skip_upload_backup" name="action"><?php echo __("Skip Next", 'xcloner-backup-and-restore')?>
95 95
 						    <i class="material-icons right">navigate_next</i>
96 96
 						</button>
97 97
 					</div>
@@ -99,7 +99,7 @@  discard block
 block discarded – undo
99 99
 			</li>	
100 100
 			
101 101
 			<li data-step="3" class="restore-remote-backup-step steps active">
102
-				<div class="collapsible-header"><i class="material-icons">folder_open</i><?php echo __("Restore Files Backup Available On Target Location",'xcloner-backup-and-restore')?>
102
+				<div class="collapsible-header"><i class="material-icons">folder_open</i><?php echo __("Restore Files Backup Available On Target Location", 'xcloner-backup-and-restore')?>
103 103
 						<i class="material-icons right" title="Refresh Target Backup Files List" id="refresh_remote_backup_file">cached</i>
104 104
 
105 105
 						<div class="switch right">
@@ -120,7 +120,7 @@  discard block
 block discarded – undo
120 120
 										data-tooltip="<?php echo __("This is the directory where you would like to restore the backup archive files.<br /> 
121 121
 										Please use this with caution when restoring to a live site.",'xcloner-backup-and-restore')?>"><i class="material-icons">help_outline</i>
122 122
 									</a>	
123
-									<h5><?php echo __("Restore Target Path:",'xcloner-backup-and-restore')?></h5>
123
+									<h5><?php echo __("Restore Target Path:", 'xcloner-backup-and-restore')?></h5>
124 124
 									<input type="text" name="remote_restore_path" id="remote_restore_path" class="validate" placeholder="Restore Target Path">
125 125
 									<label></label>
126 126
 								</div>
@@ -133,40 +133,40 @@  discard block
 block discarded – undo
133 133
 									class="list-backup-content btn-floating tooltipped btn-small right" data-tooltip="<?php echo __('Click To List The Selected Backup Content', 'xcloner-backup-and-restore') ?>">
134 134
 										<i class="material-icons">folder_open</i>
135 135
 									</a>
136
-									<h5><?php echo __("Restore Backup Archive:",'xcloner-backup-and-restore')?></h5>
136
+									<h5><?php echo __("Restore Backup Archive:", 'xcloner-backup-and-restore')?></h5>
137 137
 									<select id="remote_backup_file" name="remote_backup_file" class="browser-default">
138
-										<option value="" disabled selected><?php echo __("Please select the target backup file to restore",'xcloner-backup-and-restore')?></option>
138
+										<option value="" disabled selected><?php echo __("Please select the target backup file to restore", 'xcloner-backup-and-restore')?></option>
139 139
 								    </select>
140 140
 								    <label></label>
141 141
 							    </div>
142 142
 							
143 143
 								<div class="col s12">
144 144
 									<input class="with-gap" name="filter_files" type="radio" id="filter_files_all" checked value="" disabled />
145
-									<label for="filter_files_all" class="tooltipped" data-position="right" data-tooltip="<?php echo __("Restore all backup files. Available only when doing a Remote Target System Restore", 'xcloner-backup-and-restore')?>"><?php echo __("Restore All Files","xcloner-backup-and-restore")?></label>
145
+									<label for="filter_files_all" class="tooltipped" data-position="right" data-tooltip="<?php echo __("Restore all backup files. Available only when doing a Remote Target System Restore", 'xcloner-backup-and-restore')?>"><?php echo __("Restore All Files", "xcloner-backup-and-restore")?></label>
146 146
 									
147 147
 									<input class="with-gap" name="filter_files" type="radio" id="filter_files_wp_content"  value="/^wp-content\/(.*)/" />
148 148
 									<label for="filter_files_wp_content" class="tooltipped" data-tooltip="<?php echo __('Restore the files only of the wp-content/ folder', 'xcloner-backup-and-restore')?>">
149
-										<?php echo __("Only wp-content","xcloner-backup-and-restore")?>
149
+										<?php echo __("Only wp-content", "xcloner-backup-and-restore")?>
150 150
 									</label>
151 151
 									
152 152
 									<input class="with-gap" name="filter_files" type="radio" id="filter_files_plugins"  value="/^wp-content\/plugins(.*)/" />
153 153
 									<label for="filter_files_plugins" class="tooltipped" data-tooltip="<?php echo __('Restore the files only of the wp-content/plugins/ folder', 'xcloner-backup-and-restore')?>">
154
-										<?php echo __("Only Plugins","xcloner-backup-and-restore")?>
154
+										<?php echo __("Only Plugins", "xcloner-backup-and-restore")?>
155 155
 									</label>
156 156
 
157 157
 									<input class="with-gap" name="filter_files" type="radio" id="filter_files_uploads"  value="/^wp-content\/uploads(.*)/" />
158 158
 									<label for="filter_files_uploads" class="tooltipped" data-tooltip="<?php echo __('Restore the files only of the wp-content/uploads/ folder only', 'xcloner-backup-and-restore')?>">
159
-										<?php echo __("Only Uploads","xcloner-backup-and-restore")?>
159
+										<?php echo __("Only Uploads", "xcloner-backup-and-restore")?>
160 160
 									</label>
161 161
 									
162 162
 									<input class="with-gap" name="filter_files" type="radio" id="filter_files_themes"  value="/^wp-content\/themes(.*)/" />
163 163
 									<label for="filter_files_themes" class="tooltipped" data-tooltip="<?php echo __('Restore the files only of the wp-content/themes/ folder', 'xcloner-backup-and-restore')?>">
164
-										<?php echo __("Only Themes","xcloner-backup-and-restore")?>
164
+										<?php echo __("Only Themes", "xcloner-backup-and-restore")?>
165 165
 									</label>
166 166
 									
167 167
 									<input class="with-gap" name="filter_files" type="radio" id="filter_files_database"  value="/^xcloner-(.*)\/(.*)\.sql/"/>
168 168
 									<label for="filter_files_database" class="tooltipped" data-tooltip="<?php echo __('Restore the database-sql.sql mysql backup from the xcloner-xxxxx/ folder', 'xcloner-backup-and-restore')?>">
169
-										<?php echo __("Only Database Backup","xcloner-backup-and-restore")?>
169
+										<?php echo __("Only Database Backup", "xcloner-backup-and-restore")?>
170 170
 									</label>
171 171
 								</div>
172 172
 							</div>
@@ -181,14 +181,14 @@  discard block
 block discarded – undo
181 181
 				       
182 182
 				        <div class="col s12 l5 right-align">
183 183
 							<div class="toggler">
184
-								<button class="btn waves-effect waves-light restore_remote_backup normal " type="submit" id="" name="action"><?php echo __("Restore",'xcloner-backup-and-restore')?>
184
+								<button class="btn waves-effect waves-light restore_remote_backup normal " type="submit" id="" name="action"><?php echo __("Restore", 'xcloner-backup-and-restore')?>
185 185
 								    <i class="material-icons left">navigate_before</i>
186 186
 								</button>
187
-								<button class="btn waves-effect waves-light red restore_remote_backup cancel" type="submit" id="" name="action"><?php echo __("Cancel",'xcloner-backup-and-restore')?>
187
+								<button class="btn waves-effect waves-light red restore_remote_backup cancel" type="submit" id="" name="action"><?php echo __("Cancel", 'xcloner-backup-and-restore')?>
188 188
 								    <i class="material-icons right">close</i>
189 189
 								</button>
190 190
 							</div>
191
-							<button class="btn waves-effect waves-light grey" type="submit" title="<?php echo __("Skip Next",'xcloner-backup-and-restore')?>" id="skip_remote_backup_step" name="action"><?php echo __("Skip Next",'xcloner-backup-and-restore')?>
191
+							<button class="btn waves-effect waves-light grey" type="submit" title="<?php echo __("Skip Next", 'xcloner-backup-and-restore')?>" id="skip_remote_backup_step" name="action"><?php echo __("Skip Next", 'xcloner-backup-and-restore')?>
192 192
 								<i class="material-icons right">navigate_next</i>
193 193
 							</button>
194 194
 				        </div>
@@ -196,66 +196,66 @@  discard block
 block discarded – undo
196 196
 			</li>
197 197
 			
198 198
 			<li data-step="4" class="restore-remote-database-step steps active">
199
-				<div class="collapsible-header"><i class="material-icons">list</i><?php echo __("Restore Target Database - Search and Replace",'xcloner-backup-and-restore')?>
199
+				<div class="collapsible-header"><i class="material-icons">list</i><?php echo __("Restore Target Database - Search and Replace", 'xcloner-backup-and-restore')?>
200 200
 					<i class="material-icons right" title="Refresh Database Backup Files List" id="refresh_database_file">cached</i>
201 201
 				</div>
202 202
 				<div class="collapsible-body row">
203 203
 						
204 204
 						<div id="remote-restore-options">
205 205
 						<div class="col s12">
206
-							<a class="btn-floating tooltipped btn-small right" data-position="left" data-delay="50" data-html="true" data-tooltip="<?php echo __('Please provide below the mysql connection details for the target host database.<br />For live sites we recommend using a new separate database.','xcloner-backup-and-restore')?>" data-tooltip-id="92c95730-94e9-7b59-bd52-14adc30d5e3e"><i class="material-icons">help_outline</i></a>	
207
-							<h5><?php echo __('Target Mysql Details','xcloner-backup-and-restore')?></h5>
206
+							<a class="btn-floating tooltipped btn-small right" data-position="left" data-delay="50" data-html="true" data-tooltip="<?php echo __('Please provide below the mysql connection details for the target host database.<br />For live sites we recommend using a new separate database.', 'xcloner-backup-and-restore')?>" data-tooltip-id="92c95730-94e9-7b59-bd52-14adc30d5e3e"><i class="material-icons">help_outline</i></a>	
207
+							<h5><?php echo __('Target Mysql Details', 'xcloner-backup-and-restore')?></h5>
208 208
 						</div>						
209 209
 						<div class=" col s12">
210 210
 							<div class="input-field col s12 m6">
211 211
 								<input type="text" name="remote_mysql_host" id="remote_mysql_host" class="validate" placeholder="Target Mysql Hostname">
212
-								<label><?php echo __("Target Mysql Hostname",'xcloner-backup-and-restore')?></label>
212
+								<label><?php echo __("Target Mysql Hostname", 'xcloner-backup-and-restore')?></label>
213 213
 							</div>
214 214
 							
215 215
 							<div class="input-field  col s12 m6">
216 216
 								<input type="text" name="remote_mysql_db" id="remote_mysql_db" class="validate" placeholder="Target Mysql Database">
217
-								<label><?php echo __("Target Mysql Database",'xcloner-backup-and-restore')?></label>
217
+								<label><?php echo __("Target Mysql Database", 'xcloner-backup-and-restore')?></label>
218 218
 							</div>
219 219
 							
220 220
 							<div class="input-field  col s12 m6">
221 221
 								<input type="text" name="remote_mysql_user" id="remote_mysql_user" class="validate" placeholder="Target Mysql Username">
222
-								<label><?php echo __("Target Mysql Username",'xcloner-backup-and-restore')?></label>
222
+								<label><?php echo __("Target Mysql Username", 'xcloner-backup-and-restore')?></label>
223 223
 							</div>
224 224
 							
225 225
 							
226 226
 							<div class="input-field  col s12 m6">
227 227
 								<input type="text" name="remote_mysql_pass" id="remote_mysql_pass" class="validate" placeholder="Target Mysql Password">
228
-								<label><?php echo __("Target Mysql Password",'xcloner-backup-and-restore')?></label>
228
+								<label><?php echo __("Target Mysql Password", 'xcloner-backup-and-restore')?></label>
229 229
 							</div>
230 230
 							
231 231
 						</div>	
232 232
 						<div class="col s12">
233
-						<a class="btn-floating tooltipped btn-small right" data-position="left" data-delay="50" data-html="true" data-tooltip="<?php echo __('I will attempt to replace all mysql backup records matching the provided Source Url with the provided Target Url. <br />Leave blank the Target Url if you would like to skip this option. <br />As a bonus, I will also replace all matching serialized data and fix it\'s parsing.','xcloner-backup-and-restore')?>" data-tooltip-id="92c95730-94e9-7b59-bd52-14adc30d5e3e"><i class="material-icons">help_outline</i></a>	
234
-							<h5><?php echo __('Target Mysql Search and Replace','xcloner-backup-and-restore')?></h5>
233
+						<a class="btn-floating tooltipped btn-small right" data-position="left" data-delay="50" data-html="true" data-tooltip="<?php echo __('I will attempt to replace all mysql backup records matching the provided Source Url with the provided Target Url. <br />Leave blank the Target Url if you would like to skip this option. <br />As a bonus, I will also replace all matching serialized data and fix it\'s parsing.', 'xcloner-backup-and-restore')?>" data-tooltip-id="92c95730-94e9-7b59-bd52-14adc30d5e3e"><i class="material-icons">help_outline</i></a>	
234
+							<h5><?php echo __('Target Mysql Search and Replace', 'xcloner-backup-and-restore')?></h5>
235 235
 						</div>
236 236
 						<div class="col s12">  
237 237
 							<div class="input-field col s12 m6 ">
238
-									<input type="text" name="wp_home_url" id="wp_home_url" class="validate" placeholder="WP Home Url" value="<?php echo home_url();?>">
239
-									<label><?php echo __("Source Home Url",'xcloner-backup-and-restore')?></label>
238
+									<input type="text" name="wp_home_url" id="wp_home_url" class="validate" placeholder="WP Home Url" value="<?php echo home_url(); ?>">
239
+									<label><?php echo __("Source Home Url", 'xcloner-backup-and-restore')?></label>
240 240
 							</div>	
241 241
 							
242 242
 							<div class="input-field col s12 m6 ">
243 243
 									<input type="text" name="remote_restore_url" id="remote_restore_url" class="validate" placeholder="Restore Target Url">
244
-									<label><?php echo __("With Target Home Url",'xcloner-backup-and-restore')?></label>
244
+									<label><?php echo __("With Target Home Url", 'xcloner-backup-and-restore')?></label>
245 245
 							</div>
246 246
 						
247
-						<?php if( site_url() != home_url()) : ?>
247
+						<?php if (site_url() != home_url()) : ?>
248 248
 							<div class="input-field col s12 m6 ">
249
-									<input type="text" name="wp_site_url" id="wp_site_url" class="validate" placeholder="WP Site Url" value="<?php echo site_url();?>">
250
-									<label><?php echo __("Source Site Url",'xcloner-backup-and-restore')?></label>
249
+									<input type="text" name="wp_site_url" id="wp_site_url" class="validate" placeholder="WP Site Url" value="<?php echo site_url(); ?>">
250
+									<label><?php echo __("Source Site Url", 'xcloner-backup-and-restore')?></label>
251 251
 							</div>	
252 252
 							
253 253
 							<div class="input-field col s12 m6 ">
254 254
 									<input type="text" name="remote_restore_site_url" id="remote_restore_site_url" class="validate" placeholder="Restore Target Url">
255
-									<label><?php echo __("With Target Site Url",'xcloner-backup-and-restore')?></label>
255
+									<label><?php echo __("With Target Site Url", 'xcloner-backup-and-restore')?></label>
256 256
 							</div>
257 257
 						
258
-						<?php endif;?>
258
+						<?php endif; ?>
259 259
 						</div>
260 260
 						
261 261
 						</div>
@@ -263,7 +263,7 @@  discard block
 block discarded – undo
263 263
 						<div class=" col s12 l7">
264 264
 							<div class="input-field row">
265 265
 								<select id="remote_database_file" name="remote_database_file" class="browser-default">
266
-									<option value="" disabled selected><?php echo __("Please select the target database backup file to restore",'xcloner-backup-and-restore')?></option>
266
+									<option value="" disabled selected><?php echo __("Please select the target database backup file to restore", 'xcloner-backup-and-restore')?></option>
267 267
 							    </select>
268 268
 							    
269 269
 							    <label></label>
@@ -282,15 +282,15 @@  discard block
 block discarded – undo
282 282
 				      
283 283
 				        <div class="col s12 l5 right-align">
284 284
 							<div class="toggler">
285
-								<button class="btn waves-effect waves-light restore_remote_mysqldump normal " type="submit" id="" name="action"><?php echo __("Restore",'xcloner-backup-and-restore')?>
285
+								<button class="btn waves-effect waves-light restore_remote_mysqldump normal " type="submit" id="" name="action"><?php echo __("Restore", 'xcloner-backup-and-restore')?>
286 286
 								    <i class="material-icons left">navigate_before</i>
287 287
 								</button>
288
-								<button class="btn waves-effect waves-light red restore_remote_mysqldump cancel" type="submit" id="" name="action"><?php echo __("Cancel",'xcloner-backup-and-restore')?>
288
+								<button class="btn waves-effect waves-light red restore_remote_mysqldump cancel" type="submit" id="" name="action"><?php echo __("Cancel", 'xcloner-backup-and-restore')?>
289 289
 								    <i class="material-icons right">close</i>
290 290
 								</button>
291 291
 							</div>
292 292
 							
293
-							<button class="btn waves-effect waves-light grey" type="submit" title="<?php echo __("Skip Next",'xcloner-backup-and-restore')?>" id="skip_restore_remote_database_step" name="action"><?php echo __("Skip Next",'xcloner-backup-and-restore')?>
293
+							<button class="btn waves-effect waves-light grey" type="submit" title="<?php echo __("Skip Next", 'xcloner-backup-and-restore')?>" id="skip_restore_remote_database_step" name="action"><?php echo __("Skip Next", 'xcloner-backup-and-restore')?>
294 294
 								<i class="material-icons right">navigate_next</i>
295 295
 							</button>
296 296
 							
@@ -300,13 +300,13 @@  discard block
 block discarded – undo
300 300
 			</li>
301 301
 			
302 302
 			<li data-step="5" class="restore-finish-step steps active">
303
-				<div class="collapsible-header"><i class="material-icons">folder_open</i><?php echo __("Finishing up...",'xcloner-backup-and-restore')?>
303
+				<div class="collapsible-header"><i class="material-icons">folder_open</i><?php echo __("Finishing up...", 'xcloner-backup-and-restore')?>
304 304
 				</div>
305 305
 				<div class="collapsible-body row">
306 306
 						
307 307
 						<div class="row">
308 308
 							<div class="col s4">
309
-								<label><?php echo __("Update wp-config.php mysql details and update the Target Site Url",'xcloner-backup-and-restore')?></label>
309
+								<label><?php echo __("Update wp-config.php mysql details and update the Target Site Url", 'xcloner-backup-and-restore')?></label>
310 310
 							</div>
311 311
 							
312 312
 							<div class="col s8">
@@ -323,7 +323,7 @@  discard block
 block discarded – undo
323 323
 						
324 324
 						<div class="row">
325 325
 							<div class="col s4">
326
-								<label><?php echo __("Delete Restored Backup Temporary Folder",'xcloner-backup-and-restore')?></label>
326
+								<label><?php echo __("Delete Restored Backup Temporary Folder", 'xcloner-backup-and-restore')?></label>
327 327
 							</div>
328 328
 							<div class="col s8">
329 329
 								<div class="switch">
@@ -339,7 +339,7 @@  discard block
 block discarded – undo
339 339
 						
340 340
 						<div class="row">
341 341
 							<div class="col s4">
342
-								<label><?php echo __("Delete Restore Script",'xcloner-backup-and-restore')?></label>
342
+								<label><?php echo __("Delete Restore Script", 'xcloner-backup-and-restore')?></label>
343 343
 							</div>
344 344
 							<div class="col s8">
345 345
 								<div class="switch">
@@ -358,8 +358,8 @@  discard block
 block discarded – undo
358 358
 				        </div>
359 359
 				        
360 360
 						<div class=" row col s12 center-align" id="xcloner_restore_finish">
361
-							<h5><?php echo __("Thank you for using XCloner.",'xcloner-backup-and-restore')?></h5>
362
-							<h6><?php echo sprintf(__("We would love to hear about your experience in the %s.", 'xcloner-backup-and-restore'),'<a href="https://wordpress.org/support/plugin/xcloner-backup-and-restore" target="_blank">Wordpress XCloner forums</a>') ?></h6>
361
+							<h5><?php echo __("Thank you for using XCloner.", 'xcloner-backup-and-restore')?></h5>
362
+							<h6><?php echo sprintf(__("We would love to hear about your experience in the %s.", 'xcloner-backup-and-restore'), '<a href="https://wordpress.org/support/plugin/xcloner-backup-and-restore" target="_blank">Wordpress XCloner forums</a>') ?></h6>
363 363
 							<a class="twitter-follow-button" href="https://twitter.com/thinkovi" data-show-count="false">Follow @thinkovi</a>
364 364
 							<script src="//platform.twitter.com/widgets.js" async="" charset="utf-8"></script>
365 365
 				        </div>
@@ -367,13 +367,13 @@  discard block
 block discarded – undo
367 367
 				        <div class="col s12 center-align">
368 368
 							<div class="row">
369 369
 								<div class="col s6 right-align">
370
-								<button class="btn waves-effect waves-light teal" type="submit" id="restore_finish" name="action"><?php echo __("Finish",'xcloner-backup-and-restore')?>
370
+								<button class="btn waves-effect waves-light teal" type="submit" id="restore_finish" name="action"><?php echo __("Finish", 'xcloner-backup-and-restore')?>
371 371
 									<i class="material-icons right">navigate_next</i>
372 372
 								</button>
373 373
 								</div>
374 374
 									
375 375
 								<div id="open_target_site" class="col s6 left-align">
376
-									<a disabled="disabled" href="#" class="btn waves-effect waves-light teal" type="button" target="_blank"><?php echo __("Open Target Site",'xcloner-backup-and-restore')?>
376
+									<a disabled="disabled" href="#" class="btn waves-effect waves-light teal" type="button" target="_blank"><?php echo __("Open Target Site", 'xcloner-backup-and-restore')?>
377 377
 										<i class="material-icons right">navigate_next</i>
378 378
 									</a>
379 379
 								</div>
@@ -391,7 +391,7 @@  discard block
 block discarded – undo
391 391
 <!-- List Backup Content Modal-->
392 392
 <div id="backup_cotent_modal" class="modal">
393 393
 	<div class="modal-content">
394
-		<h4><?php echo sprintf(__("Listing Backup Content ",'xcloner-backup-and-restore'), "")?></h4>
394
+		<h4><?php echo sprintf(__("Listing Backup Content ", 'xcloner-backup-and-restore'), "")?></h4>
395 395
 		<h5 class="backup-name"></h5>
396 396
 		
397 397
 		<div class="progress">
Please login to merge, or discard this patch.
admin/partials/xcloner_remote_storage_page.php 2 patches
Braces   +8 added lines, -3 removed lines patch added patch discarded remove patch
@@ -3,8 +3,9 @@  discard block
 block discarded – undo
3 3
 
4 4
 $gdrive_auth_url = "";
5 5
 
6
-if(method_exists($remote_storage, "get_gdrive_auth_url"))
6
+if(method_exists($remote_storage, "get_gdrive_auth_url")) {
7 7
 	$gdrive_auth_url = $remote_storage->get_gdrive_auth_url();
8
+}
8 9
 
9 10
 $gdrive_construct = $remote_storage->gdrive_construct();
10 11
 ?>
@@ -24,7 +25,8 @@  discard block
 block discarded – undo
24 25
 					<div class="switch right">
25 26
 						<label>
26 27
 						Off
27
-						<input type="checkbox" name="xcloner_ftp_enable" class="status" value="1" <?php if(get_option("xcloner_ftp_enable")) echo "checked"?> \>
28
+						<input type="checkbox" name="xcloner_ftp_enable" class="status" value="1" <?php if(get_option("xcloner_ftp_enable")) {
29
+	echo "checked"?> \>
28 30
 						<span class="lever"></span>
29 31
 						On
30 32
 						</label>
@@ -280,6 +282,7 @@  discard block
 block discarded – undo
280 282
 							<option readonly value=""><?php echo __("Please Select AWS Region")?></option>
281 283
 							<?php 							
282 284
 							$aws_regions = $remote_storage->get_aws_regions();
285
+}
283 286
 							
284 287
 							foreach($aws_regions as $key=>$region){
285 288
 								?>
@@ -332,7 +335,8 @@  discard block
 block discarded – undo
332 335
 					<div class="switch right">
333 336
 						<label>
334 337
 						Off
335
-						<input type="checkbox" name="xcloner_dropbox_enable" class="status" value="1" <?php if(get_option("xcloner_dropbox_enable")) echo "checked"?> \>
338
+						<input type="checkbox" name="xcloner_dropbox_enable" class="status" value="1" <?php if(get_option("xcloner_dropbox_enable")) {
339
+	echo "checked"?> \>
336 340
 						<span class="lever"></span>
337 341
 						On
338 342
 						</label>
@@ -751,6 +755,7 @@  discard block
 block discarded – undo
751 755
 								<div class="center">
752 756
 									<?php 
753 757
 										$url = wp_nonce_url(self_admin_url('update.php?action=install-plugin&plugin=xcloner-google-drive'), 'install-plugin_xcloner-google-drive');
758
+}
754 759
 									?>
755 760
 									<h6><?php echo __("This storage option requires the XCloner-Google-Drive Wordpress Plugin to be installed and activated.")?></h6>
756 761
 									<h6><?php echo __("PHP 5.5 minimum version is required.")?></h6>
Please login to merge, or discard this patch.
Spacing   +136 added lines, -136 removed lines patch added patch discarded remove patch
@@ -3,7 +3,7 @@  discard block
 block discarded – undo
3 3
 
4 4
 $gdrive_auth_url = "";
5 5
 
6
-if(method_exists($remote_storage, "get_gdrive_auth_url"))
6
+if (method_exists($remote_storage, "get_gdrive_auth_url"))
7 7
 	$gdrive_auth_url = $remote_storage->get_gdrive_auth_url();
8 8
 
9 9
 $gdrive_construct = $remote_storage->gdrive_construct();
@@ -20,11 +20,11 @@  discard block
 block discarded – undo
20 20
 			<!-- FTP STORAGE-->
21 21
 			<li id="ftp">
22 22
 				<div class="collapsible-header">
23
-					<i class="material-icons">computer</i><?php echo __("FTP Storage",'xcloner-backup-and-restore')?>
23
+					<i class="material-icons">computer</i><?php echo __("FTP Storage", 'xcloner-backup-and-restore')?>
24 24
 					<div class="switch right">
25 25
 						<label>
26 26
 						Off
27
-						<input type="checkbox" name="xcloner_ftp_enable" class="status" value="1" <?php if(get_option("xcloner_ftp_enable")) echo "checked"?> \>
27
+						<input type="checkbox" name="xcloner_ftp_enable" class="status" value="1" <?php if (get_option("xcloner_ftp_enable")) echo "checked"?> \>
28 28
 						<span class="lever"></span>
29 29
 						On
30 30
 						</label>
@@ -33,96 +33,96 @@  discard block
 block discarded – undo
33 33
 				<div class="collapsible-body">
34 34
 					<div class="row">
35 35
 						<div class="col s12 m3 label">
36
-							<label for="ftp_host"><?php echo __("Ftp Hostname",'xcloner-backup-and-restore')?></label>
36
+							<label for="ftp_host"><?php echo __("Ftp Hostname", 'xcloner-backup-and-restore')?></label>
37 37
 						</div>
38 38
 						<div class="col s12 m6">
39
-							<input placeholder="<?php echo __("Ftp Hostname",'xcloner-backup-and-restore')?>" id="ftp_host" type="text" name="xcloner_ftp_hostname" class="validate" value="<?php echo get_option("xcloner_ftp_hostname")?>">
39
+							<input placeholder="<?php echo __("Ftp Hostname", 'xcloner-backup-and-restore')?>" id="ftp_host" type="text" name="xcloner_ftp_hostname" class="validate" value="<?php echo get_option("xcloner_ftp_hostname")?>">
40 40
 				        </div>
41 41
 				        <div class=" col s12 m2">
42
-							<input placeholder="<?php echo __("Ftp Port",'xcloner-backup-and-restore')?>" id="ftp_port" type="text" name="xcloner_ftp_port" class="validate" value="<?php echo get_option("xcloner_ftp_port", 21)?>">
42
+							<input placeholder="<?php echo __("Ftp Port", 'xcloner-backup-and-restore')?>" id="ftp_port" type="text" name="xcloner_ftp_port" class="validate" value="<?php echo get_option("xcloner_ftp_port", 21)?>">
43 43
 				        </div>
44 44
 			        </div>
45 45
 			        
46 46
 			        <div class="row">
47 47
 						<div class="col s12 m3 label">
48
-							<label for="ftp_username"><?php echo __("Ftp Username",'xcloner-backup-and-restore')?></label>
48
+							<label for="ftp_username"><?php echo __("Ftp Username", 'xcloner-backup-and-restore')?></label>
49 49
 						</div>	
50 50
 						<div class=" col s12 m6">
51
-							<input placeholder="<?php echo __("Ftp Username",'xcloner-backup-and-restore')?>" id="ftp_username" type="text" name="xcloner_ftp_username" class="validate" value="<?php echo get_option("xcloner_ftp_username")?>" autocomplete="off" >
51
+							<input placeholder="<?php echo __("Ftp Username", 'xcloner-backup-and-restore')?>" id="ftp_username" type="text" name="xcloner_ftp_username" class="validate" value="<?php echo get_option("xcloner_ftp_username")?>" autocomplete="off" >
52 52
 				        </div>
53 53
 			        </div>
54 54
 			        
55 55
 			        
56 56
 			        <div class="row">
57 57
 						<div class="col s12 m3 label">
58
-							<label for="ftp_password"><?php echo __("Ftp Password",'xcloner-backup-and-restore')?></label>
58
+							<label for="ftp_password"><?php echo __("Ftp Password", 'xcloner-backup-and-restore')?></label>
59 59
 						</div>
60 60
 						<div class=" col s12 m6">
61
-							<input placeholder="<?php echo __("Ftp Password",'xcloner-backup-and-restore')?>" id="ftp_password" type="password" name="xcloner_ftp_password" class="validate" value="<?php echo get_option("xcloner_ftp_password")?>" autocomplete="off" >
61
+							<input placeholder="<?php echo __("Ftp Password", 'xcloner-backup-and-restore')?>" id="ftp_password" type="password" name="xcloner_ftp_password" class="validate" value="<?php echo get_option("xcloner_ftp_password")?>" autocomplete="off" >
62 62
 				        </div>
63 63
 			        </div>
64 64
 			        
65 65
 			        <div class="row">
66 66
 						<div class="col s12 m3 label">
67
-							<label for="ftp_root"><?php echo __("Ftp Storage Folder",'xcloner-backup-and-restore')?></label>
67
+							<label for="ftp_root"><?php echo __("Ftp Storage Folder", 'xcloner-backup-and-restore')?></label>
68 68
 						</div>
69 69
 						<div class=" col s12 m6">
70
-							<input placeholder="<?php echo __("Ftp Storage Folder",'xcloner-backup-and-restore')?>" id="ftp_root" type="text" name="xcloner_ftp_path" class="validate" value="<?php echo get_option("xcloner_ftp_path")?>">
70
+							<input placeholder="<?php echo __("Ftp Storage Folder", 'xcloner-backup-and-restore')?>" id="ftp_root" type="text" name="xcloner_ftp_path" class="validate" value="<?php echo get_option("xcloner_ftp_path")?>">
71 71
 						</div>	
72 72
 			        </div>
73 73
 			        
74 74
 			        <div class="row">
75 75
 						<div class="col s12 m3 label">
76
-							<label for="ftp_root"><?php echo __("Ftp Transfer Mode",'xcloner-backup-and-restore')?></label>
76
+							<label for="ftp_root"><?php echo __("Ftp Transfer Mode", 'xcloner-backup-and-restore')?></label>
77 77
 						</div>
78 78
 						<div class=" col s12 m6 input-field inline">
79
-							<input name="xcloner_ftp_transfer_mode" type="radio" id="passive" value="1" <?php if(get_option("xcloner_ftp_transfer_mode", 1)) echo "checked"?> />
80
-							<label for="passive"><?php echo __("Passive",'xcloner-backup-and-restore')?></label>
79
+							<input name="xcloner_ftp_transfer_mode" type="radio" id="passive" value="1" <?php if (get_option("xcloner_ftp_transfer_mode", 1)) echo "checked"?> />
80
+							<label for="passive"><?php echo __("Passive", 'xcloner-backup-and-restore')?></label>
81 81
 
82
-							<input name="xcloner_ftp_transfer_mode" type="radio" id="active" value="0" <?php if(!get_option("xcloner_ftp_transfer_mode", 1)) echo "checked"?> />
83
-							<label for="active"><?php echo __("Active",'xcloner-backup-and-restore')?></label>
82
+							<input name="xcloner_ftp_transfer_mode" type="radio" id="active" value="0" <?php if (!get_option("xcloner_ftp_transfer_mode", 1)) echo "checked"?> />
83
+							<label for="active"><?php echo __("Active", 'xcloner-backup-and-restore')?></label>
84 84
 						</div>	
85 85
 			        </div>
86 86
 			        
87 87
 			        <div class="row">
88 88
 						<div class="col s12 m3 label">
89
-							<label for="ftp_ssl_mode"><?php echo __("Ftp Secure Connection",'xcloner-backup-and-restore')?></label>
89
+							<label for="ftp_ssl_mode"><?php echo __("Ftp Secure Connection", 'xcloner-backup-and-restore')?></label>
90 90
 						</div>
91 91
 						<div class=" col s12 m6 input-field inline">
92
-							<input name="xcloner_ftp_ssl_mode" type="radio" id="ftp_ssl_mode_inactive" value="0" <?php if(!get_option("xcloner_ftp_ssl_mode")) echo "checked"?> />
93
-							<label for="ftp_ssl_mode_inactive"><?php echo __("Disable",'xcloner-backup-and-restore')?></label>
92
+							<input name="xcloner_ftp_ssl_mode" type="radio" id="ftp_ssl_mode_inactive" value="0" <?php if (!get_option("xcloner_ftp_ssl_mode")) echo "checked"?> />
93
+							<label for="ftp_ssl_mode_inactive"><?php echo __("Disable", 'xcloner-backup-and-restore')?></label>
94 94
 
95
-							<input name="xcloner_ftp_ssl_mode" type="radio" id="ftp_ssl_mode_active" value="1" <?php if(get_option("xcloner_ftp_ssl_mode")) echo "checked"?> />
96
-							<label for="ftp_ssl_mode_active"><?php echo __("Enable",'xcloner-backup-and-restore')?></label>
95
+							<input name="xcloner_ftp_ssl_mode" type="radio" id="ftp_ssl_mode_active" value="1" <?php if (get_option("xcloner_ftp_ssl_mode")) echo "checked"?> />
96
+							<label for="ftp_ssl_mode_active"><?php echo __("Enable", 'xcloner-backup-and-restore')?></label>
97 97
 						</div>	
98 98
 			        </div>
99 99
 			        
100 100
 			        <div class="row">
101 101
 						<div class="col s12 m3 label">
102
-							<label for="ftp_timeout"><?php echo __("Ftp Timeout",'xcloner-backup-and-restore')?></label>
102
+							<label for="ftp_timeout"><?php echo __("Ftp Timeout", 'xcloner-backup-and-restore')?></label>
103 103
 						</div>
104 104
 						<div class=" col s12 m2">
105
-							<input placeholder="<?php echo __("Ftp Timeout",'xcloner-backup-and-restore')?>" id="ftp_timeout" type="text" name="xcloner_ftp_timeout" class="validate" value="<?php echo get_option("xcloner_ftp_timeout", 30)?>">
105
+							<input placeholder="<?php echo __("Ftp Timeout", 'xcloner-backup-and-restore')?>" id="ftp_timeout" type="text" name="xcloner_ftp_timeout" class="validate" value="<?php echo get_option("xcloner_ftp_timeout", 30)?>">
106 106
 				        </div>
107 107
 			        </div>
108 108
 			        
109 109
 			        <div class="row">
110 110
 						<div class="col s12 m3 label">
111
-							<label for="ftp_cleanup_days"><?php echo __("Ftp Cleanup (days)",'xcloner-backup-and-restore')?></label>
111
+							<label for="ftp_cleanup_days"><?php echo __("Ftp Cleanup (days)", 'xcloner-backup-and-restore')?></label>
112 112
 						</div>
113 113
 						<div class=" col s12 m6">
114
-							<input placeholder="<?php echo __("how many days to keep the backups for",'xcloner-backup-and-restore')?>" id="ftp_cleanup_days" type="text" name="xcloner_ftp_cleanup_days" class="validate" value="<?php echo get_option("xcloner_ftp_cleanup_days")?>">
114
+							<input placeholder="<?php echo __("how many days to keep the backups for", 'xcloner-backup-and-restore')?>" id="ftp_cleanup_days" type="text" name="xcloner_ftp_cleanup_days" class="validate" value="<?php echo get_option("xcloner_ftp_cleanup_days")?>">
115 115
 				        </div>
116 116
 			        </div>
117 117
 			        
118 118
 			        <div class="row">
119 119
 						<div class="col s6 m4">
120
-							<button class="btn waves-effect waves-light" type="submit" name="action" id="action"  value="ftp"><?php echo __("Save Settings",'xcloner-backup-and-restore')?>
120
+							<button class="btn waves-effect waves-light" type="submit" name="action" id="action"  value="ftp"><?php echo __("Save Settings", 'xcloner-backup-and-restore')?>
121 121
 								<i class="material-icons right">save</i>
122 122
 							</button>
123 123
 						</div>	
124 124
 						<div class="col s6 m4">
125
-							<button class="btn waves-effect waves-light orange" type="submit" name="action" id="action"  value="ftp" onclick="jQuery('#connection_check').val('1')"><?php echo __("Verify",'xcloner-backup-and-restore')?>
125
+							<button class="btn waves-effect waves-light orange" type="submit" name="action" id="action"  value="ftp" onclick="jQuery('#connection_check').val('1')"><?php echo __("Verify", 'xcloner-backup-and-restore')?>
126 126
 								<i class="material-icons right">import_export</i>
127 127
 							</button>
128 128
 						</div>
@@ -133,11 +133,11 @@  discard block
 block discarded – undo
133 133
 			<!-- SFTP STORAGE-->
134 134
 			<li id="sftp">
135 135
 				<div class="collapsible-header">
136
-					<i class="material-icons">computer</i><?php echo __("SFTP Storage",'xcloner-backup-and-restore')?>
136
+					<i class="material-icons">computer</i><?php echo __("SFTP Storage", 'xcloner-backup-and-restore')?>
137 137
 					<div class="switch right">
138 138
 						<label>
139 139
 						Off
140
-						<input type="checkbox" name="xcloner_sftp_enable" class="status" value="1" <?php if(get_option("xcloner_sftp_enable")) echo "checked"?> \>
140
+						<input type="checkbox" name="xcloner_sftp_enable" class="status" value="1" <?php if (get_option("xcloner_sftp_enable")) echo "checked"?> \>
141 141
 						<span class="lever"></span>
142 142
 						On
143 143
 						</label>
@@ -146,79 +146,79 @@  discard block
 block discarded – undo
146 146
 				<div class="collapsible-body">
147 147
 					<div class="row">
148 148
 						<div class="col s12 m3 label">
149
-							<label for="sftp_host"><?php echo __("SFTP Hostname",'xcloner-backup-and-restore')?></label>
149
+							<label for="sftp_host"><?php echo __("SFTP Hostname", 'xcloner-backup-and-restore')?></label>
150 150
 						</div>
151 151
 						<div class="col s12 m6">
152
-							<input placeholder="<?php echo __("SFTP Hostname",'xcloner-backup-and-restore')?>" id="sftp_host" type="text" name="xcloner_sftp_hostname" class="validate" value="<?php echo get_option("xcloner_sftp_hostname")?>">
152
+							<input placeholder="<?php echo __("SFTP Hostname", 'xcloner-backup-and-restore')?>" id="sftp_host" type="text" name="xcloner_sftp_hostname" class="validate" value="<?php echo get_option("xcloner_sftp_hostname")?>">
153 153
 				        </div>
154 154
 				        <div class=" col s12 m2">
155
-							<input placeholder="<?php echo __("SFTP Port",'xcloner-backup-and-restore')?>" id="sftp_port" type="text" name="xcloner_sftp_port" class="validate" value="<?php echo get_option("xcloner_sftp_port", 22)?>">
155
+							<input placeholder="<?php echo __("SFTP Port", 'xcloner-backup-and-restore')?>" id="sftp_port" type="text" name="xcloner_sftp_port" class="validate" value="<?php echo get_option("xcloner_sftp_port", 22)?>">
156 156
 				        </div>
157 157
 			        </div>
158 158
 			        
159 159
 			        <div class="row">
160 160
 						<div class="col s12 m3 label">
161
-							<label for="sftp_username"><?php echo __("SFTP Username",'xcloner-backup-and-restore')?></label>
161
+							<label for="sftp_username"><?php echo __("SFTP Username", 'xcloner-backup-and-restore')?></label>
162 162
 						</div>	
163 163
 						<div class=" col s12 m6">
164
-							<input placeholder="<?php echo __("SFTP Username",'xcloner-backup-and-restore')?>" id="sftp_username" type="text" name="xcloner_sftp_username" class="validate" value="<?php echo get_option("xcloner_sftp_username")?>" autocomplete="off" >
164
+							<input placeholder="<?php echo __("SFTP Username", 'xcloner-backup-and-restore')?>" id="sftp_username" type="text" name="xcloner_sftp_username" class="validate" value="<?php echo get_option("xcloner_sftp_username")?>" autocomplete="off" >
165 165
 				        </div>
166 166
 			        </div>
167 167
 			        
168 168
 			        
169 169
 			        <div class="row">
170 170
 						<div class="col s12 m3 label">
171
-							<label for="sftp_password"><?php echo __("SFTP or Private Key Password",'xcloner-backup-and-restore')?></label>
171
+							<label for="sftp_password"><?php echo __("SFTP or Private Key Password", 'xcloner-backup-and-restore')?></label>
172 172
 						</div>
173 173
 						<div class=" col s12 m6">
174
-							<input placeholder="<?php echo __("SFTP or Private Key Password",'xcloner-backup-and-restore')?>" id="ftp_spassword" type="password" name="xcloner_sftp_password" class="validate" value="<?php echo get_option("xcloner_sftp_password")?>" autocomplete="off" >
174
+							<input placeholder="<?php echo __("SFTP or Private Key Password", 'xcloner-backup-and-restore')?>" id="ftp_spassword" type="password" name="xcloner_sftp_password" class="validate" value="<?php echo get_option("xcloner_sftp_password")?>" autocomplete="off" >
175 175
 				        </div>
176 176
 			        </div>
177 177
 			        
178 178
 			        <div class="row">
179 179
 						<div class="col s12 m3 label">
180
-							<label for="sftp_private_key"><?php echo __("SFTP Private Key(RSA)",'xcloner-backup-and-restore')?></label>
180
+							<label for="sftp_private_key"><?php echo __("SFTP Private Key(RSA)", 'xcloner-backup-and-restore')?></label>
181 181
 						</div>
182 182
 						<div class=" col s12 m6">
183
-							<textarea rows="5" placeholder="<?php echo __("Local Server Path or Contents of the SFTP Private Key RSA File",'xcloner-backup-and-restore')?>" id="sftp_private_key" type="text" name="xcloner_sftp_private_key" class="validate" value=""><?php echo get_option("xcloner_sftp_private_key")?></textarea>
183
+							<textarea rows="5" placeholder="<?php echo __("Local Server Path or Contents of the SFTP Private Key RSA File", 'xcloner-backup-and-restore')?>" id="sftp_private_key" type="text" name="xcloner_sftp_private_key" class="validate" value=""><?php echo get_option("xcloner_sftp_private_key")?></textarea>
184 184
 						</div>
185 185
 			        </div>
186 186
 			        
187 187
 			        <div class="row">
188 188
 						<div class="col s12 m3 label">
189
-							<label for="sftp_root"><?php echo __("SFTP Storage Folder",'xcloner-backup-and-restore')?></label>
189
+							<label for="sftp_root"><?php echo __("SFTP Storage Folder", 'xcloner-backup-and-restore')?></label>
190 190
 						</div>
191 191
 						<div class=" col s12 m6">
192
-							<input placeholder="<?php echo __("SFTP Storage Folder",'xcloner-backup-and-restore')?>" id="sftp_root" type="text" name="xcloner_sftp_path" class="validate" value="<?php echo get_option("xcloner_sftp_path")?>">
192
+							<input placeholder="<?php echo __("SFTP Storage Folder", 'xcloner-backup-and-restore')?>" id="sftp_root" type="text" name="xcloner_sftp_path" class="validate" value="<?php echo get_option("xcloner_sftp_path")?>">
193 193
 						</div>	
194 194
 			        </div>
195 195
 			        
196 196
 			        <div class="row">
197 197
 						<div class="col s12 m3 label">
198
-							<label for="sftp_timeout"><?php echo __("SFTP Timeout",'xcloner-backup-and-restore')?></label>
198
+							<label for="sftp_timeout"><?php echo __("SFTP Timeout", 'xcloner-backup-and-restore')?></label>
199 199
 						</div>
200 200
 						<div class=" col s12 m2">
201
-							<input placeholder="<?php echo __("SFTP Timeout",'xcloner-backup-and-restore')?>" id="sftp_timeout" type="text" name="xcloner_sftp_timeout" class="validate" value="<?php echo get_option("xcloner_sftp_timeout", 30)?>">
201
+							<input placeholder="<?php echo __("SFTP Timeout", 'xcloner-backup-and-restore')?>" id="sftp_timeout" type="text" name="xcloner_sftp_timeout" class="validate" value="<?php echo get_option("xcloner_sftp_timeout", 30)?>">
202 202
 				        </div>
203 203
 			        </div>
204 204
 			        
205 205
 			        <div class="row">
206 206
 						<div class="col s12 m3 label">
207
-							<label for="sftp_cleanup_days"><?php echo __("SFTP Cleanup (days)",'xcloner-backup-and-restore')?></label>
207
+							<label for="sftp_cleanup_days"><?php echo __("SFTP Cleanup (days)", 'xcloner-backup-and-restore')?></label>
208 208
 						</div>
209 209
 						<div class=" col s12 m6">
210
-							<input placeholder="<?php echo __("how many days to keep the backups for",'xcloner-backup-and-restore')?>" id="sftp_cleanup_days" type="text" name="xcloner_sftp_cleanup_days" class="validate" value="<?php echo get_option("xcloner_sftp_cleanup_days")?>">
210
+							<input placeholder="<?php echo __("how many days to keep the backups for", 'xcloner-backup-and-restore')?>" id="sftp_cleanup_days" type="text" name="xcloner_sftp_cleanup_days" class="validate" value="<?php echo get_option("xcloner_sftp_cleanup_days")?>">
211 211
 				        </div>
212 212
 			        </div>
213 213
 			        
214 214
 			        <div class="row">
215 215
 						<div class="col s6 m4">
216
-							<button class="btn waves-effect waves-light" type="submit" name="action" id="action"  value="sftp"><?php echo __("Save Settings",'xcloner-backup-and-restore')?>
216
+							<button class="btn waves-effect waves-light" type="submit" name="action" id="action"  value="sftp"><?php echo __("Save Settings", 'xcloner-backup-and-restore')?>
217 217
 								<i class="material-icons right">save</i>
218 218
 							</button>
219 219
 						</div>	
220 220
 						<div class="col s6 m4">
221
-							<button class="btn waves-effect waves-light orange" type="submit" name="action" id="action"  value="sftp" onclick="jQuery('#connection_check').val('1')"><?php echo __("Verify",'xcloner-backup-and-restore')?>
221
+							<button class="btn waves-effect waves-light orange" type="submit" name="action" id="action"  value="sftp" onclick="jQuery('#connection_check').val('1')"><?php echo __("Verify", 'xcloner-backup-and-restore')?>
222 222
 								<i class="material-icons right">import_export</i>
223 223
 							</button>
224 224
 						</div>
@@ -230,11 +230,11 @@  discard block
 block discarded – undo
230 230
 			<!-- AWS STORAGE-->
231 231
 			<li id="aws">
232 232
 				<div class="collapsible-header">
233
-					<i class="material-icons">computer</i><?php echo __("AWS Storage",'xcloner-backup-and-restore')?>
233
+					<i class="material-icons">computer</i><?php echo __("AWS Storage", 'xcloner-backup-and-restore')?>
234 234
 					<div class="switch right">
235 235
 						<label>
236 236
 						Off
237
-						<input type="checkbox" name="xcloner_aws_enable" class="status" value="1" <?php if(get_option("xcloner_aws_enable")) echo "checked"?> \>
237
+						<input type="checkbox" name="xcloner_aws_enable" class="status" value="1" <?php if (get_option("xcloner_aws_enable")) echo "checked"?> \>
238 238
 						<span class="lever"></span>
239 239
 						On
240 240
 						</label>
@@ -255,35 +255,35 @@  discard block
 block discarded – undo
255 255
 			        
256 256
 			        <div class="row">
257 257
 						<div class="col s12 m3 label">
258
-							<label for="aws_key"><?php echo __("AWS Key",'xcloner-backup-and-restore')?></label>
258
+							<label for="aws_key"><?php echo __("AWS Key", 'xcloner-backup-and-restore')?></label>
259 259
 						</div>	
260 260
 						<div class=" col s12 m6">
261
-							<input placeholder="<?php echo __("AWS Key",'xcloner-backup-and-restore')?>" id="aws_key" type="text" name="xcloner_aws_key" class="validate" value="<?php echo get_option("xcloner_aws_key")?>" autocomplete="off" >
261
+							<input placeholder="<?php echo __("AWS Key", 'xcloner-backup-and-restore')?>" id="aws_key" type="text" name="xcloner_aws_key" class="validate" value="<?php echo get_option("xcloner_aws_key")?>" autocomplete="off" >
262 262
 				        </div>
263 263
 			        </div>
264 264
 			        
265 265
 			        <div class="row">
266 266
 						<div class="col s12 m3 label">
267
-							<label for="aws_secret"><?php echo __("AWS Secret",'xcloner-backup-and-restore')?></label>
267
+							<label for="aws_secret"><?php echo __("AWS Secret", 'xcloner-backup-and-restore')?></label>
268 268
 						</div>	
269 269
 						<div class=" col s12 m6">
270
-							<input placeholder="<?php echo __("AWS Secret",'xcloner-backup-and-restore')?>" id="aws_secret" type="text" name="xcloner_aws_secret" class="validate" value="<?php echo get_option("xcloner_aws_secret")?>" autocomplete="off" >
270
+							<input placeholder="<?php echo __("AWS Secret", 'xcloner-backup-and-restore')?>" id="aws_secret" type="text" name="xcloner_aws_secret" class="validate" value="<?php echo get_option("xcloner_aws_secret")?>" autocomplete="off" >
271 271
 				        </div>
272 272
 			        </div>
273 273
 			        
274 274
 			        <div class="row">
275 275
 						<div class="col s12 m3 label">
276
-							<label for="aws_region"><?php echo __("AWS Region",'xcloner-backup-and-restore')?></label>
276
+							<label for="aws_region"><?php echo __("AWS Region", 'xcloner-backup-and-restore')?></label>
277 277
 						</div>	
278 278
 						<div class=" col s12 m6">
279
-							<select placeholder="<?php echo __("example: us-east-1",'xcloner-backup-and-restore')?>" id="aws_region" type="text" name="xcloner_aws_region" class="validate" value="<?php echo get_option("xcloner_aws_region")?>" autocomplete="off" >
279
+							<select placeholder="<?php echo __("example: us-east-1", 'xcloner-backup-and-restore')?>" id="aws_region" type="text" name="xcloner_aws_region" class="validate" value="<?php echo get_option("xcloner_aws_region")?>" autocomplete="off" >
280 280
 							<option readonly value=""><?php echo __("Please Select AWS Region")?></option>
281 281
 							<?php 							
282 282
 							$aws_regions = $remote_storage->get_aws_regions();
283 283
 							
284
-							foreach($aws_regions as $key=>$region){
284
+							foreach ($aws_regions as $key=>$region) {
285 285
 								?>
286
-								<option value="<?php echo $key?>" <?php echo ($key == get_option('xcloner_aws_region')?"selected":"")?>><?php echo $region?> = <?php echo $key?></option>
286
+								<option value="<?php echo $key?>" <?php echo ($key == get_option('xcloner_aws_region') ? "selected" : "")?>><?php echo $region?> = <?php echo $key?></option>
287 287
 								<?php
288 288
 								}
289 289
 							?>
@@ -293,30 +293,30 @@  discard block
 block discarded – undo
293 293
 			        
294 294
 			        <div class="row">
295 295
 						<div class="col s12 m3 label">
296
-							<label for="aws_bucket_name"><?php echo __("AWS Bucket Name",'xcloner-backup-and-restore')?></label>
296
+							<label for="aws_bucket_name"><?php echo __("AWS Bucket Name", 'xcloner-backup-and-restore')?></label>
297 297
 						</div>	
298 298
 						<div class=" col s12 m6">
299
-							<input placeholder="<?php echo __("AWS Bucket Name",'xcloner-backup-and-restore')?>" id="aws_bucket_name" type="text" name="xcloner_aws_bucket_name" class="validate" value="<?php echo get_option("xcloner_aws_bucket_name")?>" autocomplete="off" >
299
+							<input placeholder="<?php echo __("AWS Bucket Name", 'xcloner-backup-and-restore')?>" id="aws_bucket_name" type="text" name="xcloner_aws_bucket_name" class="validate" value="<?php echo get_option("xcloner_aws_bucket_name")?>" autocomplete="off" >
300 300
 				        </div>
301 301
 			        </div>
302 302
 			        
303 303
 			        <div class="row">
304 304
 						<div class="col s12 m3 label">
305
-							<label for="aws_cleanup_days"><?php echo __("AWS Cleanup (days)",'xcloner-backup-and-restore')?></label>
305
+							<label for="aws_cleanup_days"><?php echo __("AWS Cleanup (days)", 'xcloner-backup-and-restore')?></label>
306 306
 						</div>
307 307
 						<div class=" col s12 m6">
308
-							<input placeholder="<?php echo __("how many days to keep the backups for",'xcloner-backup-and-restore')?>" id="aws_cleanup_days" type="text" name="xcloner_aws_cleanup_days" class="validate" value="<?php echo get_option("xcloner_aws_cleanup_days")?>">
308
+							<input placeholder="<?php echo __("how many days to keep the backups for", 'xcloner-backup-and-restore')?>" id="aws_cleanup_days" type="text" name="xcloner_aws_cleanup_days" class="validate" value="<?php echo get_option("xcloner_aws_cleanup_days")?>">
309 309
 				        </div>
310 310
 			        </div>
311 311
 			        
312 312
 			        <div class="row">
313 313
 						<div class="col s6 m4">
314
-							<button class="btn waves-effect waves-light" type="submit" name="action" id="action"  value="aws"><?php echo __("Save Settings",'xcloner-backup-and-restore')?>
314
+							<button class="btn waves-effect waves-light" type="submit" name="action" id="action"  value="aws"><?php echo __("Save Settings", 'xcloner-backup-and-restore')?>
315 315
 								<i class="material-icons right">save</i>
316 316
 							</button>
317 317
 						</div>	
318 318
 						<div class="col s6 m4">
319
-							<button class="btn waves-effect waves-light orange" type="submit" name="action" id="action"  value="aws" onclick="jQuery('#connection_check').val('1')"><?php echo __("Verify",'xcloner-backup-and-restore')?>
319
+							<button class="btn waves-effect waves-light orange" type="submit" name="action" id="action"  value="aws" onclick="jQuery('#connection_check').val('1')"><?php echo __("Verify", 'xcloner-backup-and-restore')?>
320 320
 								<i class="material-icons right">import_export</i>
321 321
 							</button>
322 322
 						</div>
@@ -328,11 +328,11 @@  discard block
 block discarded – undo
328 328
 			<!-- DROPBOX STORAGE-->
329 329
 			<li id="dropbox">
330 330
 				<div class="collapsible-header">
331
-					<i class="material-icons">computer</i><?php echo __("Dropbox Storage",'xcloner-backup-and-restore')?>
331
+					<i class="material-icons">computer</i><?php echo __("Dropbox Storage", 'xcloner-backup-and-restore')?>
332 332
 					<div class="switch right">
333 333
 						<label>
334 334
 						Off
335
-						<input type="checkbox" name="xcloner_dropbox_enable" class="status" value="1" <?php if(get_option("xcloner_dropbox_enable")) echo "checked"?> \>
335
+						<input type="checkbox" name="xcloner_dropbox_enable" class="status" value="1" <?php if (get_option("xcloner_dropbox_enable")) echo "checked"?> \>
336 336
 						<span class="lever"></span>
337 337
 						On
338 338
 						</label>
@@ -353,49 +353,49 @@  discard block
 block discarded – undo
353 353
 			        
354 354
 			        <div class="row">
355 355
 						<div class="col s12 m3 label">
356
-							<label for="dropbox_access_token"><?php echo __("Dropbox Access Token",'xcloner-backup-and-restore')?></label>
356
+							<label for="dropbox_access_token"><?php echo __("Dropbox Access Token", 'xcloner-backup-and-restore')?></label>
357 357
 						</div>	
358 358
 						<div class=" col s12 m6">
359
-							<input placeholder="<?php echo __("Dropbox Access Token",'xcloner-backup-and-restore')?>" id="dropbox_access_token" type="text" name="xcloner_dropbox_access_token" class="validate" value="<?php echo get_option("xcloner_dropbox_access_token")?>" autocomplete="off" >
359
+							<input placeholder="<?php echo __("Dropbox Access Token", 'xcloner-backup-and-restore')?>" id="dropbox_access_token" type="text" name="xcloner_dropbox_access_token" class="validate" value="<?php echo get_option("xcloner_dropbox_access_token")?>" autocomplete="off" >
360 360
 				        </div>
361 361
 			        </div>
362 362
 			        
363 363
 			        
364 364
 			        <div class="row">
365 365
 						<div class="col s12 m3 label">
366
-							<label for="dropbox_app_secret"><?php echo __("Dropbox App Secret",'xcloner-backup-and-restore')?></label>
366
+							<label for="dropbox_app_secret"><?php echo __("Dropbox App Secret", 'xcloner-backup-and-restore')?></label>
367 367
 						</div>
368 368
 						<div class=" col s12 m6">
369
-							<input placeholder="<?php echo __("Dropbox App Secret",'xcloner-backup-and-restore')?>" id="dropbox_app_secret" type="text" name="xcloner_dropbox_app_secret" class="validate" value="<?php echo get_option("xcloner_dropbox_app_secret")?>" autocomplete="off" >
369
+							<input placeholder="<?php echo __("Dropbox App Secret", 'xcloner-backup-and-restore')?>" id="dropbox_app_secret" type="text" name="xcloner_dropbox_app_secret" class="validate" value="<?php echo get_option("xcloner_dropbox_app_secret")?>" autocomplete="off" >
370 370
 				        </div>
371 371
 			        </div>
372 372
 			        
373 373
 			        <div class="row">
374 374
 						<div class="col s12 m3 label">
375
-							<label for="dropbox_prefix"><?php echo __("Dropbox Prefix",'xcloner-backup-and-restore')?></label>
375
+							<label for="dropbox_prefix"><?php echo __("Dropbox Prefix", 'xcloner-backup-and-restore')?></label>
376 376
 						</div>
377 377
 						<div class=" col s12 m6">
378
-							<input placeholder="<?php echo __("Dropbox Prefix",'xcloner-backup-and-restore')?>" id="dropbox_prefix" type="text" name="xcloner_dropbox_prefix" class="validate" value="<?php echo get_option("xcloner_dropbox_prefix")?>">
378
+							<input placeholder="<?php echo __("Dropbox Prefix", 'xcloner-backup-and-restore')?>" id="dropbox_prefix" type="text" name="xcloner_dropbox_prefix" class="validate" value="<?php echo get_option("xcloner_dropbox_prefix")?>">
379 379
 						</div>	
380 380
 			        </div>
381 381
 			        
382 382
 			        <div class="row">
383 383
 						<div class="col s12 m3 label">
384
-							<label for="dropbox_cleanup_days"><?php echo __("Dropbox Cleanup (days)",'xcloner-backup-and-restore')?></label>
384
+							<label for="dropbox_cleanup_days"><?php echo __("Dropbox Cleanup (days)", 'xcloner-backup-and-restore')?></label>
385 385
 						</div>
386 386
 						<div class=" col s12 m6">
387
-							<input placeholder="<?php echo __("how many days to keep the backups for",'xcloner-backup-and-restore')?>" id="dropbox_cleanup_days" type="text" name="xcloner_dropbox_cleanup_days" class="validate" value="<?php echo get_option("xcloner_dropbox_cleanup_days")?>">
387
+							<input placeholder="<?php echo __("how many days to keep the backups for", 'xcloner-backup-and-restore')?>" id="dropbox_cleanup_days" type="text" name="xcloner_dropbox_cleanup_days" class="validate" value="<?php echo get_option("xcloner_dropbox_cleanup_days")?>">
388 388
 				        </div>
389 389
 			        </div>
390 390
 			        
391 391
 			        <div class="row">
392 392
 						<div class="col s6 m4">
393
-							<button class="btn waves-effect waves-light" type="submit" name="action" id="action"  value="dropbox"><?php echo __("Save Settings",'xcloner-backup-and-restore')?>
393
+							<button class="btn waves-effect waves-light" type="submit" name="action" id="action"  value="dropbox"><?php echo __("Save Settings", 'xcloner-backup-and-restore')?>
394 394
 								<i class="material-icons right">save</i>
395 395
 							</button>
396 396
 						</div>	
397 397
 						<div class="col s6 m4">
398
-							<button class="btn waves-effect waves-light orange" type="submit" name="action" id="action"  value="dropbox" onclick="jQuery('#connection_check').val('1')"><?php echo __("Verify",'xcloner-backup-and-restore')?>
398
+							<button class="btn waves-effect waves-light orange" type="submit" name="action" id="action"  value="dropbox" onclick="jQuery('#connection_check').val('1')"><?php echo __("Verify", 'xcloner-backup-and-restore')?>
399 399
 								<i class="material-icons right">import_export</i>
400 400
 							</button>
401 401
 						</div>
@@ -407,11 +407,11 @@  discard block
 block discarded – undo
407 407
 			<!-- AZURE STORAGE-->
408 408
 			<li id="azure">
409 409
 				<div class="collapsible-header">
410
-					<i class="material-icons">computer</i><?php echo __("Azure Blob Storage",'xcloner-backup-and-restore')?>
410
+					<i class="material-icons">computer</i><?php echo __("Azure Blob Storage", 'xcloner-backup-and-restore')?>
411 411
 					<div class="switch right">
412 412
 						<label>
413 413
 						Off
414
-						<input type="checkbox" name="xcloner_azure_enable" class="status" value="1" <?php if(get_option("xcloner_azure_enable")) echo "checked"?> \>
414
+						<input type="checkbox" name="xcloner_azure_enable" class="status" value="1" <?php if (get_option("xcloner_azure_enable")) echo "checked"?> \>
415 415
 						<span class="lever"></span>
416 416
 						On
417 417
 						</label>
@@ -425,56 +425,56 @@  discard block
 block discarded – undo
425 425
 						</div>	
426 426
 						<div class=" col s12 m6">
427 427
 							<p>
428
-								<?php echo sprintf(__('Visit %s and get your "Api Key".','xcloner-backup-and-restore'), '<a href="https://azure.microsoft.com/en-us/services/storage/blobs/" target="_blank">https://azure.microsoft.com/en-us/services/storage/blobs/</a>')?>
428
+								<?php echo sprintf(__('Visit %s and get your "Api Key".', 'xcloner-backup-and-restore'), '<a href="https://azure.microsoft.com/en-us/services/storage/blobs/" target="_blank">https://azure.microsoft.com/en-us/services/storage/blobs/</a>')?>
429 429
 							</p>
430 430
 				        </div>
431 431
 			        </div>
432 432
 			        
433 433
 			        <div class="row">
434 434
 						<div class="col s12 m3 label">
435
-							<label for="azure_account_name"><?php echo __("Azure Account Name",'xcloner-backup-and-restore')?></label>
435
+							<label for="azure_account_name"><?php echo __("Azure Account Name", 'xcloner-backup-and-restore')?></label>
436 436
 						</div>	
437 437
 						<div class=" col s12 m6">
438
-							<input placeholder="<?php echo __("Azure Account Name",'xcloner-backup-and-restore')?>" id="azure_account_name" type="text" name="xcloner_azure_account_name" class="validate" value="<?php echo get_option("xcloner_azure_account_name")?>" autocomplete="off" >
438
+							<input placeholder="<?php echo __("Azure Account Name", 'xcloner-backup-and-restore')?>" id="azure_account_name" type="text" name="xcloner_azure_account_name" class="validate" value="<?php echo get_option("xcloner_azure_account_name")?>" autocomplete="off" >
439 439
 				        </div>
440 440
 			        </div>
441 441
 			        
442 442
 			        
443 443
 			        <div class="row">
444 444
 						<div class="col s12 m3 label">
445
-							<label for="azure_api_key"><?php echo __("Azure Api Key",'xcloner-backup-and-restore')?></label>
445
+							<label for="azure_api_key"><?php echo __("Azure Api Key", 'xcloner-backup-and-restore')?></label>
446 446
 						</div>
447 447
 						<div class=" col s12 m6">
448
-							<input placeholder="<?php echo __("Azure Api Key",'xcloner-backup-and-restore')?>" id="azure_api_key" type="text" name="xcloner_azure_api_key" class="validate" value="<?php echo get_option("xcloner_azure_api_key")?>" autocomplete="off" >
448
+							<input placeholder="<?php echo __("Azure Api Key", 'xcloner-backup-and-restore')?>" id="azure_api_key" type="text" name="xcloner_azure_api_key" class="validate" value="<?php echo get_option("xcloner_azure_api_key")?>" autocomplete="off" >
449 449
 				        </div>
450 450
 			        </div>
451 451
 			        
452 452
 			        <div class="row">
453 453
 						<div class="col s12 m3 label">
454
-							<label for="azure_container"><?php echo __("Azure Container",'xcloner-backup-and-restore')?></label>
454
+							<label for="azure_container"><?php echo __("Azure Container", 'xcloner-backup-and-restore')?></label>
455 455
 						</div>
456 456
 						<div class=" col s12 m6">
457
-							<input placeholder="<?php echo __("Azure Container",'xcloner-backup-and-restore')?>" id="azure_container" type="text" name="xcloner_azure_container" class="validate" value="<?php echo get_option("xcloner_azure_container")?>">
457
+							<input placeholder="<?php echo __("Azure Container", 'xcloner-backup-and-restore')?>" id="azure_container" type="text" name="xcloner_azure_container" class="validate" value="<?php echo get_option("xcloner_azure_container")?>">
458 458
 						</div>	
459 459
 			        </div>
460 460
 			        
461 461
 			        <div class="row">
462 462
 						<div class="col s12 m3 label">
463
-							<label for="azure_cleanup_days"><?php echo __("Azure Cleanup (days)",'xcloner-backup-and-restore')?></label>
463
+							<label for="azure_cleanup_days"><?php echo __("Azure Cleanup (days)", 'xcloner-backup-and-restore')?></label>
464 464
 						</div>
465 465
 						<div class=" col s12 m6">
466
-							<input placeholder="<?php echo __("how many days to keep the backups for",'xcloner-backup-and-restore')?>" id="azure_cleanup_days" type="text" name="xcloner_azure_cleanup_days" class="validate" value="<?php echo get_option("xcloner_azure_cleanup_days")?>">
466
+							<input placeholder="<?php echo __("how many days to keep the backups for", 'xcloner-backup-and-restore')?>" id="azure_cleanup_days" type="text" name="xcloner_azure_cleanup_days" class="validate" value="<?php echo get_option("xcloner_azure_cleanup_days")?>">
467 467
 				        </div>
468 468
 			        </div>
469 469
 			        
470 470
 			        <div class="row">
471 471
 						<div class="col s6 m4">
472
-							<button class="btn waves-effect waves-light" type="submit" name="action" id="action"  value="azure"><?php echo __("Save Settings",'xcloner-backup-and-restore')?>
472
+							<button class="btn waves-effect waves-light" type="submit" name="action" id="action"  value="azure"><?php echo __("Save Settings", 'xcloner-backup-and-restore')?>
473 473
 								<i class="material-icons right">save</i>
474 474
 							</button>
475 475
 						</div>	
476 476
 						<div class="col s6 m4">
477
-							<button class="btn waves-effect waves-light orange" type="submit" name="action" id="action"  value="azure" onclick="jQuery('#connection_check').val('1')"><?php echo __("Verify",'xcloner-backup-and-restore')?>
477
+							<button class="btn waves-effect waves-light orange" type="submit" name="action" id="action"  value="azure" onclick="jQuery('#connection_check').val('1')"><?php echo __("Verify", 'xcloner-backup-and-restore')?>
478 478
 								<i class="material-icons right">import_export</i>
479 479
 							</button>
480 480
 						</div>
@@ -486,11 +486,11 @@  discard block
 block discarded – undo
486 486
 			<!-- BACKBLAZE STORAGE-->
487 487
 			<li id="backblaze">
488 488
 				<div class="collapsible-header">
489
-					<i class="material-icons">computer</i><?php echo __("Backblaze Storage",'xcloner-backup-and-restore')?>
489
+					<i class="material-icons">computer</i><?php echo __("Backblaze Storage", 'xcloner-backup-and-restore')?>
490 490
 					<div class="switch right">
491 491
 						<label>
492 492
 						Off
493
-						<input type="checkbox" name="xcloner_backblaze_enable" class="status" value="1" <?php if(get_option("xcloner_backblaze_enable")) echo "checked"?> \>
493
+						<input type="checkbox" name="xcloner_backblaze_enable" class="status" value="1" <?php if (get_option("xcloner_backblaze_enable")) echo "checked"?> \>
494 494
 						<span class="lever"></span>
495 495
 						On
496 496
 						</label>
@@ -504,56 +504,56 @@  discard block
 block discarded – undo
504 504
 						</div>	
505 505
 						<div class=" col s12 m6">
506 506
 							<p>
507
-								<?php echo sprintf(__('Visit %s and get your Account Id and  Application Key.','xcloner-backup-and-restore'), '<a href="https://secure.backblaze.com/b2_buckets.htm" target="_blank">https://secure.backblaze.com/b2_buckets.htm</a>')?>
507
+								<?php echo sprintf(__('Visit %s and get your Account Id and  Application Key.', 'xcloner-backup-and-restore'), '<a href="https://secure.backblaze.com/b2_buckets.htm" target="_blank">https://secure.backblaze.com/b2_buckets.htm</a>')?>
508 508
 							</p>
509 509
 				        </div>
510 510
 			        </div>
511 511
 			        
512 512
 			        <div class="row">
513 513
 						<div class="col s12 m3 label">
514
-							<label for="backblaze_account_id"><?php echo __("Backblaze Account Id",'xcloner-backup-and-restore')?></label>
514
+							<label for="backblaze_account_id"><?php echo __("Backblaze Account Id", 'xcloner-backup-and-restore')?></label>
515 515
 						</div>	
516 516
 						<div class=" col s12 m6">
517
-							<input placeholder="<?php echo __("Backblaze Account Id",'xcloner-backup-and-restore')?>" id="backblaze_account_id" type="text" name="xcloner_backblaze_account_id" class="validate" value="<?php echo get_option("xcloner_backblaze_account_id")?>" autocomplete="off" >
517
+							<input placeholder="<?php echo __("Backblaze Account Id", 'xcloner-backup-and-restore')?>" id="backblaze_account_id" type="text" name="xcloner_backblaze_account_id" class="validate" value="<?php echo get_option("xcloner_backblaze_account_id")?>" autocomplete="off" >
518 518
 				        </div>
519 519
 			        </div>
520 520
 			        
521 521
 			        
522 522
 			        <div class="row">
523 523
 						<div class="col s12 m3 label">
524
-							<label for="backblaze_application_key"><?php echo __("Backblaze Application Key",'xcloner-backup-and-restore')?></label>
524
+							<label for="backblaze_application_key"><?php echo __("Backblaze Application Key", 'xcloner-backup-and-restore')?></label>
525 525
 						</div>
526 526
 						<div class=" col s12 m6">
527
-							<input placeholder="<?php echo __("Backblaze Application Key",'xcloner-backup-and-restore')?>" id="backblaze_application_key" type="text" name="xcloner_backblaze_application_key" class="validate" value="<?php echo get_option("xcloner_backblaze_application_key")?>" autocomplete="off" >
527
+							<input placeholder="<?php echo __("Backblaze Application Key", 'xcloner-backup-and-restore')?>" id="backblaze_application_key" type="text" name="xcloner_backblaze_application_key" class="validate" value="<?php echo get_option("xcloner_backblaze_application_key")?>" autocomplete="off" >
528 528
 				        </div>
529 529
 			        </div>
530 530
 			        
531 531
 			        <div class="row">
532 532
 						<div class="col s12 m3 label">
533
-							<label for="backblaze_bucket_name"><?php echo __("Backblaze Bucket Name",'xcloner-backup-and-restore')?></label>
533
+							<label for="backblaze_bucket_name"><?php echo __("Backblaze Bucket Name", 'xcloner-backup-and-restore')?></label>
534 534
 						</div>
535 535
 						<div class=" col s12 m6">
536
-							<input placeholder="<?php echo __("Backblaze Bucket Name",'xcloner-backup-and-restore')?>" id="backblaze_bucket_name" type="text" name="xcloner_backblaze_bucket_name" class="validate" value="<?php echo get_option("xcloner_backblaze_bucket_name")?>" autocomplete="off" >
536
+							<input placeholder="<?php echo __("Backblaze Bucket Name", 'xcloner-backup-and-restore')?>" id="backblaze_bucket_name" type="text" name="xcloner_backblaze_bucket_name" class="validate" value="<?php echo get_option("xcloner_backblaze_bucket_name")?>" autocomplete="off" >
537 537
 				        </div>
538 538
 			        </div>
539 539
 			        
540 540
 			        <div class="row">
541 541
 						<div class="col s12 m3 label">
542
-							<label for="backblaze_cleanup_days"><?php echo __("Backblaze Cleanup (days)",'xcloner-backup-and-restore')?></label>
542
+							<label for="backblaze_cleanup_days"><?php echo __("Backblaze Cleanup (days)", 'xcloner-backup-and-restore')?></label>
543 543
 						</div>
544 544
 						<div class=" col s12 m6">
545
-							<input placeholder="<?php echo __("how many days to keep the backups for",'xcloner-backup-and-restore')?>" id="backblaze_cleanup_days" type="text" name="xcloner_backblaze_cleanup_days" class="validate" value="<?php echo get_option("xcloner_backblaze_cleanup_days")?>">
545
+							<input placeholder="<?php echo __("how many days to keep the backups for", 'xcloner-backup-and-restore')?>" id="backblaze_cleanup_days" type="text" name="xcloner_backblaze_cleanup_days" class="validate" value="<?php echo get_option("xcloner_backblaze_cleanup_days")?>">
546 546
 				        </div>
547 547
 			        </div>
548 548
 			        
549 549
 			        <div class="row">
550 550
 						<div class="col s6 m4">
551
-							<button class="btn waves-effect waves-light" type="submit" name="action" id="action"  value="backblaze"><?php echo __("Save Settings",'xcloner-backup-and-restore')?>
551
+							<button class="btn waves-effect waves-light" type="submit" name="action" id="action"  value="backblaze"><?php echo __("Save Settings", 'xcloner-backup-and-restore')?>
552 552
 								<i class="material-icons right">save</i>
553 553
 							</button>
554 554
 						</div>	
555 555
 						<div class="col s6 m4">
556
-							<button class="btn waves-effect waves-light orange" type="submit" name="action" id="action"  value="backblaze" onclick="jQuery('#connection_check').val('1')"><?php echo __("Verify",'xcloner-backup-and-restore')?>
556
+							<button class="btn waves-effect waves-light orange" type="submit" name="action" id="action"  value="backblaze" onclick="jQuery('#connection_check').val('1')"><?php echo __("Verify", 'xcloner-backup-and-restore')?>
557 557
 								<i class="material-icons right">import_export</i>
558 558
 							</button>
559 559
 						</div>
@@ -565,11 +565,11 @@  discard block
 block discarded – undo
565 565
 			<!-- WEBDAV STORAGE-->
566 566
 			<li id="webdav">
567 567
 				<div class="collapsible-header">
568
-					<i class="material-icons">computer</i><?php echo __("WebDAV Storage",'xcloner-backup-and-restore')?>
568
+					<i class="material-icons">computer</i><?php echo __("WebDAV Storage", 'xcloner-backup-and-restore')?>
569 569
 					<div class="switch right">
570 570
 						<label>
571 571
 						Off
572
-						<input type="checkbox" name="xcloner_webdav_enable" class="status" value="1" <?php if(get_option("xcloner_webdav_enable")) echo "checked"?> \>
572
+						<input type="checkbox" name="xcloner_webdav_enable" class="status" value="1" <?php if (get_option("xcloner_webdav_enable")) echo "checked"?> \>
573 573
 						<span class="lever"></span>
574 574
 						On
575 575
 						</label>
@@ -590,57 +590,57 @@  discard block
 block discarded – undo
590 590
 			        
591 591
 			        <div class="row">
592 592
 						<div class="col s12 m3 label">
593
-							<label for="webdav_url"><?php echo __("WebDAV Base Url",'xcloner-backup-and-restore')?></label>
593
+							<label for="webdav_url"><?php echo __("WebDAV Base Url", 'xcloner-backup-and-restore')?></label>
594 594
 						</div>	
595 595
 						<div class=" col s12 m6">
596
-							<input placeholder="<?php echo __("WebDAV Base Url",'xcloner-backup-and-restore')?>" id="webdav_url" type="text" name="xcloner_webdav_url" class="validate" value="<?php echo get_option("xcloner_webdav_url")?>" autocomplete="off" >
596
+							<input placeholder="<?php echo __("WebDAV Base Url", 'xcloner-backup-and-restore')?>" id="webdav_url" type="text" name="xcloner_webdav_url" class="validate" value="<?php echo get_option("xcloner_webdav_url")?>" autocomplete="off" >
597 597
 				        </div>
598 598
 			        </div>
599 599
 			        
600 600
 			        <div class="row">
601 601
 						<div class="col s12 m3 label">
602
-							<label for="webdav_username"><?php echo __("WebDAV Username",'xcloner-backup-and-restore')?></label>
602
+							<label for="webdav_username"><?php echo __("WebDAV Username", 'xcloner-backup-and-restore')?></label>
603 603
 						</div>
604 604
 						<div class=" col s12 m6">
605
-							<input placeholder="<?php echo __("WebDAV Username",'xcloner-backup-and-restore')?>" id="webdav_username" type="text" name="xcloner_webdav_username" class="validate" value="<?php echo get_option("xcloner_webdav_username")?>" autocomplete="off" >
605
+							<input placeholder="<?php echo __("WebDAV Username", 'xcloner-backup-and-restore')?>" id="webdav_username" type="text" name="xcloner_webdav_username" class="validate" value="<?php echo get_option("xcloner_webdav_username")?>" autocomplete="off" >
606 606
 				        </div>
607 607
 			        </div>
608 608
 			        
609 609
 			        <div class="row">
610 610
 						<div class="col s12 m3 label">
611
-							<label for="webdav_password"><?php echo __("WebDAV Password",'xcloner-backup-and-restore')?></label>
611
+							<label for="webdav_password"><?php echo __("WebDAV Password", 'xcloner-backup-and-restore')?></label>
612 612
 						</div>
613 613
 						<div class=" col s12 m6">
614
-							<input placeholder="<?php echo __("WebDAV Password",'xcloner-backup-and-restore')?>" id="webdav_password" type="password" name="xcloner_webdav_password" class="validate" value="<?php echo get_option("xcloner_webdav_password")?>" autocomplete="off" >
614
+							<input placeholder="<?php echo __("WebDAV Password", 'xcloner-backup-and-restore')?>" id="webdav_password" type="password" name="xcloner_webdav_password" class="validate" value="<?php echo get_option("xcloner_webdav_password")?>" autocomplete="off" >
615 615
 				        </div>
616 616
 			        </div>
617 617
 			        
618 618
 			        <div class="row">
619 619
 						<div class="col s12 m3 label">
620
-							<label for="webdav_target_folder"><?php echo __("WebDAV Target Folder",'xcloner-backup-and-restore')?></label>
620
+							<label for="webdav_target_folder"><?php echo __("WebDAV Target Folder", 'xcloner-backup-and-restore')?></label>
621 621
 						</div>	
622 622
 						<div class=" col s12 m6">
623
-							<input placeholder="<?php echo __("WebDAV Target Folder",'xcloner-backup-and-restore')?>" id="webdav_target_folder" type="text" name="xcloner_webdav_target_folder" class="validate" value="<?php echo get_option("xcloner_webdav_target_folder")?>" autocomplete="off" >
623
+							<input placeholder="<?php echo __("WebDAV Target Folder", 'xcloner-backup-and-restore')?>" id="webdav_target_folder" type="text" name="xcloner_webdav_target_folder" class="validate" value="<?php echo get_option("xcloner_webdav_target_folder")?>" autocomplete="off" >
624 624
 				        </div>
625 625
 			        </div>
626 626
 			        
627 627
 			        <div class="row">
628 628
 						<div class="col s12 m3 label">
629
-							<label for="webdav_cleanup_days"><?php echo __("WebDAV Cleanup (days)",'xcloner-backup-and-restore')?></label>
629
+							<label for="webdav_cleanup_days"><?php echo __("WebDAV Cleanup (days)", 'xcloner-backup-and-restore')?></label>
630 630
 						</div>
631 631
 						<div class=" col s12 m6">
632
-							<input placeholder="<?php echo __("how many days to keep the backups for",'xcloner-backup-and-restore')?>" id="webdav_cleanup_days" type="text" name="xcloner_webdav_cleanup_days" class="validate" value="<?php echo get_option("xcloner_webdav_cleanup_days")?>">
632
+							<input placeholder="<?php echo __("how many days to keep the backups for", 'xcloner-backup-and-restore')?>" id="webdav_cleanup_days" type="text" name="xcloner_webdav_cleanup_days" class="validate" value="<?php echo get_option("xcloner_webdav_cleanup_days")?>">
633 633
 				        </div>
634 634
 			        </div>
635 635
 			        
636 636
 			        <div class="row">
637 637
 						<div class="col s6 m4">
638
-							<button class="btn waves-effect waves-light" type="submit" name="action" id="action"  value="webdav"><?php echo __("Save Settings",'xcloner-backup-and-restore')?>
638
+							<button class="btn waves-effect waves-light" type="submit" name="action" id="action"  value="webdav"><?php echo __("Save Settings", 'xcloner-backup-and-restore')?>
639 639
 								<i class="material-icons right">save</i>
640 640
 							</button>
641 641
 						</div>	
642 642
 						<div class="col s6 m4">
643
-							<button class="btn waves-effect waves-light orange" type="submit" name="action" id="action"  value="webdav" onclick="jQuery('#connection_check').val('1')"><?php echo __("Verify",'xcloner-backup-and-restore')?>
643
+							<button class="btn waves-effect waves-light orange" type="submit" name="action" id="action"  value="webdav" onclick="jQuery('#connection_check').val('1')"><?php echo __("Verify", 'xcloner-backup-and-restore')?>
644 644
 								<i class="material-icons right">import_export</i>
645 645
 							</button>
646 646
 						</div>
@@ -652,12 +652,12 @@  discard block
 block discarded – undo
652 652
 			<!-- Google DRIVE STORAGE-->
653 653
 			<li id="gdrive">
654 654
 				<div class="collapsible-header">
655
-					<i class="material-icons">computer</i><?php echo __("Google Drive Storage",'xcloner-backup-and-restore')?>
656
-					<?php if($gdrive_construct):?>
655
+					<i class="material-icons">computer</i><?php echo __("Google Drive Storage", 'xcloner-backup-and-restore')?>
656
+					<?php if ($gdrive_construct):?>
657 657
 					<div class="switch right">
658 658
 						<label>
659 659
 						Off
660
-						<input type="checkbox" name="xcloner_gdrive_enable" class="status" value="1" <?php if(get_option("xcloner_gdrive_enable")) echo "checked"?> \>
660
+						<input type="checkbox" name="xcloner_gdrive_enable" class="status" value="1" <?php if (get_option("xcloner_gdrive_enable")) echo "checked"?> \>
661 661
 						<span class="lever"></span>
662 662
 						On
663 663
 						</label>
@@ -666,7 +666,7 @@  discard block
 block discarded – undo
666 666
 				</div>
667 667
 				<div class="collapsible-body">
668 668
 			        
669
-			        <?php if($gdrive_construct) : ?>
669
+			        <?php if ($gdrive_construct) : ?>
670 670
 			        
671 671
 				        <div class="row">
672 672
 							<div class="col s12 m3 label">
@@ -674,28 +674,28 @@  discard block
 block discarded – undo
674 674
 							</div>	
675 675
 							<div class=" col s12 m9">
676 676
 								<p>
677
-									<?php echo sprintf(__('Visit %s to create a new application and get your Client ID and Client Secret.','xcloner-backup-and-restore'), '<a href="https://console.developers.google.com" target="_blank">https://console.developers.google.com</a>')?>
677
+									<?php echo sprintf(__('Visit %s to create a new application and get your Client ID and Client Secret.', 'xcloner-backup-and-restore'), '<a href="https://console.developers.google.com" target="_blank">https://console.developers.google.com</a>')?>
678 678
 									<a href="https://youtu.be/YXUVPUVgG8k" target="_blank" class="btn-floating tooltipped btn-small" data-position="right" data-delay="50" data-html="true" 
679
-									data-tooltip="<?php echo sprintf(__('Click here to view a short video explaining how to create the Client ID and Client Secret as well as connecting XCloner with the Google Drive API %s','xcloner-backup-and-restore'),"<br />https://youtu.be/YXUVPUVgG8k")?>" data-tooltip-id="92c95730-94e9-7b59-bd52-14adc30d5e3e"><i class="material-icons">help_outline</i></a>	
679
+									data-tooltip="<?php echo sprintf(__('Click here to view a short video explaining how to create the Client ID and Client Secret as well as connecting XCloner with the Google Drive API %s', 'xcloner-backup-and-restore'), "<br />https://youtu.be/YXUVPUVgG8k")?>" data-tooltip-id="92c95730-94e9-7b59-bd52-14adc30d5e3e"><i class="material-icons">help_outline</i></a>	
680 680
 								</p>
681 681
 					        </div>
682 682
 				        </div>
683 683
 			        
684 684
 						<div class="row">
685 685
 							<div class="col s12 m3 label">
686
-								<label for="gdrive_client_id"><?php echo __("Client ID",'xcloner-backup-and-restore')?></label>
686
+								<label for="gdrive_client_id"><?php echo __("Client ID", 'xcloner-backup-and-restore')?></label>
687 687
 							</div>
688 688
 							<div class=" col s12 m6">
689
-								<input placeholder="<?php echo __("Google Client ID",'xcloner-backup-and-restore')?>" id="gdrive_client_id" type="text" name="xcloner_gdrive_client_id" class="validate" value="<?php echo get_option("xcloner_gdrive_client_id")?>">
689
+								<input placeholder="<?php echo __("Google Client ID", 'xcloner-backup-and-restore')?>" id="gdrive_client_id" type="text" name="xcloner_gdrive_client_id" class="validate" value="<?php echo get_option("xcloner_gdrive_client_id")?>">
690 690
 					        </div>
691 691
 				        </div>
692 692
 				        
693 693
 				        <div class="row">
694 694
 							<div class="col s12 m3 label">
695
-								<label for="gdrive_client_secret"><?php echo __("Client Secret",'xcloner-backup-and-restore')?></label>
695
+								<label for="gdrive_client_secret"><?php echo __("Client Secret", 'xcloner-backup-and-restore')?></label>
696 696
 							</div>
697 697
 							<div class=" col s12 m6">
698
-								<input placeholder="<?php echo __("Google Client Secret",'xcloner-backup-and-restore')?>" id="gdrive_client_secret" type="text" name="xcloner_gdrive_client_secret" class="validate" value="<?php echo get_option("xcloner_gdrive_client_secret")?>">
698
+								<input placeholder="<?php echo __("Google Client Secret", 'xcloner-backup-and-restore')?>" id="gdrive_client_secret" type="text" name="xcloner_gdrive_client_secret" class="validate" value="<?php echo get_option("xcloner_gdrive_client_secret")?>">
699 699
 					        </div>
700 700
 				        </div>
701 701
 				        
@@ -705,41 +705,41 @@  discard block
 block discarded – undo
705 705
 								&nbsp;
706 706
 							</div>	
707 707
 							<div class=" col s12 m6">
708
-									<a class="btn" target="_blank" id="gdrive_authorization_click" onclick="jQuery('#authentification_code').show()" href="<?php echo $gdrive_auth_url?>"><?php echo sprintf(__('Authorize Google Drive','xcloner-backup-and-restore'))?></a>
709
-									<input type="text" name="authentification_code" id="authentification_code" placeholder="<?php echo __("Paste Authorization Code Here","xcloner-backup-and-restore")?>">
708
+									<a class="btn" target="_blank" id="gdrive_authorization_click" onclick="jQuery('#authentification_code').show()" href="<?php echo $gdrive_auth_url?>"><?php echo sprintf(__('Authorize Google Drive', 'xcloner-backup-and-restore'))?></a>
709
+									<input type="text" name="authentification_code" id="authentification_code" placeholder="<?php echo __("Paste Authorization Code Here", "xcloner-backup-and-restore")?>">
710 710
 					        </div>
711 711
 				        </div>
712 712
 				        
713 713
 				        <div class="row">
714 714
 							<div class="col s12 m3 label">
715
-								<label for="gdrive_target_folder"><?php echo __("Folder ID or Root Path",'xcloner-backup-and-restore')?>
715
+								<label for="gdrive_target_folder"><?php echo __("Folder ID or Root Path", 'xcloner-backup-and-restore')?>
716 716
 									<a class="btn-floating tooltipped btn-small" data-position="right" data-delay="50" data-html="true" \
717 717
 									data-tooltip="<?php echo __('Folder ID can be found by right clicking on the folder name and selecting \'Get shareable link\' menu, format https://drive.google.com/open?id={FOLDER_ID}<br />
718 718
 									If you supply a folder name, it has to exists in the drive root and start with / , example /backups.xcloner.com/','xcloner-backup-and-restore')?>" data-tooltip-id="92c95730-94e9-7b59-bd52-14adc30d5e3e"><i class="material-icons">help_outline</i></a>	
719 719
 								</label>
720 720
 							</div>	
721 721
 							<div class=" col s12 m6">
722
-								<input placeholder="<?php echo __("Target Folder ID or Root Path",'xcloner-backup-and-restore')?>" id="gdrive_target_folder" type="text" name="xcloner_gdrive_target_folder" class="validate" value="<?php echo get_option("xcloner_gdrive_target_folder")?>" autocomplete="off" >
722
+								<input placeholder="<?php echo __("Target Folder ID or Root Path", 'xcloner-backup-and-restore')?>" id="gdrive_target_folder" type="text" name="xcloner_gdrive_target_folder" class="validate" value="<?php echo get_option("xcloner_gdrive_target_folder")?>" autocomplete="off" >
723 723
 					        </div>
724 724
 				        </div>
725 725
 				        
726 726
 				        <div class="row">
727 727
 							<div class="col s12 m3 label">
728
-								<label for="gdrive_cleanup_days"><?php echo __("Google Drive Cleanup (days)",'xcloner-backup-and-restore')?></label>
728
+								<label for="gdrive_cleanup_days"><?php echo __("Google Drive Cleanup (days)", 'xcloner-backup-and-restore')?></label>
729 729
 							</div>
730 730
 							<div class=" col s12 m6">
731
-								<input placeholder="<?php echo __("how many days to keep the backups for",'xcloner-backup-and-restore')?>" id="gdrive_cleanup_days" type="text" name="xcloner_gdrive_cleanup_days" class="validate" value="<?php echo get_option("xcloner_gdrive_cleanup_days")?>">
731
+								<input placeholder="<?php echo __("how many days to keep the backups for", 'xcloner-backup-and-restore')?>" id="gdrive_cleanup_days" type="text" name="xcloner_gdrive_cleanup_days" class="validate" value="<?php echo get_option("xcloner_gdrive_cleanup_days")?>">
732 732
 					        </div>
733 733
 				        </div>
734 734
 				        
735 735
 				        <div class="row">
736 736
 							<div class="col s6 m4">
737
-								<button class="btn waves-effect waves-light" type="submit" name="action" id="action"  value="gdrive"><?php echo __("Save Settings",'xcloner-backup-and-restore')?>
737
+								<button class="btn waves-effect waves-light" type="submit" name="action" id="action"  value="gdrive"><?php echo __("Save Settings", 'xcloner-backup-and-restore')?>
738 738
 									<i class="material-icons right">save</i>
739 739
 								</button>
740 740
 							</div>	
741 741
 							<div class="col s6 m4">
742
-								<button class="btn waves-effect waves-light orange" type="submit" name="action" id="action"  value="gdrive" onclick="jQuery('#connection_check').val('1')"><?php echo __("Verify",'xcloner-backup-and-restore')?>
742
+								<button class="btn waves-effect waves-light orange" type="submit" name="action" id="action"  value="gdrive" onclick="jQuery('#connection_check').val('1')"><?php echo __("Verify", 'xcloner-backup-and-restore')?>
743 743
 									<i class="material-icons right">import_export</i>
744 744
 								</button>
745 745
 							</div>
@@ -755,15 +755,15 @@  discard block
 block discarded – undo
755 755
 									<h6><?php echo __("This storage option requires the XCloner-Google-Drive Wordpress Plugin to be installed and activated.")?></h6>
756 756
 									<h6><?php echo __("PHP 5.5 minimum version is required.")?></h6>
757 757
 									<br />
758
-									<a class="install-now btn" data-slug="xcloner-google-drive" href="<?php echo $url;?>" aria-label="Install XCloner Google Drive 1.0.0 now" data-name="XCloner Google Drive 1.0.0">
759
-										<?php echo sprintf(__('Install Now','xcloner-backup-and-restore'))?>
758
+									<a class="install-now btn" data-slug="xcloner-google-drive" href="<?php echo $url; ?>" aria-label="Install XCloner Google Drive 1.0.0 now" data-name="XCloner Google Drive 1.0.0">
759
+										<?php echo sprintf(__('Install Now', 'xcloner-backup-and-restore'))?>
760 760
 									</a>
761 761
 									
762 762
 									<a href="<?php echo admin_url("plugin-install.php")?>?tab=plugin-information&amp;plugin=xcloner-google-drive&amp;TB_iframe=true&amp;width=772&amp;height=499" class="btn thickbox open-plugin-details-modal" aria-label="More information about Theme Check 20160523.1" data-title="Theme Check 20160523.1">
763 763
 									<!--
764 764
 									<a class="btn" href="https://github.com/ovidiul/XCloner-Google-Drive/archive/master.zip">
765 765
 									-->
766
-										<?php echo sprintf(__('More Details','xcloner-backup-and-restore'))?>
766
+										<?php echo sprintf(__('More Details', 'xcloner-backup-and-restore'))?>
767 767
 									</a>
768 768
 								</div>
769 769
 					        </div>
Please login to merge, or discard this patch.
includes/class-xcloner-logger.php 2 patches
Spacing   +20 added lines, -20 removed lines patch added patch discarded remove patch
@@ -4,44 +4,44 @@  discard block
 block discarded – undo
4 4
 use Monolog\Handler\StreamHandler;
5 5
 use Monolog\Handler\RotatingFileHandler;
6 6
 
7
-class Xcloner_Logger extends Logger{
7
+class Xcloner_Logger extends Logger {
8 8
 	
9
-	private $logger_path ;
9
+	private $logger_path;
10 10
 	private $max_logger_files = 7;
11 11
 	private $main_logger_url;
12 12
 	
13 13
 	public function __construct(Xcloner $xcloner_container, $logger_name = "xcloner_logger")
14 14
 	{
15
-		if(!$xcloner_container->get_xcloner_settings())
15
+		if (!$xcloner_container->get_xcloner_settings())
16 16
 		{
17 17
 			$xcloner_settings 	= new Xcloner_Settings($xcloner_container);
18
-		}else{
18
+		} else {
19 19
 			$xcloner_settings 	= $xcloner_container->get_xcloner_settings();
20 20
 		}
21 21
 		
22 22
 		$hash = $xcloner_settings->get_hash();
23
-		if($hash == "-".$xcloner_settings->get_server_unique_hash(5))
23
+		if ($hash == "-".$xcloner_settings->get_server_unique_hash(5))
24 24
 		{
25 25
 			$hash = "";
26 26
 		}
27 27
 		
28
-		$logger_path 		= $xcloner_settings->get_xcloner_store_path().DS.$xcloner_settings->get_logger_filename();
29
-		$logger_path_tmp 	= "";
28
+		$logger_path = $xcloner_settings->get_xcloner_store_path().DS.$xcloner_settings->get_logger_filename();
29
+		$logger_path_tmp = "";
30 30
 		
31
-		if($hash)
31
+		if ($hash)
32 32
 		{
33 33
 			$logger_path_tmp = $xcloner_settings->get_xcloner_tmp_path().DS.$xcloner_settings->get_logger_filename(1);
34 34
 		}
35 35
 		
36 36
 		$this->logger_path = $logger_path;
37 37
 		
38
-		if(!is_dir($xcloner_settings->get_xcloner_store_path()) or !is_writable($xcloner_settings->get_xcloner_store_path()))
38
+		if (!is_dir($xcloner_settings->get_xcloner_store_path()) or !is_writable($xcloner_settings->get_xcloner_store_path()))
39 39
 		{
40 40
 			$logger_path = 'php://stderr';
41 41
 			$logger_path_tmp = "";
42 42
 		}
43 43
 		
44
-		if(!$xcloner_settings->get_xcloner_option('xcloner_enable_log'))
44
+		if (!$xcloner_settings->get_xcloner_option('xcloner_enable_log'))
45 45
 		{
46 46
 			$logger_path = 'php://stderr';
47 47
 			$logger_path_tmp = "";
@@ -52,27 +52,27 @@  discard block
 block discarded – undo
52 52
 		
53 53
 		$debug_level = Logger::INFO;
54 54
 		
55
-		if(WP_DEBUG)
55
+		if (WP_DEBUG)
56 56
 		{
57 57
 			$debug_level = Logger::DEBUG;
58 58
 		}
59 59
 
60 60
 	
61
-		if($logger_path)
61
+		if ($logger_path)
62 62
 		{
63
-			if(!$xcloner_settings->get_xcloner_option('xcloner_enable_log'))
63
+			if (!$xcloner_settings->get_xcloner_option('xcloner_enable_log'))
64 64
 			{
65 65
 				$stream = new StreamHandler($logger_path, $debug_level);
66
-			}else{
66
+			} else {
67 67
 				$stream = new RotatingFileHandler($logger_path, $this->max_logger_files, $debug_level);
68 68
 			}
69 69
 				
70 70
 			$this->pushHandler($stream);
71 71
 			
72
-			$this->main_logger_url =  $stream->getUrl();
72
+			$this->main_logger_url = $stream->getUrl();
73 73
 		}
74 74
 			
75
-		if($hash and $logger_path_tmp)
75
+		if ($hash and $logger_path_tmp)
76 76
 		{
77 77
 			$this->pushHandler(new StreamHandler($logger_path_tmp, $debug_level));
78 78
 		}
@@ -89,7 +89,7 @@  discard block
 block discarded – undo
89 89
 	{
90 90
 		$lines = array();
91 91
 		
92
-		if(!file_exists($this->main_logger_url) or !is_readable($this->main_logger_url))
92
+		if (!file_exists($this->main_logger_url) or !is_readable($this->main_logger_url))
93 93
 			return false;
94 94
 		
95 95
 		$fp = fopen($this->main_logger_url, 'r');
@@ -98,12 +98,12 @@  discard block
 block discarded – undo
98 98
 		$lastLine = "";
99 99
 		
100 100
 		// Loop backword until we have our lines or we reach the start
101
-		while($pos > 0 && count($lines) < $totalLines) {
101
+		while ($pos > 0 && count($lines) < $totalLines) {
102 102
 		
103 103
 		$C = fgetc($fp);
104
-		if($C == "\n") {
104
+		if ($C == "\n") {
105 105
 		  // skip empty lines
106
-		  if(trim($lastLine) != "") {
106
+		  if (trim($lastLine) != "") {
107 107
 			$lines[] = $lastLine;
108 108
 		  }
109 109
 		  $lastLine = '';
Please login to merge, or discard this patch.
Braces   +5 added lines, -4 removed lines patch added patch discarded remove patch
@@ -15,7 +15,7 @@  discard block
 block discarded – undo
15 15
 		if(!$xcloner_container->get_xcloner_settings())
16 16
 		{
17 17
 			$xcloner_settings 	= new Xcloner_Settings($xcloner_container);
18
-		}else{
18
+		} else{
19 19
 			$xcloner_settings 	= $xcloner_container->get_xcloner_settings();
20 20
 		}
21 21
 		
@@ -63,7 +63,7 @@  discard block
 block discarded – undo
63 63
 			if(!$xcloner_settings->get_xcloner_option('xcloner_enable_log'))
64 64
 			{
65 65
 				$stream = new StreamHandler($logger_path, $debug_level);
66
-			}else{
66
+			} else{
67 67
 				$stream = new RotatingFileHandler($logger_path, $this->max_logger_files, $debug_level);
68 68
 			}
69 69
 				
@@ -89,8 +89,9 @@  discard block
 block discarded – undo
89 89
 	{
90 90
 		$lines = array();
91 91
 		
92
-		if(!file_exists($this->main_logger_url) or !is_readable($this->main_logger_url))
93
-			return false;
92
+		if(!file_exists($this->main_logger_url) or !is_readable($this->main_logger_url)) {
93
+					return false;
94
+		}
94 95
 		
95 96
 		$fp = fopen($this->main_logger_url, 'r');
96 97
 		fseek($fp, -1, SEEK_END);
Please login to merge, or discard this patch.
includes/class-xcloner-deactivator.php 2 patches
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -33,11 +33,11 @@
 block discarded – undo
33 33
 		
34 34
 		global $xcloner_plugin;
35 35
 		
36
-		if(is_a($xcloner_plugin, 'Xcloner'))
36
+		if (is_a($xcloner_plugin, 'Xcloner'))
37 37
 		{
38
-			try{
38
+			try {
39 39
 				$xcloner_plugin->get_xcloner_filesystem()->cleanup_tmp_directories();
40
-			}catch(Exception $e)
40
+			}catch (Exception $e)
41 41
 			{
42 42
 				$xcloner_plugin->trigger_message_notice($e->getMessage());
43 43
 			}
Please login to merge, or discard this patch.
Braces   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -37,7 +37,7 @@
 block discarded – undo
37 37
 		{
38 38
 			try{
39 39
 				$xcloner_plugin->get_xcloner_filesystem()->cleanup_tmp_directories();
40
-			}catch(Exception $e)
40
+			} catch(Exception $e)
41 41
 			{
42 42
 				$xcloner_plugin->trigger_message_notice($e->getMessage());
43 43
 			}
Please login to merge, or discard this patch.
includes/class-xcloner.php 3 patches
Indentation   +21 added lines, -21 removed lines patch added patch discarded remove patch
@@ -307,7 +307,7 @@  discard block
 block discarded – undo
307 307
 		$this->loader->add_action( 'plugins_loaded', $plugin_i18n, 'load_plugin_textdomain' );
308 308
 		
309 309
 		//wp_localize_script( 'ajax-script', 'my_ajax_object',
310
-        //   array( 'ajax_url' => admin_url( 'admin-ajax.php' ) ) );
310
+		//   array( 'ajax_url' => admin_url( 'admin-ajax.php' ) ) );
311 311
 
312 312
 	}
313 313
 
@@ -341,8 +341,8 @@  discard block
 block discarded – undo
341 341
 	
342 342
 	private function define_plugin_settings(){
343 343
 		/**
344
-		* register wporg_settings_init to the admin_init action hook
345
-		*/
344
+		 * register wporg_settings_init to the admin_init action hook
345
+		 */
346 346
 
347 347
 		$this->xcloner_settings = new XCloner_Settings($this);
348 348
 				
@@ -487,15 +487,15 @@  discard block
 block discarded – undo
487 487
 	}
488 488
 	
489 489
 	function friendly_error_type($type) {
490
-	    static $levels=null;
491
-	    if ($levels===null) {
492
-	        $levels=[];
493
-	        foreach (get_defined_constants() as $key=>$value) {
494
-	            if (strpos($key,'E_')!==0) {continue;}
490
+		static $levels=null;
491
+		if ($levels===null) {
492
+			$levels=[];
493
+			foreach (get_defined_constants() as $key=>$value) {
494
+				if (strpos($key,'E_')!==0) {continue;}
495 495
 					$levels[$value]= $key; //substr($key,2);
496
-	        }
497
-	    }
498
-	    return (isset($levels[$type]) ? $levels[$type] : "Error #{$type}");
496
+			}
497
+		}
498
+		return (isset($levels[$type]) ? $levels[$type] : "Error #{$type}");
499 499
 	}
500 500
 		
501 501
 	private function define_ajax_hooks()
@@ -537,24 +537,24 @@  discard block
 block discarded – undo
537 537
 			add_action( 'wp_ajax_restore_backup', 				array($xcloner_api,'restore_backup')  );
538 538
 			add_action( 'admin_notices', 						array($this, 'xcloner_error_admin_notices' ));
539 539
             
540
-        }
540
+		}
541 541
         
542
-        //Do a pre-update backup of targeted files
543
-        if($this->get_xcloner_settings()->get_xcloner_option('xcloner_enable_pre_update_backup'))
544
-        {
542
+		//Do a pre-update backup of targeted files
543
+		if($this->get_xcloner_settings()->get_xcloner_option('xcloner_enable_pre_update_backup'))
544
+		{
545 545
 			add_action("pre_auto_update", array($this, "pre_auto_update"), 1, 3);
546 546
 		}
547 547
 	}
548 548
 	
549 549
 	function add_plugin_action_links($links, $file) {
550
-        if ($file == plugin_basename(dirname(dirname(__FILE__)) . '/xcloner.php'))
550
+		if ($file == plugin_basename(dirname(dirname(__FILE__)) . '/xcloner.php'))
551 551
 		{	
552 552
 			$links[] = '<a href="admin.php?page=xcloner_settings_page">'.__('Settings', 'xcloner-backup-and-restore').'</a>';
553 553
 			$links[] = '<a href="admin.php?page=xcloner_generate_backups_page">'.__('Generate Backup', 'xcloner-backup-and-restore').'</a>';
554 554
 		}
555 555
         
556
-        return $links;
557
-    }
556
+		return $links;
557
+	}
558 558
 	
559 559
 	public function xcloner_error_admin_notices() {
560 560
 			settings_errors( 'xcloner_error_message' );
@@ -638,9 +638,9 @@  discard block
 block discarded – undo
638 638
 	function xcloner_display()
639 639
 	{	
640 640
 		// check user capabilities
641
-	    if (!current_user_can('manage_options')) {
642
-	        return;
643
-	    }
641
+		if (!current_user_can('manage_options')) {
642
+			return;
643
+		}
644 644
 	
645 645
 		$page = sanitize_key($_GET['page']);
646 646
 
Please login to merge, or discard this patch.
Spacing   +83 added lines, -83 removed lines patch added patch discarded remove patch
@@ -148,15 +148,15 @@  discard block
 block discarded – undo
148 148
 		return $this->xcloner_file_transfer;
149 149
 	}
150 150
 	
151
-	public function check_dependencies(){
151
+	public function check_dependencies() {
152 152
 		
153 153
 		$backup_storage_path = realpath(__DIR__.DS."..".DS."..".DS."..").DS."backups".DS;
154 154
 		
155 155
 		define("XCLONER_STORAGE_PATH", realpath($backup_storage_path));
156 156
 
157
-		if(!is_dir($backup_storage_path))
157
+		if (!is_dir($backup_storage_path))
158 158
 		{
159
-			if(!@mkdir($backup_storage_path))
159
+			if (!@mkdir($backup_storage_path))
160 160
 			{
161 161
 				$status = "error";
162 162
 				$message = sprintf(__("Unable to create the Backup Storage Location Folder %s . Please fix this before starting the backup process."), $backup_storage_path);
@@ -164,7 +164,7 @@  discard block
 block discarded – undo
164 164
 				return;
165 165
 			}
166 166
 		}	
167
-		if(!is_writable($backup_storage_path))
167
+		if (!is_writable($backup_storage_path))
168 168
 		{
169 169
 			$status = "error";
170 170
 			$message = sprintf(__("Unable to write to the Backup Storage Location Folder %s . Please fix this before starting the backup process."), $backup_storage_path);
@@ -178,15 +178,15 @@  discard block
 block discarded – undo
178 178
 	public function trigger_message($message, $status = "error", $message_param1 = "", $message_param2 = "", $message_param3 = "")
179 179
 	{
180 180
 			$message = sprintf(__($message), $message_param1, $message_param2, $message_param3);
181
-			add_action( 'xcloner_admin_notices', array($this,"trigger_message_notice"), 10, 2);
182
-			do_action( 'xcloner_admin_notices', $message, $status);
181
+			add_action('xcloner_admin_notices', array($this, "trigger_message_notice"), 10, 2);
182
+			do_action('xcloner_admin_notices', $message, $status);
183 183
 	}
184 184
 	
185 185
 	public function trigger_message_notice($message, $status = "success")
186 186
 	{
187 187
 		?>
188 188
 		<div class="notice notice-<?php echo $status?> is-dismissible">
189
-	        <p><?php _e( $message, 'xcloner-backup-and-restore' ); ?></p>
189
+	        <p><?php _e($message, 'xcloner-backup-and-restore'); ?></p>
190 190
 	    </div>
191 191
 		<?php
192 192
 	}
@@ -213,79 +213,79 @@  discard block
 block discarded – undo
213 213
 		 * The class responsible for orchestrating the actions and filters of the
214 214
 		 * core plugin.
215 215
 		 */
216
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-xcloner-loader.php';
216
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-xcloner-loader.php';
217 217
 
218 218
 		/**
219 219
 		 * The class responsible for defining internationalization functionality
220 220
 		 * of the plugin.
221 221
 		 */
222
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-xcloner-i18n.php';
222
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-xcloner-i18n.php';
223 223
 
224 224
 		/**
225 225
 		 * The class responsible for defining all actions that occur in the admin area.
226 226
 		 */
227
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-xcloner-admin.php';
227
+		require_once plugin_dir_path(dirname(__FILE__)).'admin/class-xcloner-admin.php';
228 228
 		
229 229
 		/**
230 230
 		 * The class responsible for debugging XCloner.
231 231
 		 */
232
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-xcloner-logger.php';
232
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-xcloner-logger.php';
233 233
 		
234 234
 		/**
235 235
 		 * The class responsible for defining the admin settings area.
236 236
 		 */
237
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-xcloner-settings.php';
237
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-xcloner-settings.php';
238 238
 		
239 239
 		/**
240 240
 		 * The class responsible for defining the Remote Storage settings area.
241 241
 		 */
242
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-xcloner-remote-storage.php';
242
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-xcloner-remote-storage.php';
243 243
 		
244 244
 		/**
245 245
 		 * The class responsible for implementing the database backup methods.
246 246
 		 */
247
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-xcloner-database.php';
247
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-xcloner-database.php';
248 248
 		
249 249
 		/**
250 250
 		 * The class responsible for sanitization of users input.
251 251
 		 */
252
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-xcloner-sanitization.php';
252
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-xcloner-sanitization.php';
253 253
 		
254 254
 		/**
255 255
 		 * The class responsible for XCloner system requirements validation.
256 256
 		 */
257
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-xcloner-requirements.php';
257
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-xcloner-requirements.php';
258 258
 		
259 259
 		/**
260 260
 		 * The class responsible for XCloner backup archive creation.
261 261
 		 */
262
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-xcloner-archive.php';
262
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-xcloner-archive.php';
263 263
 		
264 264
 		/**
265 265
 		 * The class responsible for XCloner API requests.
266 266
 		 */
267
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-xcloner-api.php';
267
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-xcloner-api.php';
268 268
 		
269 269
 		/**
270 270
 		 * The class responsible for the XCloner File System methods.
271 271
 		 */
272
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-xcloner-file-system.php';
272
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-xcloner-file-system.php';
273 273
 		
274 274
 		/**
275 275
 		 * The class responsible for the XCloner File Transfer methods.
276 276
 		 */
277
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-xcloner-file-transfer.php';
277
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-xcloner-file-transfer.php';
278 278
 		
279 279
 		/**
280 280
 		 * The class responsible for the XCloner Scheduler methods.
281 281
 		 */
282
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-xcloner-scheduler.php';
282
+		require_once plugin_dir_path(dirname(__FILE__)).'includes/class-xcloner-scheduler.php';
283 283
 
284 284
 		/**
285 285
 		 * The class responsible for defining all actions that occur in the public-facing
286 286
 		 * side of the site.
287 287
 		 */
288
-		require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-xcloner-public.php';
288
+		require_once plugin_dir_path(dirname(__FILE__)).'public/class-xcloner-public.php';
289 289
 		
290 290
 		$this->loader = new Xcloner_Loader($this);
291 291
 
@@ -304,7 +304,7 @@  discard block
 block discarded – undo
304 304
 
305 305
 		$plugin_i18n = new Xcloner_i18n();
306 306
 
307
-		$this->loader->add_action( 'plugins_loaded', $plugin_i18n, 'load_plugin_textdomain' );
307
+		$this->loader->add_action('plugins_loaded', $plugin_i18n, 'load_plugin_textdomain');
308 308
 		
309 309
 		//wp_localize_script( 'ajax-script', 'my_ajax_object',
310 310
         //   array( 'ajax_url' => admin_url( 'admin-ajax.php' ) ) );
@@ -320,11 +320,11 @@  discard block
 block discarded – undo
320 320
 	 */
321 321
 	private function define_admin_hooks() {
322 322
 	
323
-		$plugin_admin = new Xcloner_Admin( $this );
323
+		$plugin_admin = new Xcloner_Admin($this);
324 324
 		$this->plugin_admin = $plugin_admin;
325 325
 
326
-		$this->loader->add_action( 'admin_enqueue_scripts', $plugin_admin, 'enqueue_styles' );
327
-		$this->loader->add_action( 'admin_enqueue_scripts', $plugin_admin, 'enqueue_scripts' );
326
+		$this->loader->add_action('admin_enqueue_scripts', $plugin_admin, 'enqueue_styles');
327
+		$this->loader->add_action('admin_enqueue_scripts', $plugin_admin, 'enqueue_scripts');
328 328
 		
329 329
 	}
330 330
 	
@@ -333,24 +333,24 @@  discard block
 block discarded – undo
333 333
 	 * 
334 334
 	 * @access 	private
335 335
 	 */
336
-	private function define_admin_menu(){
336
+	private function define_admin_menu() {
337 337
 		
338 338
 		add_action('admin_menu', array($this->loader, 'xcloner_backup_add_admin_menu'));
339 339
 		
340 340
 	}
341 341
 	
342
-	private function define_plugin_settings(){
342
+	private function define_plugin_settings() {
343 343
 		/**
344 344
 		* register wporg_settings_init to the admin_init action hook
345 345
 		*/
346 346
 
347 347
 		$this->xcloner_settings = new XCloner_Settings($this);
348 348
 				
349
-		if(defined('DOING_CRON') || isset($_POST['hash'])){
349
+		if (defined('DOING_CRON') || isset($_POST['hash'])) {
350 350
 			
351
-			if(defined('DOING_CRON') || $_POST['hash'] == "generate_hash"){
351
+			if (defined('DOING_CRON') || $_POST['hash'] == "generate_hash") {
352 352
 				$this->xcloner_settings->generate_new_hash();
353
-			}else{
353
+			} else {
354 354
 				$this->xcloner_settings->set_hash($_POST['hash']);
355 355
 			}
356 356
 		}
@@ -370,7 +370,7 @@  discard block
 block discarded – undo
370 370
 	 */
371 371
 	public function pre_auto_update($type, $item, $context)
372 372
 	{
373
-		if(!$type)
373
+		if (!$type)
374 374
 		{
375 375
 			return false;
376 376
 		}	
@@ -379,10 +379,10 @@  discard block
 block discarded – undo
379 379
 		
380 380
 		$content_dir = str_replace(ABSPATH, "", WP_CONTENT_DIR); 
381 381
 		$plugins_dir 	= str_replace(ABSPATH, "", WP_PLUGIN_DIR);
382
-		$langs_dir 		= $content_dir . DS . "languages";
383
-		$themes_dir 		= $content_dir . DS . "themes";
382
+		$langs_dir 		= $content_dir.DS."languages";
383
+		$themes_dir 		= $content_dir.DS."themes";
384 384
 						
385
-		switch ( $type ) {
385
+		switch ($type) {
386 386
 			case 'core':
387 387
 				$exclude_files = array(
388 388
 									"^(?!(wp-admin|wp-includes|(?!.*\/.*.php)))(.*)$",
@@ -392,7 +392,7 @@  discard block
 block discarded – undo
392 392
 			
393 393
 				$dir_array = explode(DS, $plugins_dir);
394 394
 				
395
-				foreach($dir_array as $dir)
395
+				foreach ($dir_array as $dir)
396 396
 				{
397 397
 					$data .= "\/".$dir;
398 398
 					$regex .= $data."$|";
@@ -408,7 +408,7 @@  discard block
 block discarded – undo
408 408
 
409 409
 				$dir_array = explode(DS, $themes_dir);
410 410
 				
411
-				foreach($dir_array as $dir)
411
+				foreach ($dir_array as $dir)
412 412
 				{
413 413
 					$data .= "\/".$dir;
414 414
 					$regex .= $data."$|";
@@ -424,7 +424,7 @@  discard block
 block discarded – undo
424 424
 
425 425
 				$dir_array = explode(DS, $langs_dir);
426 426
 				
427
-				foreach($dir_array as $dir)
427
+				foreach ($dir_array as $dir)
428 428
 				{
429 429
 					$data .= "\/".$dir;
430 430
 					$regex .= $data."$|";
@@ -450,9 +450,9 @@  discard block
 block discarded – undo
450 450
 		$schedule['backup_params']->email_notification = get_option('admin_email');
451 451
 		$schedule['backup_params']->backup_name = "backup_pre_auto_update_".$type."_[domain]-[time]-sql";
452 452
 		
453
-		try{
453
+		try {
454 454
 			$this->xcloner_scheduler->xcloner_scheduler_callback(0, $schedule);
455
-		}catch(Exception $e){
455
+		}catch (Exception $e) {
456 456
 			$this->get_xcloner_logger()->error($e->getMessage());
457 457
 		}
458 458
 	
@@ -467,10 +467,10 @@  discard block
 block discarded – undo
467 467
 	 */
468 468
 	private function define_public_hooks() {
469 469
 
470
-		$plugin_public = new Xcloner_Public( $this );
470
+		$plugin_public = new Xcloner_Public($this);
471 471
 
472
-		$this->loader->add_action( 'wp_enqueue_scripts', $plugin_public, 'enqueue_styles' );
473
-		$this->loader->add_action( 'wp_enqueue_scripts', $plugin_public, 'enqueue_scripts' );
472
+		$this->loader->add_action('wp_enqueue_scripts', $plugin_public, 'enqueue_styles');
473
+		$this->loader->add_action('wp_enqueue_scripts', $plugin_public, 'enqueue_scripts');
474 474
 
475 475
 	}
476 476
 	
@@ -479,20 +479,20 @@  discard block
 block discarded – undo
479 479
 		$logger = new XCloner_Logger($this, "php_system");
480 480
 		$error = error_get_last();
481 481
 		
482
-		if($error['type'] and $logger)
482
+		if ($error['type'] and $logger)
483 483
 		{
484
-			$logger->info($this->friendly_error_type ($error['type']).": ".var_export($error, true));
484
+			$logger->info($this->friendly_error_type($error['type']).": ".var_export($error, true));
485 485
 		}
486 486
 	
487 487
 	}
488 488
 	
489 489
 	function friendly_error_type($type) {
490
-	    static $levels=null;
491
-	    if ($levels===null) {
492
-	        $levels=[];
490
+	    static $levels = null;
491
+	    if ($levels === null) {
492
+	        $levels = [];
493 493
 	        foreach (get_defined_constants() as $key=>$value) {
494
-	            if (strpos($key,'E_')!==0) {continue;}
495
-					$levels[$value]= $key; //substr($key,2);
494
+	            if (strpos($key, 'E_') !== 0) {continue; }
495
+					$levels[$value] = $key; //substr($key,2);
496 496
 	        }
497 497
 	    }
498 498
 	    return (isset($levels[$type]) ? $levels[$type] : "Error #{$type}");
@@ -502,52 +502,52 @@  discard block
 block discarded – undo
502 502
 	{
503 503
 		//adding the pre-update hook
504 504
 		
505
-		if(is_admin() || defined('DOING_CRON'))
505
+		if (is_admin() || defined('DOING_CRON'))
506 506
 		{
507
-			$this->xcloner_logger 			= new XCloner_Logger($this, "xcloner_api");
508
-			$this->xcloner_filesystem 		= new Xcloner_File_System($this);
507
+			$this->xcloner_logger = new XCloner_Logger($this, "xcloner_api");
508
+			$this->xcloner_filesystem = new Xcloner_File_System($this);
509 509
 			
510 510
 			//$this->xcloner_filesystem->set_diff_timestamp_start (strtotime("-15 days"));
511 511
 			
512
-			$this->archive_system 			= new Xcloner_Archive($this);
513
-			$this->xcloner_database 		= new Xcloner_Database($this);
514
-			$this->xcloner_scheduler 		= new Xcloner_Scheduler($this);
515
-			$this->xcloner_remote_storage 	= new Xcloner_Remote_Storage($this);
516
-			$this->xcloner_file_transfer 	= new Xcloner_File_Transfer($this);
512
+			$this->archive_system = new Xcloner_Archive($this);
513
+			$this->xcloner_database = new Xcloner_Database($this);
514
+			$this->xcloner_scheduler = new Xcloner_Scheduler($this);
515
+			$this->xcloner_remote_storage = new Xcloner_Remote_Storage($this);
516
+			$this->xcloner_file_transfer = new Xcloner_File_Transfer($this);
517 517
 			
518
-			$xcloner_api 					= new Xcloner_Api($this);
518
+			$xcloner_api = new Xcloner_Api($this);
519 519
 
520
-			add_action( 'wp_ajax_get_database_tables_action', 	array($xcloner_api,'get_database_tables_action')  );
521
-			add_action( 'wp_ajax_get_file_system_action', 		array($xcloner_api,'get_file_system_action')  );
522
-			add_action( 'wp_ajax_scan_filesystem', 				array($xcloner_api,'scan_filesystem')  );
523
-			add_action( 'wp_ajax_backup_database', 				array($xcloner_api,'backup_database')  );
524
-			add_action( 'wp_ajax_backup_files'	, 				array($xcloner_api,'backup_files')  );
525
-			add_action( 'wp_ajax_save_schedule'	, 				array($xcloner_api,'save_schedule')  );
526
-			add_action( 'wp_ajax_get_schedule_by_id',	 		array($xcloner_api,'get_schedule_by_id')  );
527
-			add_action( 'wp_ajax_get_scheduler_list',	 		array($xcloner_api,'get_scheduler_list')  );
528
-			add_action( 'wp_ajax_delete_schedule_by_id'	, 		array($xcloner_api,'delete_schedule_by_id')  );
529
-			add_action( 'wp_ajax_delete_backup_by_name'	, 		array($xcloner_api,'delete_backup_by_name')  );
530
-			add_action( 'wp_ajax_download_backup_by_name', 		array($xcloner_api,'download_backup_by_name')  );
531
-			add_action( 'wp_ajax_remote_storage_save_status', 	array($xcloner_api,'remote_storage_save_status')  );
532
-			add_action( 'wp_ajax_upload_backup_to_remote', 		array($xcloner_api,'upload_backup_to_remote')  );
533
-			add_action( 'wp_ajax_list_backup_files'	,			array($xcloner_api,'list_backup_files')  );
534
-			add_action( 'wp_ajax_restore_upload_backup'	, 		array($xcloner_api,'restore_upload_backup')  );
535
-			add_action( 'wp_ajax_download_restore_script', 		array($xcloner_api,'download_restore_script')  );
536
-			add_action( 'wp_ajax_copy_backup_remote_to_local', 	array($xcloner_api,'copy_backup_remote_to_local')  );
537
-			add_action( 'wp_ajax_restore_backup', 				array($xcloner_api,'restore_backup')  );
538
-			add_action( 'admin_notices', 						array($this, 'xcloner_error_admin_notices' ));
520
+			add_action('wp_ajax_get_database_tables_action', array($xcloner_api, 'get_database_tables_action'));
521
+			add_action('wp_ajax_get_file_system_action', array($xcloner_api, 'get_file_system_action'));
522
+			add_action('wp_ajax_scan_filesystem', array($xcloner_api, 'scan_filesystem'));
523
+			add_action('wp_ajax_backup_database', array($xcloner_api, 'backup_database'));
524
+			add_action('wp_ajax_backup_files', array($xcloner_api, 'backup_files'));
525
+			add_action('wp_ajax_save_schedule', array($xcloner_api, 'save_schedule'));
526
+			add_action('wp_ajax_get_schedule_by_id', array($xcloner_api, 'get_schedule_by_id'));
527
+			add_action('wp_ajax_get_scheduler_list', array($xcloner_api, 'get_scheduler_list'));
528
+			add_action('wp_ajax_delete_schedule_by_id', array($xcloner_api, 'delete_schedule_by_id'));
529
+			add_action('wp_ajax_delete_backup_by_name', array($xcloner_api, 'delete_backup_by_name'));
530
+			add_action('wp_ajax_download_backup_by_name', array($xcloner_api, 'download_backup_by_name'));
531
+			add_action('wp_ajax_remote_storage_save_status', array($xcloner_api, 'remote_storage_save_status'));
532
+			add_action('wp_ajax_upload_backup_to_remote', array($xcloner_api, 'upload_backup_to_remote'));
533
+			add_action('wp_ajax_list_backup_files', array($xcloner_api, 'list_backup_files'));
534
+			add_action('wp_ajax_restore_upload_backup', array($xcloner_api, 'restore_upload_backup'));
535
+			add_action('wp_ajax_download_restore_script', array($xcloner_api, 'download_restore_script'));
536
+			add_action('wp_ajax_copy_backup_remote_to_local', array($xcloner_api, 'copy_backup_remote_to_local'));
537
+			add_action('wp_ajax_restore_backup', array($xcloner_api, 'restore_backup'));
538
+			add_action('admin_notices', array($this, 'xcloner_error_admin_notices'));
539 539
             
540 540
         }
541 541
         
542 542
         //Do a pre-update backup of targeted files
543
-        if($this->get_xcloner_settings()->get_xcloner_option('xcloner_enable_pre_update_backup'))
543
+        if ($this->get_xcloner_settings()->get_xcloner_option('xcloner_enable_pre_update_backup'))
544 544
         {
545 545
 			add_action("pre_auto_update", array($this, "pre_auto_update"), 1, 3);
546 546
 		}
547 547
 	}
548 548
 	
549 549
 	function add_plugin_action_links($links, $file) {
550
-        if ($file == plugin_basename(dirname(dirname(__FILE__)) . '/xcloner.php'))
550
+        if ($file == plugin_basename(dirname(dirname(__FILE__)).'/xcloner.php'))
551 551
 		{	
552 552
 			$links[] = '<a href="admin.php?page=xcloner_settings_page">'.__('Settings', 'xcloner-backup-and-restore').'</a>';
553 553
 			$links[] = '<a href="admin.php?page=xcloner_generate_backups_page">'.__('Generate Backup', 'xcloner-backup-and-restore').'</a>';
@@ -557,13 +557,13 @@  discard block
 block discarded – undo
557 557
     }
558 558
 	
559 559
 	public function xcloner_error_admin_notices() {
560
-			settings_errors( 'xcloner_error_message' );
560
+			settings_errors('xcloner_error_message');
561 561
 		}
562 562
 	
563 563
 	public function define_cron_hooks()
564 564
 	{
565 565
 		//registering new schedule intervals
566
-		add_filter( 'cron_schedules', array($this, 'add_new_intervals'));
566
+		add_filter('cron_schedules', array($this, 'add_new_intervals'));
567 567
 			
568 568
 		
569 569
 		$xcloner_scheduler = $this->get_xcloner_scheduler();
@@ -644,7 +644,7 @@  discard block
 block discarded – undo
644 644
 	
645 645
 		$page = sanitize_key($_GET['page']);
646 646
 
647
-		if($page)
647
+		if ($page)
648 648
 		{
649 649
 			$this->display($page);
650 650
 		}
Please login to merge, or discard this patch.
Braces   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -350,7 +350,7 @@  discard block
 block discarded – undo
350 350
 			
351 351
 			if(defined('DOING_CRON') || $_POST['hash'] == "generate_hash"){
352 352
 				$this->xcloner_settings->generate_new_hash();
353
-			}else{
353
+			} else{
354 354
 				$this->xcloner_settings->set_hash($_POST['hash']);
355 355
 			}
356 356
 		}
@@ -452,7 +452,7 @@  discard block
 block discarded – undo
452 452
 		
453 453
 		try{
454 454
 			$this->xcloner_scheduler->xcloner_scheduler_callback(0, $schedule);
455
-		}catch(Exception $e){
455
+		} catch(Exception $e){
456 456
 			$this->get_xcloner_logger()->error($e->getMessage());
457 457
 		}
458 458
 	
Please login to merge, or discard this patch.
admin/partials/xcloner_generate_backups_page.php 1 patch
Spacing   +53 added lines, -53 removed lines patch added patch discarded remove patch
@@ -11,13 +11,13 @@  discard block
 block discarded – undo
11 11
 <h1><?= esc_html(get_admin_page_title()); ?></h1>
12 12
          
13 13
 <ul class="nav-tab-wrapper content row">
14
-	<li><a href="#backup_options" class="nav-tab col s12 m3 l2 nav-tab-active"><?php echo $tab.". ".__('Backup Options','xcloner-backup-and-restore')?></a></li>
15
-	<?php if($xcloner_settings->get_enable_mysql_backup()):?>
16
-		<li><a href="#database_options" class="nav-tab col s12 m3 l2 "><?php echo ++$tab.". ".__('Database Options','xcloner-backup-and-restore')?></a></li>
14
+	<li><a href="#backup_options" class="nav-tab col s12 m3 l2 nav-tab-active"><?php echo $tab.". ".__('Backup Options', 'xcloner-backup-and-restore')?></a></li>
15
+	<?php if ($xcloner_settings->get_enable_mysql_backup()):?>
16
+		<li><a href="#database_options" class="nav-tab col s12 m3 l2 "><?php echo ++$tab.". ".__('Database Options', 'xcloner-backup-and-restore')?></a></li>
17 17
 	<?php endif?>
18
-	<li><a href="#files_options" class="nav-tab col s12 m3 l2 "><?php echo ++$tab.". ".__('Files Options','xcloner-backup-and-restore')?></a></li>
19
-	<li><a href="#generate_backup" class="nav-tab col s12 m3 l2 "><?php echo ++$tab.". ".__('Generate Backup','xcloner-backup-and-restore')?></a></li>
20
-	<li><a href="#schedule_backup" class="nav-tab col s12 m3 l2 "><?php echo ++$tab.". ".__('Schedule Backup','xcloner-backup-and-restore')?></a></li>
18
+	<li><a href="#files_options" class="nav-tab col s12 m3 l2 "><?php echo ++$tab.". ".__('Files Options', 'xcloner-backup-and-restore')?></a></li>
19
+	<li><a href="#generate_backup" class="nav-tab col s12 m3 l2 "><?php echo ++$tab.". ".__('Generate Backup', 'xcloner-backup-and-restore')?></a></li>
20
+	<li><a href="#schedule_backup" class="nav-tab col s12 m3 l2 "><?php echo ++$tab.". ".__('Schedule Backup', 'xcloner-backup-and-restore')?></a></li>
21 21
 </ul>
22 22
 
23 23
 <form action="" method="POST" id="generate_backup_form">
@@ -28,21 +28,21 @@  discard block
 block discarded – undo
28 28
 		        <div class="input-field inline col s12 m10 l6">
29 29
 					<i class="material-icons prefix">input</i>
30 30
 					<input name="backup_name" id="backup_name" type="text" value=<?php echo $xcloner_settings->get_default_backup_name() ?> >
31
-					<label for="backup_name"><?php echo __('Backup Name','xcloner-backup-and-restore')?></label>
31
+					<label for="backup_name"><?php echo __('Backup Name', 'xcloner-backup-and-restore')?></label>
32 32
 				</div>
33 33
 				<div class="hide-on-small-only m2">
34
-					<a class="btn-floating tooltipped btn-small" data-position="right" data-delay="50" data-tooltip="<?php echo __('The default backup name, supported tags [time], [hostname], [domain]','xcloner-backup-and-restore')?>" data-tooltip-id=""><i class="material-icons">help_outline</i></a>
34
+					<a class="btn-floating tooltipped btn-small" data-position="right" data-delay="50" data-tooltip="<?php echo __('The default backup name, supported tags [time], [hostname], [domain]', 'xcloner-backup-and-restore')?>" data-tooltip-id=""><i class="material-icons">help_outline</i></a>
35 35
 				</div>
36 36
 		     </div>
37 37
 		     
38 38
 		     <div class="row">
39 39
 		        <div class="input-field inline col s12 m10 l6">
40 40
 					<i class="material-icons prefix">email</i>
41
-					<input name="email_notification" id="email_notification" type="text" value="<?php echo get_option('admin_email');?>" >
42
-					<label for="email_notification"><?php echo __('Send Email Notification To','xcloner-backup-and-restore')?></label>
41
+					<input name="email_notification" id="email_notification" type="text" value="<?php echo get_option('admin_email'); ?>" >
42
+					<label for="email_notification"><?php echo __('Send Email Notification To', 'xcloner-backup-and-restore')?></label>
43 43
 				</div>
44 44
 				<div class="hide-on-small-only m2">
45
-					<a class="btn-floating tooltipped btn-small" data-position="right" data-delay="50" data-tooltip="<?php echo __('If left blank, no notification will be sent','xcloner-backup-and-restore')?>" data-tooltip-id=""><i class="material-icons">help_outline</i></a>
45
+					<a class="btn-floating tooltipped btn-small" data-position="right" data-delay="50" data-tooltip="<?php echo __('If left blank, no notification will be sent', 'xcloner-backup-and-restore')?>" data-tooltip-id=""><i class="material-icons">help_outline</i></a>
46 46
 				</div>
47 47
 		     </div>
48 48
 		     
@@ -50,7 +50,7 @@  discard block
 block discarded – undo
50 50
 				<div class="input-field inline col s10 m10 l6">
51 51
 					<i class="material-icons prefix">access_time</i>
52 52
 					<input type="datetime-local" id="diff_start_date" class="datepicker_max_today" name="diff_start_date" >
53
-					<label for="diff_start_date"><?php echo __('Backup Only Files Modified/Created After','xcloner-backup-and-restore')?></label>
53
+					<label for="diff_start_date"><?php echo __('Backup Only Files Modified/Created After', 'xcloner-backup-and-restore')?></label>
54 54
 				</div>
55 55
 				<div class="hide-on-small-only m2">	
56 56
 					<a class="btn-floating tooltipped btn-small" data-html="true" data-position="center" data-delay="50" data-tooltip="<?php echo __("This option allows you to create a differential backup that will include only <br> changed files since the set date, leave blank to include all files", "xcloner-backup-and-restore")?>"><i class="material-icons">help_outline</i></a>
@@ -61,10 +61,10 @@  discard block
 block discarded – undo
61 61
 				<div class="input-field col s12 m10 l6">
62 62
 					<i class="material-icons prefix">input</i>
63 63
 					<textarea name="backup_comments" id="backup_comments" class="materialize-textarea"></textarea>
64
-					<label for="backup_comments"><?php echo __('Backup Comments','xcloner-backup-and-restore')?></label>
64
+					<label for="backup_comments"><?php echo __('Backup Comments', 'xcloner-backup-and-restore')?></label>
65 65
 				</div>
66 66
 				<div class="hide-on-small-only m2">
67
-					<a class="btn-floating tooltipped btn-small" data-position="right" data-delay="50" data-tooltip="<?php echo __('Some default backup comments that will be stored inside the backup archive','xcloner-backup-and-restore')?>" data-tooltip-id=""><i class="material-icons">help_outline</i></a>
67
+					<a class="btn-floating tooltipped btn-small" data-position="right" data-delay="50" data-tooltip="<?php echo __('Some default backup comments that will be stored inside the backup archive', 'xcloner-backup-and-restore')?>" data-tooltip-id=""><i class="material-icons">help_outline</i></a>
68 68
 				</div>
69 69
 		     </div>
70 70
 		     
@@ -75,10 +75,10 @@  discard block
 block discarded – undo
75 75
 			 </div>
76 76
 		</div>
77 77
 		
78
-		<?php if($xcloner_settings->get_enable_mysql_backup()):?>
78
+		<?php if ($xcloner_settings->get_enable_mysql_backup()):?>
79 79
 		<div id="database_options" class="tab-content">
80 80
 			<h2><?php echo __('Select database data to include in the backup', 'xcloner-backup-and-restore')?>:
81
-				<a class="btn-floating tooltipped btn-small" data-position="right" data-delay="50" data-tooltip="<?php echo __('Enable the \'Backup only WP tables\' setting if you don\'t want to show all other databases and tables not related to this Wordpress install','xcloner-backup-and-restore');?>" data-tooltip-id=""><i class="material-icons">help_outline</i></a>
81
+				<a class="btn-floating tooltipped btn-small" data-position="right" data-delay="50" data-tooltip="<?php echo __('Enable the \'Backup only WP tables\' setting if you don\'t want to show all other databases and tables not related to this Wordpress install', 'xcloner-backup-and-restore'); ?>" data-tooltip-id=""><i class="material-icons">help_outline</i></a>
82 82
 			</h2>
83 83
 			
84 84
 			<!-- database/tables tree -->
@@ -98,8 +98,8 @@  discard block
 block discarded – undo
98 98
 		<?php endif ?>
99 99
 		
100 100
 		<div id="files_options" class="tab-content">
101
-			<h2><?php echo __('Select from below the files/folders you want to exclude from your Backup Archive','xcloner-backup-and-restore')?>:
102
-				<a class="btn-floating tooltipped btn-small" data-position="bottom" data-delay="50" data-html="true" data-tooltip="<?php echo __('You can navigate below through all your site structure(Backup Start Location) to exclude any file/folder you need by clicking the checkbox near it. <br />If the checkobx is disabled, then it matches a Regex Exclude File option and it can\'t be unchecked','xcloner-backup-and-restore');?>" data-tooltip-id=""><i class="material-icons">help_outline</i></a>
101
+			<h2><?php echo __('Select from below the files/folders you want to exclude from your Backup Archive', 'xcloner-backup-and-restore')?>:
102
+				<a class="btn-floating tooltipped btn-small" data-position="bottom" data-delay="50" data-html="true" data-tooltip="<?php echo __('You can navigate below through all your site structure(Backup Start Location) to exclude any file/folder you need by clicking the checkbox near it. <br />If the checkobx is disabled, then it matches a Regex Exclude File option and it can\'t be unchecked', 'xcloner-backup-and-restore'); ?>" data-tooltip-id=""><i class="material-icons">help_outline</i></a>
103 103
 			</h2>
104 104
 			
105 105
 			<!-- Files System Container -->
@@ -127,7 +127,7 @@  discard block
 block discarded – undo
127 127
 					<ul class="backup-status collapsible" data-collapsible="accordion">
128 128
 					    <li class="file-system">
129 129
 						      <div class="collapsible-header">
130
-									<i class="material-icons">folder</i><?php echo __('Scanning The File System...','xcloner-backup-and-restore')?>
130
+									<i class="material-icons">folder</i><?php echo __('Scanning The File System...', 'xcloner-backup-and-restore')?>
131 131
 									
132 132
 									<p class="right"><?php echo sprintf(__('Found %s files (%s)', 'xcloner-backup-and-restore'), '<span class="file-counter">0</span>', '<span  class="file-size-total">0</span>MB')?></p>
133 133
 
@@ -141,12 +141,12 @@  discard block
 block discarded – undo
141 141
 								</div>	
142 142
 						      <div class="collapsible-body status-body"></div>
143 143
 					    </li>
144
-					    <?php if($xcloner_settings->get_enable_mysql_backup()):?>
144
+					    <?php if ($xcloner_settings->get_enable_mysql_backup()):?>
145 145
 					    <li class="database-backup">
146 146
 						      <div class="collapsible-header">
147
-									<i class="material-icons">storage</i><?php echo __('Generating the Mysql Backup...','xcloner-backup-and-restore')?>
147
+									<i class="material-icons">storage</i><?php echo __('Generating the Mysql Backup...', 'xcloner-backup-and-restore')?>
148 148
 									
149
-									<p class="right"><?php echo sprintf(__('Found %s tables in %s databases (%s)', 'xcloner-backup-and-restore'), '<span class="table-counter">0</span>', '<span class="database-counter">0</span>', '<span data-processed="0" class="total-records">0</span> records','xcloner-backup-and-restore')?></p>
149
+									<p class="right"><?php echo sprintf(__('Found %s tables in %s databases (%s)', 'xcloner-backup-and-restore'), '<span class="table-counter">0</span>', '<span class="database-counter">0</span>', '<span data-processed="0" class="total-records">0</span> records', 'xcloner-backup-and-restore')?></p>
150 150
 									
151 151
 									<div>
152 152
 										<p class="right"><span class="last-logged-table"></span></p>
@@ -170,9 +170,9 @@  discard block
 block discarded – undo
170 170
 					    <?php endif?>
171 171
 					    <li class="files-backup">
172 172
 						      <div class="collapsible-header">
173
-									<i class="material-icons">archive</i><?php echo __('Adding Files to Archive...','xcloner-backup-and-restore')?>
173
+									<i class="material-icons">archive</i><?php echo __('Adding Files to Archive...', 'xcloner-backup-and-restore')?>
174 174
 									
175
-									<p class="right"><?php echo sprintf(__('Adding %s files (%s)','xcloner-backup-and-restore'), '<span class="file-counter">0</span>', '<span  data-processed="0" class="file-size-total">0</span>MB')?></p>
175
+									<p class="right"><?php echo sprintf(__('Adding %s files (%s)', 'xcloner-backup-and-restore'), '<span class="file-counter">0</span>', '<span  data-processed="0" class="file-size-total">0</span>MB')?></p>
176 176
 
177 177
 									<div>
178 178
 										<p class="right"><span class="last-logged-file"></span></p>
@@ -185,7 +185,7 @@  discard block
 block discarded – undo
185 185
 						      <div class="collapsible-body status-body">
186 186
 									<div class="row">
187 187
 										<div class="col l3 s12">
188
-											<h2><?php echo __("Backup Parts",'xcloner-backup-and-restore')?>: </h2>
188
+											<h2><?php echo __("Backup Parts", 'xcloner-backup-and-restore')?>: </h2>
189 189
 										</div>	
190 190
 										<div class="col l9 s12">
191 191
 											<ul class="backup-name"></ul>
@@ -195,14 +195,14 @@  discard block
 block discarded – undo
195 195
 					    </li>
196 196
 					    <li class="backup-done">
197 197
 						      <div class="collapsible-header">
198
-									<i class="material-icons">done</i><?php echo __('Backup Done','xcloner-backup-and-restore')?>
198
+									<i class="material-icons">done</i><?php echo __('Backup Done', 'xcloner-backup-and-restore')?>
199 199
 									
200 200
 									<p class="right">
201
-										 <?php if(sizeof($available_storages)):?>
202
-											<a href="#" class="cloud-upload" title="<?php echo __("Send Backup To Remote Storage",'xcloner-backup-and-restore')?>"><i class="material-icons">cloud_upload</i></a>
201
+										 <?php if (sizeof($available_storages)):?>
202
+											<a href="#" class="cloud-upload" title="<?php echo __("Send Backup To Remote Storage", 'xcloner-backup-and-restore')?>"><i class="material-icons">cloud_upload</i></a>
203 203
 										 <?php endif?>
204
-										 <a href="#" class="download" title="<?php echo __("Download Backup",'xcloner-backup-and-restore')?>"><i class="material-icons">file_download</i></a>
205
-										 <a href="#" class="list-backup-content" title="<?php echo __("List Backup Content",'xcloner-backup-and-restore')?>"><i class="material-icons">folder_open</i></a>
204
+										 <a href="#" class="download" title="<?php echo __("Download Backup", 'xcloner-backup-and-restore')?>"><i class="material-icons">file_download</i></a>
205
+										 <a href="#" class="list-backup-content" title="<?php echo __("List Backup Content", 'xcloner-backup-and-restore')?>"><i class="material-icons">folder_open</i></a>
206 206
 									</p>
207 207
 									
208 208
 									<div class="progress">
@@ -212,8 +212,8 @@  discard block
 block discarded – undo
212 212
 								</div>	
213 213
 						      <div class="collapsible-body center-align">
214 214
 									<div class="row">
215
-										<h5><?php echo __("Thank you for using XCloner.",'xcloner-backup-and-restore')?></h5>
216
-										<h6><?php echo sprintf(__("We would love to hear about your experience in the %s.", 'xcloner-backup-and-restore'),'<a href="https://wordpress.org/support/plugin/xcloner-backup-and-restore/reviews/" target="_blank">Wordpress XCloner Reviews Section</a>') ?></h6>
215
+										<h5><?php echo __("Thank you for using XCloner.", 'xcloner-backup-and-restore')?></h5>
216
+										<h6><?php echo sprintf(__("We would love to hear about your experience in the %s.", 'xcloner-backup-and-restore'), '<a href="https://wordpress.org/support/plugin/xcloner-backup-and-restore/reviews/" target="_blank">Wordpress XCloner Reviews Section</a>') ?></h6>
217 217
 										<a class="twitter-follow-button" href="https://twitter.com/thinkovi" data-show-count="false">Follow @thinkovi</a>
218 218
 										<script src="//platform.twitter.com/widgets.js" async="" charset="utf-8"></script>
219 219
 										
@@ -234,7 +234,7 @@  discard block
 block discarded – undo
234 234
 			<div class="row">
235 235
 				<div id="schedule_backup_success" class="col s12 l6 updated settings-error notice is-dismissible"> 
236 236
 					<p><strong><?php echo __('Schedule Saved', 'xcloner-backup-and-restore')?></strong></p>
237
-					<button type="button" class="notice-dismiss"><span class="screen-reader-text"><?php echo __('(Dismiss this notice.','xcloner-backup-and-restore')?></span></button>
237
+					<button type="button" class="notice-dismiss"><span class="screen-reader-text"><?php echo __('(Dismiss this notice.', 'xcloner-backup-and-restore')?></span></button>
238 238
 				</div>
239 239
 			</div>
240 240
 			
@@ -248,11 +248,11 @@  discard block
 block discarded – undo
248 248
 			<div class="row">
249 249
 				 <div class="input-field inline col s12 m8 l4">
250 250
 					  <input type="datetime-local" id="datepicker" class="datepicker" name="schedule_start_date" >
251
-					  <label for="datepicker"><?php echo __('Schedule Backup To Start On:','xcloner-backup-and-restore')?></label>
251
+					  <label for="datepicker"><?php echo __('Schedule Backup To Start On:', 'xcloner-backup-and-restore')?></label>
252 252
 				</div>
253 253
 				 <div class="input-field inline col s12 m4 l3">
254 254
 					  <input id="timepicker_ampm_dark" class="timepicker" type="time" name="schedule_start_time">
255
-					  <label for="timepicker_ampm_dark"><?php echo __('At:','xcloner-backup-and-restore')?></label>
255
+					  <label for="timepicker_ampm_dark"><?php echo __('At:', 'xcloner-backup-and-restore')?></label>
256 256
 				</div>
257 257
 			</div>
258 258
 			
@@ -260,17 +260,17 @@  discard block
 block discarded – undo
260 260
 			<div class="row">
261 261
 				<div class="input-field inline col s10 m11 l7">
262 262
 					<select id="backup_type" class="" name="backup_type">
263
-						<option value=""><?php echo __("Full Backup","xcloner-backup-and-restore");?></option>
264
-						<option value="diff"><?php echo __("Differential Backups","xcloner-backup-and-restore");?></option>
265
-						<option value="full_diff"><?php echo __("Full Backup + Differential Backups","xcloner-backup-and-restore");?></option>
263
+						<option value=""><?php echo __("Full Backup", "xcloner-backup-and-restore"); ?></option>
264
+						<option value="diff"><?php echo __("Differential Backups", "xcloner-backup-and-restore"); ?></option>
265
+						<option value="full_diff"><?php echo __("Full Backup + Differential Backups", "xcloner-backup-and-restore"); ?></option>
266 266
 					</select>
267
-					<label for="backup_type"><?php echo __('Scheduled Backup Type','xcloner-backup-and-restore')?></label>
267
+					<label for="backup_type"><?php echo __('Scheduled Backup Type', 'xcloner-backup-and-restore')?></label>
268 268
 				</div>
269 269
 				<div class="col s2 m1">	
270 270
 					<a class="btn-floating tooltipped btn-small" data-html="true" data-position="center" data-delay="50" data-tooltip="<ul style='max-width:760px; text-align:left;'>
271
-						<li><?php echo __("Full Backup = it will generate a full backup of all included files each time schedule runs","xcloner-backup-and-restore");?></li>
272
-						<li><?php echo __("Differentials Backups = backups will include only changed files since the schedule started to run","xcloner-backup-and-restore");?></li>
273
-						<li><?php echo __("Full Backup +  Differential Backups = the first time schedule runs, it will create a full backup and all next scheduled backups will include only files created/modified since that last full backup; a full backup is recreated when the number of changed files is bigger than the 'Differetial Backups Max Days' XCloner option.","xcloner-backup-and-restore");?></li>
271
+						<li><?php echo __("Full Backup = it will generate a full backup of all included files each time schedule runs", "xcloner-backup-and-restore"); ?></li>
272
+						<li><?php echo __("Differentials Backups = backups will include only changed files since the schedule started to run", "xcloner-backup-and-restore"); ?></li>
273
+						<li><?php echo __("Full Backup +  Differential Backups = the first time schedule runs, it will create a full backup and all next scheduled backups will include only files created/modified since that last full backup; a full backup is recreated when the number of changed files is bigger than the 'Differetial Backups Max Days' XCloner option.", "xcloner-backup-and-restore"); ?></li>
274 274
 					</ul>"><i class="material-icons">help_outline</i></a>
275 275
 				</div>
276 276
 			</div>	
@@ -282,7 +282,7 @@  discard block
 block discarded – undo
282 282
 						<?php
283 283
 						$schedules = $xcloner_scheduler->get_available_intervals();
284 284
 						
285
-						foreach($schedules as $key=>$schedule)
285
+						foreach ($schedules as $key=>$schedule)
286 286
 						{
287 287
 						?>
288 288
 							<option value="<?php echo $key?>"><?php echo $schedule['display']?></option>
@@ -294,12 +294,12 @@  discard block
 block discarded – undo
294 294
 				</div>
295 295
 			</div>	
296 296
 			
297
-			<?php if(sizeof($available_storages)):?>
297
+			<?php if (sizeof($available_storages)):?>
298 298
 			<div class="row">
299 299
 				<div class="input-field col s12 m12 l7">
300 300
 					<select name="schedule_storage" id="schedule_storage" class="validate">
301 301
 						<option value="" selected><?php echo __('none', 'xcloner-backup-and-restore') ?></option>
302
-						<?php foreach($available_storages as $storage=>$text):?>
302
+						<?php foreach ($available_storages as $storage=>$text):?>
303 303
 							<option value="<?php echo $storage?>"><?php echo $text?></option>
304 304
 						<?php endforeach?>
305 305
 						</select>
@@ -309,7 +309,7 @@  discard block
 block discarded – undo
309 309
 			<?php endif?>
310 310
 			<div class="row">
311 311
 				<div class="col s12 l7">
312
-					<button class="right btn waves-effect waves-light submit_schedule" type="submit" name="action"><?php echo __("Submit" ,'xcloner-backup-and-restore')?>
312
+					<button class="right btn waves-effect waves-light submit_schedule" type="submit" name="action"><?php echo __("Submit", 'xcloner-backup-and-restore')?>
313 313
 						<i class="material-icons right">send</i>
314 314
 					</button>
315 315
 				</div>
@@ -328,14 +328,14 @@  discard block
 block discarded – undo
328 328
 		<textarea  class="body" rows="5"></textarea>
329 329
 	</div>
330 330
 	<div class="modal-footer">
331
-		<a class=" modal-action modal-close waves-effect waves-green btn-flat  red darken-2"><?php echo __('Close','xcloner-backup-and-restore')?></a>
331
+		<a class=" modal-action modal-close waves-effect waves-green btn-flat  red darken-2"><?php echo __('Close', 'xcloner-backup-and-restore')?></a>
332 332
 	</div>
333 333
 </div>
334 334
 
335 335
 <!-- List Backup Content Modal-->
336 336
 <div id="backup_cotent_modal" class="modal">
337 337
 	<div class="modal-content">
338
-		<h4><?php echo sprintf(__("Listing Backup Content ",'xcloner-backup-and-restore'), "")?></h4>
338
+		<h4><?php echo sprintf(__("Listing Backup Content ", 'xcloner-backup-and-restore'), "")?></h4>
339 339
 		<h5 class="backup-name"></h5>
340 340
 		
341 341
 		<div class="progress">
@@ -350,9 +350,9 @@  discard block
 block discarded – undo
350 350
 	<form method="POST" class="remote-storage-form">
351 351
 	<input type="hidden" name="file" class="backup_name">	  
352 352
 	<div class="modal-content">
353
-	  <h4><?php echo __("Remote Storage Transfer",'xcloner-backup-and-restore')?></h4>
353
+	  <h4><?php echo __("Remote Storage Transfer", 'xcloner-backup-and-restore')?></h4>
354 354
 	  <p>
355
-	  <?php if(sizeof($available_storages)):?>
355
+	  <?php if (sizeof($available_storages)):?>
356 356
 			<div class="row">
357 357
 				<div class="col s12 label">
358 358
 					<label><?php echo __(sprintf('Send %s to remote storage', "<span class='backup_name'></span>"), 'xcloner-backup-and-restore') ?></label>
@@ -360,7 +360,7 @@  discard block
 block discarded – undo
360 360
 				<div class="input-field col s8 m10">
361 361
 					<select name="transfer_storage" id="transfer_storage" class="validate" required >
362 362
 						<option value="" selected><?php echo __('please select...', 'xcloner-backup-and-restore') ?></option>
363
-						<?php foreach($available_storages as $storage=>$text):?>
363
+						<?php foreach ($available_storages as $storage=>$text):?>
364 364
 							<option value="<?php echo $storage?>"><?php echo $text?></option>
365 365
 						<?php endforeach?>
366 366
 						</select>
@@ -371,7 +371,7 @@  discard block
 block discarded – undo
371 371
 				</div>
372 372
 			</div>
373 373
 			<div class="row status">
374
-				<?php echo __("Uploading backup to the selected remote storage...",'xcloner-backup-and-restore')?> <span class="status-text"></span>
374
+				<?php echo __("Uploading backup to the selected remote storage...", 'xcloner-backup-and-restore')?> <span class="status-text"></span>
375 375
 				<div class="progress">
376 376
 					<div class="indeterminate"></div>
377 377
 				</div>
@@ -454,7 +454,7 @@  discard block
 block discarded – undo
454 454
 		}
455 455
 	});
456 456
 	
457
-	<?php if($xcloner_settings->get_enable_mysql_backup()):?>
457
+	<?php if ($xcloner_settings->get_enable_mysql_backup()):?>
458 458
 	jQuery('#jstree_database_container').jstree({
459 459
 			'core' : {
460 460
 				'check_callback' : true,
Please login to merge, or discard this patch.