当前位置: 首页>>代码示例>>PHP>>正文


PHP UpdraftPlus_Options::options_form_begin方法代码示例

本文整理汇总了PHP中UpdraftPlus_Options::options_form_begin方法的典型用法代码示例。如果您正苦于以下问题:PHP UpdraftPlus_Options::options_form_begin方法的具体用法?PHP UpdraftPlus_Options::options_form_begin怎么用?PHP UpdraftPlus_Options::options_form_begin使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在UpdraftPlus_Options的用法示例。


在下文中一共展示了UpdraftPlus_Options::options_form_begin方法的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: settings_output


//.........这里部分代码省略.........
            echo 'class="updraft-hidden"';
        }
        ?>
 style="<?php 
        if (2 != $tabflag) {
            echo 'display:none;';
        }
        ?>
">
			<?php 
        $is_opera = false !== strpos($_SERVER['HTTP_USER_AGENT'], 'Opera') || false !== strpos($_SERVER['HTTP_USER_AGENT'], 'OPR/');
        $tmp_opts = array('include_opera_warning' => $is_opera);
        $this->settings_downloading_and_restoring($backup_history, false, $tmp_opts);
        $this->settings_delete_and_restore_modals();
        ?>
		</div>

		<div id="updraft-navtab-settings-content" <?php 
        if (3 != $tabflag) {
            echo 'class="updraft-hidden"';
        }
        ?>
 style="<?php 
        if (3 != $tabflag) {
            echo 'display:none;';
        }
        ?>
">
			<h2 class="updraft_settings_sectionheading"><?php 
        _e('Backup Contents And Schedule', 'updraftplus');
        ?>
</h2>
			<?php 
        UpdraftPlus_Options::options_form_begin();
        ?>
				<?php 
        $this->settings_formcontents();
        ?>
			</form>
		</div>

		<div id="updraft-navtab-expert-content"<?php 
        if (4 != $tabflag) {
            echo ' class="updraft-hidden"';
        }
        ?>
 style="<?php 
        if (4 != $tabflag) {
            echo 'display:none;';
        }
        ?>
">
			<?php 
        $this->settings_expertsettings($backup_disabled);
        ?>
		</div>

		<div id="updraft-navtab-addons-content"<?php 
        if (5 != $tabflag) {
            echo ' class="updraft-hidden"';
        }
        ?>
 style="<?php 
        if (5 != $tabflag) {
            echo 'display:none;';
        }
开发者ID:pytong,项目名称:research-group,代码行数:67,代码来源:admin.php

示例2: settings_output


//.........这里部分代码省略.........
            ?>
				<h2>UpdraftPlus <?php 
            _e('Multisite', 'updraftplus');
            ?>
</h2>
				<table>
				<tr>
				<td>
				<p style="max-width:800px;"><?php 
            echo __('Do you need WordPress Multisite support?', 'updraftplus') . ' <a href="http://updraftplus.com/">' . __('Please check out UpdraftPlus Premium, or the stand-alone Multisite add-on.', 'updraftplus');
            ?>
</a>.</p>
				</td>
				</tr>
				</table>
			<?php 
        }
        ?>

		</div>

		<div id="updraft-navtab-backups-content" style="display:none;">
			<?php 
        $this->settings_downloadingandrestoring($backup_history);
        ?>
		</div>

		<div id="updraft-navtab-settings-content" style="display:none;">
			<h2 style="margin-top: 6px;"><?php 
        _e('Configure Backup Contents And Schedule', 'updraftplus');
        ?>
</h2>
			<?php 
        UpdraftPlus_Options::options_form_begin();
        ?>
				<?php 
        $this->settings_formcontents($last_backup_html);
        ?>
			</form>
		</div>

		<div id="updraft-navtab-expert-content"<?php 
        if (4 != $tabflag) {
            echo ' style="display:none;"';
        }
        ?>
>
			<?php 
        $this->settings_expertsettings($backup_disabled);
        ?>
		</div>

		<div id="updraft-navtab-addons-content"<?php 
        if (5 != $tabflag) {
            echo ' style="display:none;"';
        }
        ?>
>

		<?php 
        $tick = UPDRAFTPLUS_URL . '/images/updraft_tick.png';
        $cross = UPDRAFTPLUS_URL . '/images/updraft_cross.png';
        $freev = UPDRAFTPLUS_URL . '/images/updraft_freev.png';
        $premv = UPDRAFTPLUS_URL . '/images/updraft_premv.png';
        ob_start();
        ?>
