本文整理汇总了PHP中BackWPup_Admin::display_messages方法的典型用法代码示例。如果您正苦于以下问题:PHP BackWPup_Admin::display_messages方法的具体用法?PHP BackWPup_Admin::display_messages怎么用?PHP BackWPup_Admin::display_messages使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类BackWPup_Admin
的用法示例。
在下文中一共展示了BackWPup_Admin::display_messages方法的10个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: page
/**
*
*/
public static function page()
{
if (!empty($_GET['jobid'])) {
$jobid = (int) $_GET['jobid'];
} else {
//generate jobid if not exists
$newjobid = BackWPup_Option::get_job_ids();
sort($newjobid);
$jobid = end($newjobid) + 1;
}
$destinations = BackWPup::get_registered_destinations();
$job_types = BackWPup::get_job_types();
?>
<div class="wrap" id="backwpup-page">
<?php
echo '<h2><span id="backwpup-page-icon"> </span>' . sprintf(__('%1$s Job: %2$s', 'backwpup'), BackWPup::get_plugin_data('name'), '<span id="h2jobtitle">' . esc_html(BackWPup_Option::get($jobid, 'name')) . '</span>') . '</h2>';
//default tabs
$tabs = array('job' => array('name' => __('General', 'backwpup'), 'display' => TRUE), 'cron' => array('name' => __('Schedule', 'backwpup'), 'display' => TRUE));
//add jobtypes to tabs
$job_job_types = BackWPup_Option::get($jobid, 'type');
foreach ($job_types as $typeid => $typeclass) {
$tabid = 'jobtype-' . strtolower($typeid);
$tabs[$tabid]['name'] = $typeclass->info['name'];
$tabs[$tabid]['display'] = TRUE;
if (!in_array($typeid, $job_job_types)) {
$tabs[$tabid]['display'] = FALSE;
}
}
//add destinations to tabs
$jobdests = BackWPup_Option::get($jobid, 'destinations');
foreach ($destinations as $destid => $dest) {
$tabid = 'dest-' . strtolower($destid);
$tabs[$tabid]['name'] = sprintf(__('To: %s', 'backwpup'), $dest['info']['name']);
$tabs[$tabid]['display'] = TRUE;
if (!in_array($destid, $jobdests)) {
$tabs[$tabid]['display'] = FALSE;
}
}
//display tabs
echo '<h2 class="nav-tab-wrapper">';
foreach ($tabs as $id => $tab) {
$addclass = '';
if ($id == $_GET['tab']) {
$addclass = ' nav-tab-active';
}
$display = '';
if (!$tab['display']) {
$display = ' style="display:none;"';
}
echo '<a href="' . wp_nonce_url(network_admin_url('admin.php') . '?page=backwpupeditjob&tab=' . $id . '&jobid=' . $jobid, 'edit-job') . '" class="nav-tab' . $addclass . '" id="tab-' . $id . '" data-nexttab="' . $id . '" ' . $display . '>' . $tab['name'] . '</a>';
}
echo '</h2>';
//display messages
BackWPup_Admin::display_messages();
echo '<form name="editjob" id="editjob" method="post" action="' . admin_url('admin-post.php') . '">';
echo '<input type="hidden" id="jobid" name="jobid" value="' . $jobid . '" />';
echo '<input type="hidden" name="tab" value="' . $_GET['tab'] . '" />';
echo '<input type="hidden" name="nexttab" value="' . $_GET['tab'] . '" />';
echo '<input type="hidden" name="page" value="backwpupeditjob" />';
echo '<input type="hidden" name="action" value="backwpup" />';
echo '<input type="hidden" name="anchor" value="" />';
wp_nonce_field('backwpupeditjob_page');
wp_nonce_field('backwpup_ajax_nonce', 'backwpupajaxnonce', FALSE);
switch ($_GET['tab']) {
case 'job':
echo '<div class="table" id="info-tab-job">';
?>
<h3 class="title"><?php
_e('Job Name', 'backwpup');
?>
</h3>
<p></p>
<table class="form-table">
<tr>
<th scope="row"><label for="name"><?php
_e('Please name this job.', 'backwpup');
?>
</label></th>
<td>
<input name="name" type="text" id="name" data-empty="<?php
_e('New Job', 'backwpup');
?>
"
value="<?php
echo BackWPup_Option::get($jobid, 'name');
?>
" class="regular-text" />
</td>
</tr>
</table>
<h3 class="title"><?php
_e('Job Tasks', 'backwpup');
?>
</h3>
<p></p>
<table class="form-table">
//.........这里部分代码省略.........
示例2: page
/**
* Display the page content
*/
public static function page()
{
?>
<div class="wrap" id="backwpup-page">
<h2><span id="backwpup-page-icon"> </span><?php
echo esc_html(sprintf(__('%s Logs', 'backwpup'), BackWPup::get_plugin_data('name')));
?>
</h2>
<?php
BackWPup_Admin::display_messages();
?>
<form id="posts-filter" action="" method="get">
<input type="hidden" name="page" value="backwpuplogs" />
<?php
self::$listtable->display();
?>
<div id="ajax-response"></div>
</form>
</div>
<?php
}
示例3: page
/**
* Print the markup.
*
* @return void
*/
public static function page()
{
// get wizards
$wizards = BackWPup::get_wizards();
?>
<div class="wrap" id="backwpup-page">
<h2><span id="backwpup-page-icon"> </span><?php
echo sprintf(__('%s Dashboard', 'backwpup'), BackWPup::get_plugin_data('name'));
?>
</h2>
<?php
BackWPup_Admin::display_messages();
if (class_exists('BackWPup_Pro', FALSE)) {
?>
<div class="backwpup-welcome backwpup-max-width">
<h3><?php
_ex('Planning backups', 'Dashboard heading', 'backwpup');
?>
</h3>
<p><?php
_e('BackWPup’s job wizards make planning and scheduling your backup jobs a breeze.', 'backwpup');
echo ' ';
_e('Use your backup archives to save your entire WordPress installation including <code>/wp-content/</code>. Push them to an external storage service if you don’t want to save the backups on the same server.', 'backwpup');
?>
</p>
<h3><?php
_ex('Restoring backups', 'Dashboard heading', 'backwpup');
?>
</h3>
<p><?php
_e('With a single backup archive you are able to restore an installation. Use a tool like phpMyAdmin or a plugin like <a href="http://wordpress.org/plugins/adminer/" target="_blank">Adminer</a> to restore your database backup files.', 'backwpup');
?>
</p>
<h3><?php
_ex('Ready to set up a backup job?', 'Dashboard heading', 'backwpup');
?>
</h3>
<p><?php
printf(__('Use one of the wizards to plan a backup, or use <a href="%s">expert mode</a> for full control over all options.', 'backwpup'), network_admin_url('admin.php') . '?page=backwpupeditjob');
echo ' ';
_e('<strong>Please note: You are solely responsible for the security of your data; the authors of this plugin are not.</strong>', 'backwpup');
?>
</p>
</div>
<?php
} else {
?>
<div class="backwpup-welcome backwpup-max-width">
<h3><?php
_ex('Planning backups', 'Dashboard heading', 'backwpup');
?>
</h3>
<p><?php
_e('Use the short links in the <strong>First steps</strong> box to plan and schedule backup jobs.', 'backwpup');
echo ' ';
_e('Use your backup archives to save your entire WordPress installation including <code>/wp-content/</code>. Push them to an external storage service if you don’t want to save the backups on the same server.', 'backwpup');
?>
</p>
<h3><?php
_ex('Restoring backups', 'Dashboard heading', 'backwpup');
?>
</h3>
<p><?php
_e('With a single backup archive you are able to restore an installation. Use a tool like phpMyAdmin or a plugin like <a href="http://wordpress.org/plugins/adminer/" target="_blank">Adminer</a> to restore your database backup files.', 'backwpup');
?>
</p>
<h3><?php
_ex('Ready to set up a backup job?', 'Dashboard heading', 'backwpup');
?>
</h3>
<p><?php
printf(__('<a href="%s">Add a new backup job</a> and plan what you want to save.', 'backwpup'), network_admin_url('admin.php') . '?page=backwpupeditjob');
?>
<br /><?php
_e('<strong>Please note: You are solely responsible for the security of your data; the authors of this plugin are not.</strong>', 'backwpup');
?>
</p>
</div>
<?php
}
if (current_user_can('backwpup_jobs_edit') && current_user_can('backwpup_logs') && current_user_can('backwpup_jobs_start')) {
?>
<div id="backwpup-first-steps" class="metabox-holder postbox backwpup-floated-postbox">
<h3 class="hndle"><span><?php
_e('First Steps', 'backwpup');
?>
</span></h3>
<div class="inside">
<ul>
<?php
if (class_exists('BackWPup_Pro', FALSE)) {
?>
<li type="1"><a href="<?php
echo wp_nonce_url(network_admin_url('admin.php') . '?page=backwpupwizard&wizard_start=SYSTEMTEST', 'wizard');
?>
//.........这里部分代码省略.........
示例4: page
/**
* Page Output
*/
public static function page()
{
global $wpdb;
?>
<div class="wrap" id="backwpup-page">
<h2><span id="backwpup-page-icon"> </span><?php
echo sprintf(__('%s Settings', 'backwpup'), BackWPup::get_plugin_data('name'));
?>
</h2>
<?php
$tabs = array('general' => __('General', 'backwpup'), 'job' => __('Jobs', 'backwpup'), 'log' => __('Logs', 'backwpup'), 'net' => __('Network', 'backwpup'), 'apikey' => __('API Keys', 'backwpup'), 'information' => __('Information', 'backwpup'));
$tabs = apply_filters('backwpup_page_settings_tab', $tabs);
echo '<h2 class="nav-tab-wrapper">';
foreach ($tabs as $id => $name) {
echo '<a href="#backwpup-tab-' . $id . '" class="nav-tab">' . $name . '</a>';
}
echo '</h2>';
BackWPup_Admin::display_messages();
?>
<form id="settingsform" action="<?php
echo admin_url('admin-post.php?action=backwpup');
?>
" method="post">
<?php
wp_nonce_field('backwpupsettings_page');
?>
<input type="hidden" name="page" value="backwpupsettings" />
<input type="hidden" name="anchor" value="#backwpup-tab-general" />
<div class="table ui-tabs-hide" id="backwpup-tab-general">
<h3 class="title"><?php
_e('Display Settings', 'backwpup');
?>
</h3>
<p><?php
_e('Do you want to see BackWPup in the WordPress admin bar?', 'backwpup');
?>
</p>
<table class="form-table">
<tr>
<th scope="row"><?php
_e('Admin bar', 'backwpup');
?>
</th>
<td>
<fieldset>
<legend class="screen-reader-text"><span><?php
_e('Admin Bar', 'backwpup');
?>
</span>
</legend>
<label for="showadminbar">
<input name="showadminbar" type="checkbox" id="showadminbar"
value="1" <?php
checked(get_site_option('backwpup_cfg_showadminbar'), TRUE);
?>
/>
<?php
_e('Show BackWPup links in admin bar.', 'backwpup');
?>
</label>
</fieldset>
</td>
</tr>
<tr>
<th scope="row"><?php
_e('Folder sizes', 'backwpup');
?>
</th>
<td>
<fieldset>
<legend class="screen-reader-text"><span><?php
_e('Folder sizes', 'backwpup');
?>
</span>
</legend>
<label for="showfoldersize">
<input name="showfoldersize" type="checkbox" id="showfoldersize"
value="1" <?php
checked(get_site_option('backwpup_cfg_showfoldersize'), TRUE);
?>
/>
<?php
_e('Display folder sizes in the files tab when editing a job. (Might increase loading time of files tab.)', 'backwpup');
?>
</label>
</fieldset>
</td>
</tr>
</table>
<h3 class="title"><?php
_e('Security', 'backwpup');
?>
</h3>
<p><?php
//.........这里部分代码省略.........
示例5: page
/**
*
*/
public static function page()
{
echo '<div class="wrap" id="backwpup-page">';
echo '<h1>' . esc_html(sprintf(__('%s › Jobs', 'backwpup'), BackWPup::get_plugin_data('name'))) . ' <a href="' . wp_nonce_url(network_admin_url('admin.php') . '?page=backwpupeditjob', 'edit-job') . '" class="add-new-h2">' . esc_html__('Add new', 'backwpup') . '</a></h1>';
BackWPup_Admin::display_messages();
$job_object = BackWPup_Job::get_working_data();
if (current_user_can('backwpup_jobs_start') && is_object($job_object)) {
//read existing logfile
$logfiledata = file_get_contents($job_object->logfile);
preg_match('/<body[^>]*>/si', $logfiledata, $match);
if (!empty($match[0])) {
$startpos = strpos($logfiledata, $match[0]) + strlen($match[0]);
} else {
$startpos = 0;
}
$endpos = stripos($logfiledata, '</body>');
if (empty($endpos)) {
$endpos = strlen($logfiledata);
}
$length = strlen($logfiledata) - (strlen($logfiledata) - $endpos) - $startpos;
?>
<div id="runningjob">
<div id="runniginfos">
<h2 id="runningtitle"><?php
esc_html(sprintf(__('Job currently running: %s', 'backwpup'), $job_object->job['name']));
?>
</h2>
<span id="warningsid"><?php
esc_html_e('Warnings:', 'backwpup');
?>
<span id="warnings"><?php
echo $job_object->warnings;
?>
</span></span>
<span id="errorid"><?php
esc_html_e('Errors:', 'backwpup');
?>
<span id="errors"><?php
echo $job_object->errors;
?>
</span></span>
<div class="infobuttons"><a href="#TB_inline?height=440&width=630&inlineId=tb-showworking" id="showworkingbutton" class="thickbox button button-primary button-primary-bwp" title="<?php
esc_attr_e('Log of running job', 'backwpup');
?>
"><?php
esc_html_e('Display working log', 'backwpup');
?>
</a>
<a href="<?php
echo wp_nonce_url(network_admin_url('admin.php') . '?page=backwpupjobs&action=abort', 'abort-job');
?>
" id="abortbutton" class="backwpup-fancybox button button-bwp"><?php
esc_html_e('Abort', 'backwpup');
?>
</a>
<a href="#" id="showworkingclose" title="<?php
esc_html_e('Close working screen', 'backwpup');
?>
" class="button button-bwp" style="display:none" ><?php
esc_html_e('Close', 'backwpup');
?>
</a></div>
</div>
<input type="hidden" name="logpos" id="logpos" value="<?php
echo strlen($logfiledata);
?>
">
<div id="lasterrormsg"></div>
<div class="progressbar"><div id="progressstep" class="bwpu-progress" style="width:<?php
echo $job_object->step_percent;
?>
%;"><?php
echo esc_html($job_object->step_percent);
?>
%</div></div>
<div id="onstep"><?php
echo esc_html($job_object->steps_data[$job_object->step_working]['NAME']);
?>
</div>
<div class="progressbar"><div id="progresssteps" class="bwpu-progress" style="width:<?php
echo $job_object->substep_percent;
?>
%;"><?php
echo esc_html($job_object->substep_percent);
?>
%</div></div>
<div id="lastmsg"><?php
echo esc_html($job_object->lastmsg);
?>
</div>
<div id="tb-showworking" style="display:none;">
<div id="showworking"><?php
echo substr($logfiledata, $startpos, $length);
?>
</div>
</div>
</div>
//.........这里部分代码省略.........
示例6: page
/**
* Print the markup.
*
* @return void
*/
public static function page()
{
// get wizards
$wizards = BackWPup::get_wizards();
?>
<div class="wrap" id="backwpup-page">
<h2><span id="backwpup-page-icon"> </span><?php
echo sprintf(__('%s Dashboard', 'backwpup'), BackWPup::get_plugin_data('name'));
?>
</h2>
<?php
BackWPup_Admin::display_messages();
if (class_exists('BackWPup_Pro', FALSE)) {
?>
<div class="backwpup-welcome backwpup-max-width">
<h3><?php
_ex('Planning backups', 'Dashboard heading', 'backwpup');
?>
</h3>
<p><?php
_e('BackWPup’s job wizards make planning and scheduling your backup jobs a breeze.', 'backwpup');
echo ' ';
_e('Use your backup archives to save your entire WordPress installation including <code>/wp-content/</code>. Push them to an external storage service if you don’t want to save the backups on the same server.', 'backwpup');
?>
</p>
<h3><?php
_ex('Restoring backups', 'Dashboard heading', 'backwpup');
?>
</h3>
<p><?php
_e('With a single backup archive you are able to restore an installation. Use a tool like phpMyAdmin or a plugin like <a href="http://wordpress.org/plugins/adminer/" target="_blank">Adminer</a> to restore your database backup files.', 'backwpup');
?>
</p>
<h3><?php
_ex('Ready to set up a backup job?', 'Dashboard heading', 'backwpup');
?>
</h3>
<p><?php
printf(__('Use one of the wizards to plan a backup, or use <a href="%s">expert mode</a> for full control over all options.', 'backwpup'), network_admin_url('admin.php') . '?page=backwpupeditjob');
echo ' ';
_e('<strong>Please note: You are solely responsible for the security of your data; the authors of this plugin are not.</strong>', 'backwpup');
?>
</p>
</div>
<?php
} else {
?>
<div class="backwpup-welcome backwpup-max-width">
<h3><?php
_ex('Planning backups', 'Dashboard heading', 'backwpup');
?>
</h3>
<p><?php
_e('Use the short links in the <strong>First steps</strong> box to plan and schedule backup jobs.', 'backwpup');
echo ' ';
_e('Use your backup archives to save your entire WordPress installation including <code>/wp-content/</code>. Push them to an external storage service if you don’t want to save the backups on the same server.', 'backwpup');
?>
</p>
<h3><?php
_ex('Restoring backups', 'Dashboard heading', 'backwpup');
?>
</h3>
<p><?php
_e('With a single backup archive you are able to restore an installation. Use a tool like phpMyAdmin or a plugin like <a href="http://wordpress.org/plugins/adminer/" target="_blank">Adminer</a> to restore your database backup files.', 'backwpup');
?>
</p>
<h3><?php
_ex('Ready to set up a backup job?', 'Dashboard heading', 'backwpup');
?>
</h3>
<p><?php
printf(__('<a href="%s">Add a new backup job</a> and plan what you want to save.', 'backwpup'), network_admin_url('admin.php') . '?page=backwpupeditjob');
?>
<br /><?php
_e('<strong>Please note: You are solely responsible for the security of your data; the authors of this plugin are not.</strong>', 'backwpup');
?>
</p>
</div>
<?php
}
if (current_user_can('backwpup_jobs_edit') && current_user_can('backwpup_logs') && current_user_can('backwpup_jobs_start')) {
?>
<div id="backwpup-first-steps" class="metabox-holder postbox backwpup-floated-postbox">
<h3 class="hndle"><span><?php
_e('First Steps', 'backwpup');
?>
</span></h3>
<div class="inside">
<ul>
<?php
if (class_exists('BackWPup_Pro', FALSE)) {
?>
<li type="1"><a href="<?php
echo wp_nonce_url(network_admin_url('admin.php') . '?page=backwpupwizard&wizard_start=SYSTEMTEST', 'wizard');
?>
//.........这里部分代码省略.........
示例7: page
/**
* Print the markup.
*
* @return void
*/
public static function page()
{
?>
<div class="wrap" id="backwpup-page">
<div class="inpsyde">
<a href="http://inpsyde.com/" title="Inpsyde GmbH">Inpsyde</a>
</div>
<h2><span id="backwpup-page-icon"> </span><?php
echo sprintf(__('%s Welcome', 'backwpup'), BackWPup::get_plugin_data('name'));
?>
</h2>
<?php
BackWPup_Admin::display_messages();
?>
<div class="welcome">
<div class="welcome_inner">
<div class="top">
<?php
if (get_site_transient('backwpup_upgrade_from_version_two')) {
?>
<div id="update-notice" class="backwpup-welcome updated">
<h3><?php
_e('Heads up! You have updated from version 2.x', 'backwpup');
?>
</h3>
<p><?php
echo str_replace('\\"', '"', sprintf(__('Please <a href="%s">check your settings</a> after updating from version 2.x:', 'backwpup'), network_admin_url('admin.php') . '?page=backwpupjobs'));
?>
</a></p>
<ul><li><?php
_e('Dropbox authentication must be re-entered', 'backwpup');
?>
</li>
<li><?php
_e('SugarSync authentication must be re-entered', 'backwpup');
?>
</li>
<li><?php
_e('S3 Settings', 'backwpup');
?>
</li>
<li><?php
_e('Google Storage is now a part of S3 service settings', 'backwpup');
?>
</li>
<li><?php
_e('All your passwords', 'backwpup');
?>
</li>
</ul>
</div>
<?php
}
?>
</div>
<?php
if (class_exists('BackWPup_Pro', FALSE)) {
?>
<div class="welcometxt">
<div class="backwpup-welcome">
<img class="backwpup-banner-img" src="<?php
echo BackWPup::get_plugin_data('URL');
?>
/assets/images/backwpupbanner-pro.png" />
<h3><?php
_e('Welcome to BackWPup Pro', 'backwpup');
?>
</h3>
//.........这里部分代码省略.........
示例8: page
/**
* Page Output
*/
public static function page()
{
global $wpdb;
?>
<div class="wrap" id="backwpup-page">
<h1><?php
echo sprintf(__('%s › Settings', 'backwpup'), BackWPup::get_plugin_data('name'));
?>
</h1>
<?php
$tabs = array('general' => __('General', 'backwpup'), 'job' => __('Jobs', 'backwpup'), 'log' => __('Logs', 'backwpup'), 'net' => __('Network', 'backwpup'), 'apikey' => __('API Keys', 'backwpup'), 'information' => __('Information', 'backwpup'));
$tabs = apply_filters('backwpup_page_settings_tab', $tabs);
echo '<h2 class="nav-tab-wrapper">';
foreach ($tabs as $id => $name) {
echo '<a href="#backwpup-tab-' . esc_attr($id) . '" class="nav-tab">' . esc_attr($name) . '</a>';
}
echo '</h2>';
BackWPup_Admin::display_messages();
?>
<form id="settingsform" action="<?php
echo admin_url('admin-post.php');
?>
" method="post">
<?php
wp_nonce_field('backwpupsettings_page');
?>
<input type="hidden" name="page" value="backwpupsettings" />
<input type="hidden" name="action" value="backwpup" />
<input type="hidden" name="anchor" value="#backwpup-tab-general" />
<div class="table ui-tabs-hide" id="backwpup-tab-general">
<h3 class="title"><?php
_e('Display Settings', 'backwpup');
?>
</h3>
<p><?php
_e('Do you want to see BackWPup in the WordPress admin bar?', 'backwpup');
?>
</p>
<table class="form-table">
<tr>
<th scope="row"><?php
_e('Admin bar', 'backwpup');
?>
</th>
<td>
<fieldset>
<legend class="screen-reader-text"><span><?php
_e('Admin Bar', 'backwpup');
?>
</span></legend>
<label for="showadminbarmenu">
<input name="showadminbarmenu" type="checkbox" id="showadminbarmenu" value="1" <?php
checked(get_site_option('backwpup_cfg_showadminbar'), TRUE);
?>
/>
<?php
_e('Show BackWPup links in admin bar.', 'backwpup');
?>
</label>
</fieldset>
</td>
</tr>
<tr>
<th scope="row"><?php
_e('Folder sizes', 'backwpup');
?>
</th>
<td>
<fieldset>
<legend class="screen-reader-text"><span><?php
_e('Folder sizes', 'backwpup');
?>
</span></legend>
<label for="showfoldersize">
<input name="showfoldersize" type="checkbox" id="showfoldersize" value="1" <?php
checked(get_site_option('backwpup_cfg_showfoldersize'), TRUE);
?>
/>
<?php
_e('Display folder sizes in the files tab when editing a job. (Might increase loading time of files tab.)', 'backwpup');
?>
</label>
</fieldset>
</td>
</tr>
</table>
<h3 class="title"><?php
_e('Security', 'backwpup');
?>
</h3>
<p><?php
_e('Security option for BackWPup', 'backwpup');
?>
</p>
//.........这里部分代码省略.........
示例9: page
/**
* Display the page content
*/
public static function page()
{
?>
<div class="wrap" id="backwpup-page">
<h1><?php
echo esc_html(sprintf(__('%s › Manage Backup Archives', 'backwpup'), BackWPup::get_plugin_data('name')));
?>
</h1>
<?php
BackWPup_Admin::display_messages();
?>
<form id="posts-filter" action="" method="get">
<input type="hidden" name="page" value="backwpupbackups" />
<?php
self::$listtable->display();
?>
<div id="ajax-response"></div>
</form>
</div>
<?php
}
示例10: page
/**
* Print the markup.
*
* @return void
*/
public static function page()
{
$lang = substr(get_locale(), 0, 2);
if ($lang !== 'de') {
$lang = 'en';
}
?>
<div class="wrap" id="backwpup-page">
<?php
BackWPup_Admin::display_messages();
?>
<div class="welcome">
<div class="welcome_inner">
<?php
if (class_exists('BackWPup_Pro', FALSE)) {
?>
<div class="welcometxt">
<div class="backwpup-welcome">
<img class="backwpup-banner-img" src="<?php
echo BackWPup::get_plugin_data('URL');
?>
/assets/images/backwpupbanner.png" />
<h1><?php
esc_html_e('Welcome to BackWPup Pro', 'backwpup');
?>
</h1>
<p><?php
esc_html_e('BackWPup’s job wizards make planning and scheduling your backup jobs a breeze.', 'backwpup');
echo ' ';
_e('Use your backup archives to save your entire WordPress installation including <code>/wp-content/</code>. Push them to an external storage service if you don’t want to save the backups on the same server. With a single backup archive you are able to restore an installation. Use a tool like phpMyAdmin or a plugin like <a href="http://wordpress.org/plugins/adminer/" target="_blank">Adminer</a> to restore your database backup files.', 'backwpup');
?>
</p>
<p><?php
echo str_replace('\\"', '"', sprintf(__('Ready to <a href="%1$s">set up a backup job</a>? You can <a href="%2$s">use the wizards</a> or plan your backup in expert mode.', 'backwpup'), network_admin_url('admin.php') . '?page=backwpupeditjob', network_admin_url('admin.php') . '?page=backwpupwizard'));
?>
</p>
</div>
<?php
if ('2016-06-30' > date('Y-m-d')) {
?>
<a href="https://www.surveymonkey.com/r/BQJZSG2"><img class="backwpup-umfage" src="<?php
echo BackWPup::get_plugin_data('URL');
?>
/assets/images/banner-survey-<?php
echo $lang;
?>
.png" style="height:auto;margin: 26px auto;max-width:100%;" /></a>
<?php
}
?>
</div>
<?php
} else {
?>
<div class="welcometxt">
<div class="backwpup-welcome">
<img class="backwpup-banner-img" src="<?php
echo esc_attr(BackWPup::get_plugin_data('URL'));
?>
/assets/images/backwpupbanner.png" />
<h1><?php
esc_html_e('Welcome to BackWPup', 'backwpup');
?>
</h1>
<p><?php
_e('Use your backup archives to save your entire WordPress installation including <code>/wp-content/</code>. Push them to an external storage service if you don’t want to save the backups on the same server. With a single backup archive you are able to restore an installation. Use a tool like phpMyAdmin or a plugin like <a href="http://wordpress.org/plugins/adminer/" target="_blank">Adminer</a> to restore your database backup files.', 'backwpup');
?>
</p>
<p><?php
esc_html_e('Ready to set up a backup job? Use one of the wizards to plan what you want to save.', 'backwpup');
?>
</p>
</div>
<?php
if ('2016-06-30' > date('Y-m-d')) {
?>
<a href="https://www.surveymonkey.com/r/BQJZSG2"><img class="backwpup-umfage" src="<?php
echo BackWPup::get_plugin_data('URL');
?>
/assets/images/banner-survey-<?php
echo $lang;
?>
.png" style="height:auto;margin: 26px auto;max-width:100%;" /></a>
<?php
}
?>
</div>
<?php
}
?>
<div>
</div>
<div class="features">
<div class="feature-box <?php
//.........这里部分代码省略.........