本文整理汇总了PHP中parent::log_path方法的典型用法代码示例。如果您正苦于以下问题:PHP parent::log_path方法的具体用法?PHP parent::log_path怎么用?PHP parent::log_path使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类parent
的用法示例。
在下文中一共展示了parent::log_path方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: validate_options
public function validate_options($input = array())
{
if ($_REQUEST['download_log_file']) {
$this->download_log_file();
exit;
}
if (empty($input) && $_SERVER['REQUEST_METHOD'] == "POST" && isset($_POST[self::$_plugin_action_slug])) {
$input = $_POST[self::$_plugin_action_slug];
}
$saved_option = parent::get_option('ac_inspector_log_path');
if (!empty($input['log_path'])) {
if ($saved_option === FALSE) {
parent::add_option('ac_inspector_log_path', $input['log_path']);
} else {
parent::update_option('ac_inspector_log_path', $input['log_path']);
}
parent::$log_path = $input['log_path'];
}
$routines = (array) ACI_Routine_Handler::get_all();
foreach (array_keys($routines) as $routine) {
$routine_settings = ACI_Routine_Handler::get_options($routine);
if (!empty($input[$routine]) && is_array($input[$routine])) {
$new_routine_settings = $input[$routine];
} else {
$new_routine_settings = array();
}
foreach ($new_routine_settings as $opt => $val) {
$routine_settings[$opt] = $new_routine_settings[$opt];
}
$routine_settings = apply_filters($routine . '_settings', $routine_settings);
ACI_Routine_Handler::set_options($routine, $routine_settings);
}
if (is_multisite() && is_plugin_active_for_network(ACI_PLUGIN_BASENAME)) {
// redirect to settings page in network
wp_redirect(add_query_arg(array('page' => ACI_PLUGIN_SLUG, 'updated' => 'true'), network_admin_url('settings.php')));
exit;
}
return $input;
}