开发者ID:JunnLearning,项目名称:dk,代码行数:67,代码来源:admin.php

示例3: options_printpage

    public function options_printpage()
    {
        if (!UpdraftPlus_Options::user_can_manage()) {
            wp_die(__('You do not have sufficient permissions to access this page.'));
        }
        $options = $this->options->get_option(UDADDONS2_SLUG . '_options');
        $user_and_pass_at_top = empty($options['email']) ? true : false;
        $title = htmlspecialchars($this->title);
        $mother = $this->mother;
        echo <<<ENDHERE
\t<div class="wrap">
\t\t
ENDHERE;
        $enter_credentials_begin = UpdraftPlus_Options::options_form_begin('', false);
        if (is_multisite()) {
            $enter_credentials_begin .= '<input type="hidden" name="action" value="update">';
        }
        $interested = htmlspecialchars(__('Interested in knowing about your UpdraftPlus.Com password security? Read about it here.', 'updraftplus'));
        $connect = htmlspecialchars(__('Connect', 'updraftplus'));
        $enter_credentials_end = <<<ENDHERE
\t\t\t<p style="margin-left: 258px;">
\t\t\t\t<input id="ud_connectsubmit" type="submit" class="button-primary" value="{$connect}" />
\t\t\t</p>
\t\t\t<p style="margin-left: 258px; font-size: 70%"><em><a href="http://updraftplus.com/faqs/tell-me-about-my-updraftplus-com-account/">{$interested}</a></em></p>
\t\t</form>
ENDHERE;
        global $updraftplus_addons2;
        // 		$this->connected = (!empty($options['email']) && !empty($options['password'])) ? $updraftplus_addons2->connection_status() : false;
        $this->connected = !empty($options['email']) ? $updraftplus_addons2->connection_status() : false;
        if (true !== $this->connected) {
            if (is_wp_error($this->connected)) {
                $connection_errors = array();
                foreach ($this->connected->get_error_messages() as $key => $msg) {
                    $connection_errors[] = $msg;
                }
            } else {
                if (!empty($options['email']) && !empty($options['password'])) {
                    $connection_errors = array(__('An unknown error occurred when trying to connect to UpdraftPlus.Com', 'updraftplus'));
                }
            }
            $this->connected = false;
        }
        if ($this->connected) {
            echo '<p style="clear: both; float: left;">' . __('You are presently <strong>connected</strong> to an UpdraftPlus.Com account.', 'updraftplus');
            echo ' <a href="#" onclick="jQuery(\'#ud_connectsubmit\').click();">' . __('If you bought new add-ons, then follow this link to refresh your connection', 'updraftplus') . '</a>.';
            if (!empty($options['password'])) {
                echo ' ' . __("Note that after you have claimed your add-ons, you can remove your password (but not the email address) from the settings below, without affecting this site's access to updates.", 'updraftplus');
            }
        } else {
            // 			$oval = is_object($this->plug_updatechecker) ? get_site_option($this->plug_updatechecker->optionName, null) : null;
            // 			// Detect the case where the password has been removed
            // 			if (is_object($oval) && !empty($oval->lastCheck) && time()-$oval->lastCheck < 86400*8) {
            // 			} else {
            echo "<p>" . __('You are presently <strong>not connected</strong> to an UpdraftPlus.Com account.', 'updraftplus');
            // 			}
        }
        echo '</p>';
        if (isset($connection_errors)) {
            echo '<div class="error"><p><strong>' . __('Errors occurred when trying to connect to UpdraftPlus.Com:', 'updraftplus') . '</strong></p><ul>';
            foreach ($connection_errors as $err) {
                echo '<li style="list-style:disc inside;">' . $err . '</li>';
            }
            echo '</ul></div>';
        }
        global $updraftplus_addons2;
        $sid = $updraftplus_addons2->siteid();
        $home_url = home_url();
        // Enumerate possible unclaimed/re-claimable purchases, and what should be active on this site
        $unclaimed_available = array();
        $assigned = array();
        $have_all = false;
        if ($this->connected && isset($updraftplus_addons2->user_addons) && is_array($updraftplus_addons2->user_addons)) {
            foreach ($updraftplus_addons2->user_addons as $akey => $addon) {
                // Keys: site, sitedescription, key, status
                if (isset($addon['status']) && 'active' == $addon['status'] && isset($addon['site']) && ('unclaimed' == $addon['site'] || 'unlimited' == $addon['site'])) {
                    $key = $addon['key'];
                    $unclaimed_available[$key] = array('eid' => $akey, 'status' => 'available');
                } elseif (isset($addon['status']) && 'active' == $addon['status'] && isset($addon['site']) && $addon['site'] == $sid) {
                    $key = $addon['key'];
                    $assigned[$key] = $akey;
                    if ('all' == $key) {
                        $have_all = true;
                    }
                } elseif (isset($addon['sitedescription']) && ($home_url === $addon['sitedescription'] || 0 === strpos($addon['sitedescription'], $home_url . ' - '))) {
                    # Is assigned to a site with the same URL as this one - allow a reclaim
                    $key = $addon['key'];
                    $unclaimed_available[$key] = array('eid' => $akey, 'status' => 'reclaimable');
                }
            }
        }
        if (!$this->connected) {
            $this->show_credentials_form($enter_credentials_begin, $enter_credentials_end);
        }
        $email = isset($options['email']) ? $options['email'] : '';
        $pass = isset($options['password']) ? base64_encode($options['password']) : '';
        $sn = base64_encode(get_bloginfo('name'));
        $su = base64_encode($home_url);
        $ourpageslug = UDADDONS2_PAGESLUG;
        $mother = $this->mother;
        //$href = (is_multisite()) ? 'settings.php' : 'options-general.php';
//.........这里部分代码省略.........
开发者ID:jimrucinski,项目名称:Vine,代码行数:101,代码来源:options.php

示例4: settings_output


//.........这里部分代码省略.........

<div id="updraft-iframe-modal">
	<div id="updraft-iframe-modal-innards">
	</div>
</div>

<div id="updraft-backupnow-modal" title="UpdraftPlus - <?php 
        _e('Perform a one-time backup', 'updraftplus');
        ?>
">
	<p><?php 
        _e("To proceed, press 'Backup Now'. Then, watch the 'Last Log Message' field for activity.", 'updraftplus');
        ?>
</p>

	<p>
		<input type="checkbox" id="backupnow_nodb"> <label for="backupnow_nodb"><?php 
        _e("Don't include the database in the backup", 'updraftplus');
        ?>
</label><br>
		<input type="checkbox" id="backupnow_nofiles"> <label for="backupnow_nofiles"><?php 
        _e("Don't include any files in the backup", 'updraftplus');
        ?>
</label><br>
		<input type="checkbox" id="backupnow_nocloud"> <label for="backupnow_nocloud"><?php 
        _e("Don't send this backup to remote storage", 'updraftplus');
        ?>
</label>
	</p>

	<?php 
        do_action('updraft_backupnow_modal_afteroptions');
        ?>

	<p><?php 
        _e('Does nothing happen when you attempt backups?', 'updraftplus');
        ?>
 <a href="http://updraftplus.com/faqs/my-scheduled-backups-and-pressing-backup-now-does-nothing-however-pressing-debug-backup-does-produce-a-backup/"><?php 
        _e('Go here for help.', 'updraftplus');
        ?>
</a></p>
</div>

			<?php 
        if (is_multisite() && !file_exists(UPDRAFTPLUS_DIR . '/addons/multisite.php')) {
            ?>
				<h2>UpdraftPlus <?php 
            _e('Multisite', 'updraftplus');
            ?>
</h2>
				<table>
				<tr>
				<td>
				<p style="max-width:800px;"><?php 
            echo __('Do you need WordPress Multisite support?', 'updraftplus') . ' <a href="http://updraftplus.com/">' . __('Please check out UpdraftPlus Premium, or the stand-alone Multisite add-on.', 'updraftplus');
            ?>
</a>.</p>
				</td>
				</tr>
				</table>
			<?php 
        }
        ?>

		</div>

		<div id="updraft-navtab-backups-content" style="display:none;">
			<?php 
        $this->settings_downloadingandrestoring($backup_history);
        ?>
		</div>

		<div id="updraft-navtab-settings-content" style="display:none;">
			<h2 style="margin-top: 6px;"><?php 
        _e('Configure Backup Contents And Schedule', 'updraftplus');
        ?>
</h2>
			<?php 
        UpdraftPlus_Options::options_form_begin();
        ?>
				<?php 
        $this->settings_formcontents($last_backup_html);
        ?>
			</form>
		</div>

		<div id="updraft-navtab-expert-content"<?php 
        if (4 != $tabflag) {
            echo ' style="display:none;"';
        }
        ?>
>
			<?php 
        $this->settings_expertsettings($backup_disabled);
        ?>
		</div>

		<?php 
        do_action('updraftplus_settings_finish');
    }
