web/wp-content/plugins/duplicator/inc/view.system.php
changeset 195 c7c0fbc09788
child 204 09a1c134465b
equal deleted inserted replaced
194:32102edaa81b 195:c7c0fbc09788
       
     1 <!-- ==========================================
       
     2 DIALOG: PACKAGE CONFIRMATION-->
       
     3 <div id="dup-dlg-package-confirm" title="<?php _e('Package Creation', 'wpduplicator'); ?>">
       
     4 	<span class="ui-icon ui-icon-disk" style="float:left; margin:0 7px 20px 0; line-height:18px;"></span>
       
     5 	<b><?php _e("Create a new Package Set?", 'wpduplicator');	?></b>
       
     6 	
       
     7 	<p style="padding:10px 20px 10px 20px; line-height:26px; text-align:left; border:1px solid #efefef; border-radius:5px">
       
     8 		<b><?php _e('Name', 'wpduplicator') ?>:</b> <span id="dup-dlg-package-confirm-msg"></span><br/>
       
     9 
       
    10 		<b><?php _e('Pre-Zip Overview', 'wpduplicator'); ?>:</b>
       
    11 		<span id='dup-dlg-package-confirm-scannow-data'>
       
    12 			<a href="javascript:void(0)" onclick="Duplicator.getSystemDirectory()"><?php _e("Perform Scan", 'wpduplicator') ?></a> 
       
    13 		</span><br/>
       
    14 		
       
    15 		<div style='font-size:11px; line-height:15px'>
       
    16 			<i>
       
    17 				<?php printf("%s <a href='javascript:void(0)'  onclick='Duplicator.optionsOpen()'>%s</a>. %s",
       
    18 						__('Note: A scan will provide an estimate on the size of your file system.  The scan will exclude items in the', 'wpduplicator'),
       
    19 						__('directory filter list', 'wpduplicator'),
       
    20 						__('Files that are not readable by the plugin will not be included in the overview.  Directories that are empty will not be included in the final package. ', 'wpduplicator'));
       
    21 				?>
       
    22 			</i>
       
    23 		</div>
       
    24 	</p>
       
    25 </div>
       
    26 
       
    27 <!-- ==========================================
       
    28 DIALOG: SYSTEM ERROR -->
       
    29 <div id="dup-dlg-system-error" title="<?php _e('System Constraint', 'wpduplicator'); ?>">
       
    30 	<p>
       
    31 		<span class="ui-icon ui-icon-alert" style="float:left; margin:0 7px 20px 0; line-height:18px;"></span>
       
    32 		<?php _e("Please try again! An issue has occurred.", 'wpduplicator');	?>
       
    33 	</p>
       
    34 	
       
    35 	<div style="padding: 0px 20px 20px 20px;">
       
    36 		<b><?php _e("Recommendations", 'wpduplicator') ?></b><br/>
       
    37 		<div id="dup-system-err-msg1">
       
    38 			<li>
       
    39 				<?php printf("<a href='javascript:void(0)' onclick='Duplicator.getSystemCheck()'>%s</a> %s &amp; 
       
    40 							  <a href='javascript:void(0)' onclick='window.location.reload();'>%s</a> %s",
       
    41 						__("Validate", 'wpduplicator'),
       
    42 					    __("your system", 'wpduplicator'),
       
    43 						__("refresh", 'wpduplicator'),
       
    44 						__("the dashboard.", 'wpduplicator')); ?>
       
    45 			</li>
       
    46 			<li>
       
    47 				<?php printf("<a href='javascript:void(0)' onclick='Duplicator.openLog()'>%s</a> %s.",
       
    48 						__("Monitor", 'wpduplicator'),
       
    49 						__("your log file a few more minutes as processing may continue on some systems", 'wpduplicator')); 
       
    50 				?>
       
    51 			</li>
       
    52 			<li><?php _e('Contact your server admin to have the page timeout increased (see duration below)', 'wpduplicator') ?>.</li>
       
    53 			<li><?php _e('Consider adding a directory filter in the options dialog if the process continues to timeout', 'wpduplicator') ?>.</li>
       
    54 			<li><?php _e('Check your disk space.  For hosted sites review your providers help.', 'wpduplicator') ?></li>
       
    55 			<li>
       
    56 				<?php printf("%s <a href='%s' target='_blank'>%s</a> %s", 
       
    57 						__("Consider using an" , 'wpduplicator'),
       
    58 						__(DUPLICATOR_CERTIFIED, 'wpduplicator'),
       
    59 						__("approved" , 'wpduplicator'),
       
    60 						__("hosting provider.", 'wpduplicator')	); ?>
       
    61 			</li>
       
    62 		</div><br/>
       
    63 	
       
    64 		<b><?php _e("Server Response", 'wpduplicator') ?></b><br/>
       
    65 		<div id="dup-system-err-msg2"></div>
       
    66 		<i style='font-size:11px'>
       
    67 			<?php 
       
    68 				printf('%s %s', 
       
    69 					__("See online help for more details at", 'wpduplicator'), 
       
    70 					"<a href='" . DUPLICATOR_HELPLINK . "' target='_blank'>support.lifeinthegrid.com</a>" );
       
    71 			?>
       
    72 		</i>
       
    73 	</div>
       
    74 </div>
       
    75 
       
    76 
       
    77 <!-- ==========================================
       
    78 DIALOG: SYSTEM CHECK -->
       
    79 <div id="dup-dlg-system-check" title="<?php _e('System Checks', 'wpduplicator'); ?>">
       
    80 	
       
    81 	<span class="ui-icon ui-icon-alert" style="float:left; margin:0 7px 20px 0; line-height:18px;"></span>
       
    82 	<?php _e("Please validate your system configuration.", 'wpduplicator'); ?>
       
    83 	<?php printf("<i>%s</i>", __("Click link for details", 'wpduplicator')); ?>
       
    84 	
       
    85 	<div style="padding: 0px 20px 20px 20px;">
       
    86 		<div id="dup-sys-check-data">
       
    87 		
       
    88 			<!-- =========================================
       
    89 			SYSTEM REQUIRMENTS -->
       
    90 			<ul id="dup-sys-check-data-reqs">
       
    91 				<li>
       
    92 					<b><?php _e("SYSTEM REQUIRMENTS", 'wpduplicator') ?></b><hr size="1"/>
       
    93 					<div class='dup-sys-check-title'><a> SYS-100: <?php _e('File Permissions', 'wpduplicator');?></a></div> <span id='SYS-100'></span>
       
    94 					<div class='dup-sys-check-data-details'>
       
    95 						<?php 
       
    96 							echo "<b>";  _e("Required permissions", 'wpduplicator'); echo ":</b>";
       
    97 							echo "<br/>";
       
    98 
       
    99 							$test = is_readable(DUPLICATOR_WPROOTPATH) ? 'Pass' : 'Fail';
       
   100 							printf("<b>%s</b> [%s] <br/>", $test, DUPLICATOR_WPROOTPATH);
       
   101 							
       
   102 							$test = is_writeable(DUPLICATOR_SSDIR_PATH) ? 'Pass' : 'Fail';
       
   103 							printf("<b>%s</b> [%s] <br/>", $test, DUPLICATOR_SSDIR_PATH);
       
   104 							
       
   105 							$test = is_writeable(DUPLICATOR_PLUGIN_PATH . 'files/') ? 'Pass' : 'Fail';
       
   106 							printf("<b>%s</b> [%s] <br/>", $test, DUPLICATOR_PLUGIN_PATH . 'files/');
       
   107 							
       
   108 							$test = is_writeable(DUPLICATOR_PLUGIN_PATH . 'files/installer.rescue.php') ? 'Pass' : 'Fail';
       
   109 							printf("<b>%s</b> [%s] <br/>", $test, DUPLICATOR_PLUGIN_PATH . 'files/installer.rescue.php');
       
   110 							
       
   111 							echo "<br/>";	
       
   112 							
       
   113 							_e("The above paths should have permissions of 755 for directories and 644 for files. On some hosts the permission set requires 777.  Setting items to 777 is a security issue and should only be set temporarily.  Please avoid any hosting company that requires this kind of setup.  See the 'Duplicator Approved' link at the bottom of this dialog for a list of approved hosting providers.", 'wpduplicator');
       
   114 							echo "<br/><br/>";
       
   115 							
       
   116 							_e("Also be sure to check the Owner/Group settings and validate they are correct and match other successful directories/files that are accessible.  For more details contact your host or visit their help pages for more information on how they implement permissions and group settings.", 'wpduplicator');		
       
   117 							
       
   118 							echo "<br/>";
       
   119 						?>
       
   120 					</div>
       
   121 				</li>
       
   122 				<li>
       
   123 					<div class='dup-sys-check-title'><a>SYS-101: <?php _e('Reserved Files', 'wpduplicator');?></a></div> <span id='SYS-101'></span>
       
   124 					<div class='dup-sys-check-data-details'>
       
   125 						<?php 
       
   126 							_e('If this check fails then a reserved file was found in the WordPress root directory. The following are reserved file names installer.php, installer-data.sql and installer-log.txt.  In order to archive your data correctly please remove any of these files from your WordPress root directory. Then try creating your package again.', 'wpduplicator');
       
   127 						?>
       
   128 					</div>
       
   129 				</li>
       
   130 				<li>
       
   131 					<div class='dup-sys-check-title'><a>SYS-102: <?php _e('Zip Archive Enabled', 'wpduplicator');?></a></div> <span id='SYS-102'></span>
       
   132 					<div class='dup-sys-check-data-details'>
       
   133 						<?php 
       
   134 							_e("The ZipArchive extension for PHP is required for compression.  Please contact your hosting provider if you're on a hosted server.  For additional information see our online documentation.", 'wpduplicator');
       
   135 						?>
       
   136 					</div>
       
   137 				</li>
       
   138 				<li>
       
   139 					<div class='dup-sys-check-title'><a>SYS-103: <?php _e('Safe Mode Off', 'wpduplicator');?></a></div> <span id='SYS-103'></span>
       
   140 					<div class='dup-sys-check-data-details'>
       
   141 						<?php 
       
   142 							_e("Safe Mode needs to be disabled in order for the Duplicator to operate correctly.  Please set safe_mode = Off in you php.ini file.  If you're on a hosted server and don't have access to the php.ini file then you will need to request this setting be updated. Safe Mode is no longer in future versions of PHP.  If your host will not work with you to resolve the issue then consider a higher reputable hosting provider.", 'wpduplicator');
       
   143 						?>
       
   144 					</div>
       
   145 				</li>	
       
   146 				<li>
       
   147 					<div class='dup-sys-check-title'><a>SYS-104: <?php _e('MySQLi Support', 'wpduplicator');?></a></div> <span id='SYS-104'></span>
       
   148 					<div class='dup-sys-check-data-details'>
       
   149 						<?php 
       
   150 							_e("In order to complete an install the mysqli extension for PHP is required. If you are on a hosted server please contact your host and request that mysqli extension be enabled. For more information visit: http://php.net/manual/en/mysqli.installation.php", 'wpduplicator');
       
   151 						?>
       
   152 					</div>
       
   153 				</li>	
       
   154 			</ul>
       
   155 	
       
   156 		
       
   157 			<!-- =========================================
       
   158 			SYSTEM CHECKS -->
       
   159 			<b><?php _e("SYSTEM CHECKS", 'wpduplicator') ?></b><hr style='margin-top:-2px' size="1"/>
       
   160 			
       
   161 			<!-- PHP SERVER -->
       
   162 			<div class='dup-sys-check-title'><b><?php _e("PHP Version", 'wpduplicator');  echo ":</b> " . phpversion(); ?></div> 
       
   163 			<?php if (phpversion() >= 5.3): ?>
       
   164 				<div class='dup-sys-pass'><?php _e('Good', 'wpduplicator'); ?></div>
       
   165 			<?php elseif (phpversion() >= 5.2): ?>
       
   166 				<div class='dup-sys-ok'><?php _e('OK', 'wpduplicator'); ?></div>
       
   167 				<i style="font-size:11px; font-weight:normal"> &nbsp; (<?php _e("PHP 5.2.17+ is required", 'wpduplicator') ?>)</i>
       
   168 			<?php else: ?> 
       
   169 				<div class='dup-sys-fail'><?php _e('Fail', 'wpduplicator'); ?></div>
       
   170 			<?php endif; ?>	<br />
       
   171 			
       
   172 			
       
   173 			<!-- WEB SERVER -->
       
   174 			<?php if (stristr($_SERVER['SERVER_SOFTWARE'], 'apache') !== false): ?>
       
   175 				<b><div class='dup-sys-check-title'><?php _e("Web Server", 'wpduplicator') ?>:</b> Apache</div> 
       
   176 				<div class='dup-sys-pass'><?php _e('Good', 'wpduplicator'); ?></div>
       
   177 			<?php elseif (stristr($_SERVER['SERVER_SOFTWARE'], 'LiteSpeed') !== false): ?> 
       
   178 				<b><div class='dup-sys-check-title'><?php _e("Web Server", 'wpduplicator') ?>:</b> LiteSpeed</div> 
       
   179 				<div class='dup-sys-ok'><?php _e('OK', 'wpduplicator'); ?></div>
       
   180 			<?php elseif (stristr($_SERVER['SERVER_SOFTWARE'], 'nginx') !== false): ?> 
       
   181 				<b><div class='dup-sys-check-title'><?php _e("Web Server", 'wpduplicator') ?>:</b> Nginx</div> 
       
   182 				<div class='dup-sys-ok'><?php _e('OK', 'wpduplicator'); ?></div>
       
   183 			<?php elseif (stristr($_SERVER['SERVER_SOFTWARE'], 'lighttpd') !== false): ?> 
       
   184 				<b><div class='dup-sys-check-title'><?php _e("Web Server", 'wpduplicator') ?>:</b> Lighthttpd</div> 
       
   185 				<div class='dup-sys-ok'><?php _e('OK', 'wpduplicator'); ?></div>
       
   186 			<?php elseif (stristr($_SERVER['SERVER_SOFTWARE'], 'iis') !== false): ?> 
       
   187 				<b><div class='dup-sys-check-title'><?php _e("Web Server", 'wpduplicator') ?>:</b> Microsoft IIS</div> 
       
   188 				<div class='dup-sys-ok'><?php _e('OK', 'wpduplicator'); ?></div>
       
   189 			<?php else: ?>
       
   190 				<b><div class='dup-sys-check-title'><?php _e("Web Server", 'wpduplicator') ?>:</b> <?php _e("Not detected", 'wpduplicator') ?> </div> 
       
   191 				<div class='dup-sys-fail'><?php _e('Fail', 'wpduplicator'); ?></div>
       
   192 			<?php endif; ?>	<br />
       
   193 			
       
   194 
       
   195 			<!-- OPEN BASE DIR -->
       
   196 			<?php 
       
   197 			$open_basedir_set = ini_get("open_basedir");
       
   198 			if (empty($open_basedir_set)): ?>
       
   199 				<b><div class='dup-sys-check-title'><?php _e("Open Base Dir", 'wpduplicator') ?>:</b> <?php _e('Off', 'wpduplicator'); ?></div> 
       
   200 				<div class='dup-sys-pass'><?php _e('Good', 'wpduplicator'); ?></div>
       
   201 			<?php else: ?>
       
   202 				<b><div class='dup-sys-check-title'><?php _e("Open Base Dir", 'wpduplicator') ?>:</b> <?php _e('On', 'wpduplicator'); ?></div> 
       
   203 				<div class='dup-sys-fail'><?php _e('Fail', 'wpduplicator'); ?></div>
       
   204 			<?php endif; ?><br />
       
   205 			
       
   206 			
       
   207 			<hr class='dup-dots' />
       
   208 			<!-- SAPI -->
       
   209 			<b><?php _e('PHP SAPI', 'wpduplicator'); ?>:</b>  <?php echo php_sapi_name(); ?><br/>
       
   210 			
       
   211 			<!-- PRE-ZIP OVERVIEW -->
       
   212 			<b><?php _e('Pre-Zip Overview', 'wpduplicator'); ?>:</b> 
       
   213 			<span id='dup-sys-scannow-data'>
       
   214 				<a href="javascript:void(0)" onclick="Duplicator.getSystemDirectory()"><?php _e("Scan Now", 'wpduplicator') ?></a> 
       
   215 			</span><br/>
       
   216 			
       
   217 			
       
   218 			<b>W3 Total Cache:</b>
       
   219 			<?php 
       
   220 				$w3tc_path = duplicator_safe_path(WP_CONTENT_DIR) .  '/w3tc';
       
   221 				if (file_exists($w3tc_path) && ! strstr($GLOBALS['duplicator_opts']['dir_bypass'], $w3tc_path)):
       
   222 			?>
       
   223 				<div class="dup-sys-fail"><?php _e("Cache Directory Found", 'wpduplicator') ?>.</div> 
       
   224 				<a href="javascript:void(0)" onclick="Duplicator.optionsAppendByPassList('<?php echo addslashes($w3tc_path); ?>')"><?php _e("Add to exclusion path now", 'wpduplicator') ?></a>
       
   225 			<?php elseif (strstr($GLOBALS['duplicator_opts']['dir_bypass'], $w3tc_path)): ?>
       
   226 				<div class="dup-sys-pass"><?php _e("Directory excluded", 'wpduplicator') ?></div><br/>
       
   227 				<i style='font-weight:normal;font-size:11px'><?php _e("Path", 'wpduplicator') ?>: <?php echo addslashes($w3tc_path); ?></i>
       
   228 			<?php else: ?>
       
   229 				<div class="dup-sys-pass"><?php _e("Cache Directory Not Found", 'wpduplicator') ?></div>
       
   230 			<?php endif; ?><br /><br />
       
   231 
       
   232 			
       
   233 			<!-- =========================================
       
   234 			CERTIFIED HOSTS -->
       
   235 			<b><?php _e("ONLINE RESOURCES", 'wpduplicator') ?></b><hr size="1"/>
       
   236 			<div style='font-weight:normal'>
       
   237 				<span class="ui-icon ui-icon-help" style="float:left; margin:0 2px 0px 0;"></span>
       
   238 				<?php 
       
   239 					printf('%s <i>%s</i>', 
       
   240 						__("For additional online help please visit", 'wpduplicator'), 
       
   241 						"<a href='" . DUPLICATOR_HELPLINK . "' target='_blank'>support.lifeinthegrid.com</a>" );
       
   242 				?><br/>	
       
   243 				<span class="ui-icon ui-icon-lightbulb" style="float:left; margin:0 2px 0px 0;"></span>
       
   244 				<?php 
       
   245 					printf("%s <i><a href='%s' target='_blank'>%s</a></i>?", 
       
   246 						__("Need a hosting provider that is", 'wpduplicator'), 
       
   247 						DUPLICATOR_CERTIFIED,
       
   248 						__("Duplicator Approved", 'wpduplicator') );
       
   249 				?><br/>			
       
   250 			</div>
       
   251 			
       
   252 		</div>
       
   253 	</div>
       
   254 </div>
       
   255 
       
   256 
       
   257 <!-- ==========================================
       
   258 DIALOG: QUICK PATH -->
       
   259 <div id="dup-dlg-quick-path" title="<?php _e('Download Links', 'wpduplicator'); ?>">
       
   260 	<p>
       
   261 		<span class="ui-icon ui-icon-locked" style="float:left; margin:0 7px 20px 0; line-height:18px;"></span>
       
   262 		<?php _e("The following links contain sensitive data.  Please share with caution!", 'wpduplicator');	?>
       
   263 	</p>
       
   264 	
       
   265 	<div style="padding: 0px 20px 20px 20px;">
       
   266 		<a href="javascript:void(0)" style="display:inline-block; text-align:right" onclick="Duplicator.selectQuickPath()">[Select All]</a> <br/>
       
   267 		<textarea id="dup-dlg-quick-path-data" style='border:1px solid silver; border-radius:5px; width:96%; height:205px; font-size:11px'></textarea><br/>
       
   268 		<i style='font-size:11px'><?php _e("The database SQL script is a quick link to your database backup script.  An exact copy is also stored in the package.", 'wpduplicator'); ?></i>
       
   269 	</div>
       
   270 </div>
       
   271 
       
   272