开发者ID:lorier,项目名称:thedailydrawing,代码行数:101,代码来源:admin.php

示例5: settings_output


//.........这里部分代码省略.........
        _e('Does nothing happen when you attempt backups?', 'updraftplus');
        ?>
 <a href="http://updraftplus.com/faqs/my-scheduled-backups-and-pressing-backup-now-does-nothing-however-pressing-debug-backup-does-produce-a-backup/"><?php 
        _e('Go here for help.', 'updraftplus');
        ?>
</a></p>
</div>

			<?php 
        if (is_multisite() && !file_exists(UPDRAFTPLUS_DIR . '/addons/multisite.php')) {
            ?>
				<h2>UpdraftPlus <?php 
            _e('Multisite', 'updraftplus');
            ?>
</h2>
				<table>
				<tr>
				<td>
				<p style="max-width:800px;"><?php 
            echo __('Do you need WordPress Multisite support?', 'updraftplus') . ' <a href="http://updraftplus.com/">' . __('Please check out UpdraftPlus Premium, or the stand-alone Multisite add-on.', 'updraftplus');
            ?>
</a>.</p>
				</td>
				</tr>
				</table>
			<?php 
        }
        ?>
			<h2 style="margin-top: 6px;"><?php 
        _e('Configure Backup Contents And Schedule', 'updraftplus');
        ?>
</h2>
			<?php 
        UpdraftPlus_Options::options_form_begin();
        ?>
				<?php 
        $this->settings_formcontents($last_backup_html);
        ?>
			</form>
			<div style="padding-top: 40px; display:none;" class="expertmode">
				<hr>
				<h2><?php 
        _e('Debug Information And Expert Options', 'updraftplus');
        ?>
</h2>
				<p>
				<?php 
        echo sprintf(__('Web server:', 'updraftplus'), 'PHP') . ' ' . htmlspecialchars($_SERVER["SERVER_SOFTWARE"]) . ' (' . htmlspecialchars(php_uname()) . ')<br />';
        echo 'ABSPATH: ' . htmlspecialchars(ABSPATH) . '<br/>';
        echo 'WP_CONTENT_DIR: ' . htmlspecialchars(WP_CONTENT_DIR) . '<br/>';
        echo 'WP_PLUGIN_DIR: ' . htmlspecialchars(WP_PLUGIN_DIR) . '<br/>';
        $peak_memory_usage = memory_get_peak_usage(true) / 1024 / 1024;
        $memory_usage = memory_get_usage(true) / 1024 / 1024;
        echo __('Peak memory usage', 'updraftplus') . ': ' . $peak_memory_usage . ' MB<br/>';
        echo __('Current memory usage', 'updraftplus') . ': ' . $memory_usage . ' MB<br/>';
        echo __('PHP memory limit', 'updraftplus') . ': ' . ini_get('memory_limit') . ' <br/>';
        echo sprintf(__('%s version:', 'updraftplus'), 'PHP') . ' ' . phpversion() . ' - ';
        echo '<a href="admin-ajax.php?page=updraftplus&action=updraft_ajax&subaction=phpinfo&nonce=' . wp_create_nonce('updraftplus-credentialtest-nonce') . '" id="updraftplus-phpinfo">' . __('show PHP information (phpinfo)', 'updraftplus') . '</a><br/>';
        echo sprintf(__('%s version:', 'updraftplus'), 'MySQL') . ' ' . (function_exists('mysql_get_server_info') ? mysql_get_server_info() : '?') . '<br>';
        if (version_compare(phpversion(), '5.2.0', '>=') && extension_loaded('zip')) {
            $ziparchive_exists = __('Yes', 'updraftplus');
        } else {
            # First do class_exists, because method_exists still sometimes segfaults due to a rare PHP bug
            $ziparchive_exists = class_exists('ZipArchive') && method_exists('ZipArchive', 'addFile') ? __('Yes', 'updraftplus') : __('No', 'updraftplus');
        }
        echo __('PHP has support for ZipArchive::addFile:', 'updraftplus') . ' ' . $ziparchive_exists . '<br>';
开发者ID:jeanpage,项目名称:ca_learn,代码行数:67,代码来源:admin.php

示例6: settings_output


//.........这里部分代码省略.........
        _e('Does nothing happen when you schedule backups?', 'updraftplus');
        ?>
 <a href="http://updraftplus.com/faqs/my-scheduled-backups-and-pressing-backup-now-does-nothing-however-pressing-debug-backup-does-produce-a-backup/"><?php 
        _e('Go here for help.', 'updraft');
        ?>
</a></p>
</div>

			<?php 
        if (is_multisite() && !file_exists(UPDRAFTPLUS_DIR . '/addons/multisite.php')) {
            ?>
				<h2>UpdraftPlus <?php 
            _e('Multisite', 'updraftplus');
            ?>
</h2>
				<table>
				<tr>
				<td>
				<p style="max-width:800px;"><?php 
            echo __('Do you need WordPress Multisite support?', 'updraftplus') . ' <a href="http://updraftplus.com/">' . __('Please check out UpdraftPlus Premium, or the stand-alone Multisite add-on.', 'updraftplus');
            ?>
</a>.</p>
				</td>
				</tr>
				</table>
			<?php 
        }
        ?>
			<h2 style="margin-top: 6px;"><?php 
        _e('Configure Backup Contents And Schedule', 'updraftplus');
        ?>
</h2>
			<?php 
        UpdraftPlus_Options::options_form_begin();
        ?>
				<?php 
        $this->settings_formcontents($last_backup_html);
        ?>
			</form>
			<div style="padding-top: 40px; display:none;" class="expertmode">
				<hr>
				<h2><?php 
        _e('Debug Information And Expert Options', 'updraftplus');
        ?>
</h2>
				<p>
				<?php 
        echo sprintf(__('Web server:', 'updraftplus'), 'PHP') . ' ' . htmlspecialchars($_SERVER["SERVER_SOFTWARE"]) . ' (' . htmlspecialchars(php_uname()) . ')<br />';
        $peak_memory_usage = memory_get_peak_usage(true) / 1024 / 1024;
        $memory_usage = memory_get_usage(true) / 1024 / 1024;
        echo __('Peak memory usage', 'updraftplus') . ': ' . $peak_memory_usage . ' MB<br/>';
        echo __('Current memory usage', 'updraftplus') . ': ' . $memory_usage . ' MB<br/>';
        echo __('PHP memory limit', 'updraftplus') . ': ' . ini_get('memory_limit') . ' <br/>';
        echo sprintf(__('%s version:', 'updraftplus'), 'PHP') . ' ' . phpversion() . ' - ';
        echo '<a href="admin-ajax.php?page=updraftplus&action=updraft_ajax&subaction=phpinfo&nonce=' . wp_create_nonce('updraftplus-credentialtest-nonce') . '" id="updraftplus-phpinfo">' . __('show PHP information (phpinfo)', 'updraftplus') . '</a><br/>';
        echo sprintf(__('%s version:', 'updraftplus'), 'MySQL') . ' ' . (function_exists('mysql_get_server_info') ? mysql_get_server_info() : '?') . '<br>';
        if (version_compare(phpversion(), '5.2.0', '>=') && extension_loaded('zip')) {
            $ziparchive_exists .= __('Yes', 'updraftplus');
        } else {
            $ziparchive_exists .= method_exists('ZipArchive', 'addFile') ? __('Yes', 'updraftplus') : __('No', 'updraftplus');
        }
        echo __('PHP has support for ZipArchive::addFile:', 'updraftplus') . ' ' . $ziparchive_exists . '<br>';
        $binzip = $updraftplus->find_working_bin_zip(false);
        echo __('zip executable found:', 'updraftplus') . ' ' . (is_string($binzip) ? __('Yes') . ': ' . $binzip : __('No')) . '<br>';
        echo '<a href="admin-ajax.php?page=updraftplus&action=updraft_ajax&subaction=backuphistoryraw&nonce=' . wp_create_nonce('updraftplus-credentialtest-nonce') . '" id="updraftplus-rawbackuphistory">' . __('Show raw backup and file list', 'updraftplus') . '</a><br/>';
        echo '<h3>' . __('Total (uncompressed) on-disk data:', 'updraftplus') . '</h3>';
开发者ID:brandmobility,项目名称:kikbak,代码行数:67,代码来源:admin.php


注:本文中的UpdraftPlus_Options::options_form_begin方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。