mirror of
https://github.com/10h30/ultimatemember.git
synced 2026-07-11 18:56:10 +09:00
Date Field Complete
This commit is contained in:
@@ -27,6 +27,7 @@
|
||||
|
||||
$save = '';
|
||||
$save[ $_metakey ]['roles'] = '';
|
||||
$save[ $_metakey ]['disabled_weekdays'] = '';
|
||||
$save[ $_metakey ]['icon'] = '';
|
||||
foreach( $array['post'] as $key => $val){
|
||||
|
||||
|
||||
@@ -0,0 +1,13 @@
|
||||
<?php
|
||||
|
||||
/***
|
||||
*** @Un-install UM completely
|
||||
***/
|
||||
add_action('um_admin_do_action__uninstall_ultimatemember', 'um_admin_do_action__uninstall_ultimatemember');
|
||||
function um_admin_do_action__uninstall_ultimatemember( $action ){
|
||||
global $ultimatemember;
|
||||
if ( !is_admin() || !current_user_can('manage_options') ) die();
|
||||
|
||||
$ultimatemember->uninstall->remove_um();
|
||||
|
||||
}
|
||||
@@ -826,7 +826,12 @@ class UM_Admin_Metabox {
|
||||
?>
|
||||
|
||||
<p><label for="_format">Date User-Friendly Format <?php $this->tooltip('The display format of the date which is visible to user.'); ?></label>
|
||||
<input type="text" name="_format" id="_format" value="<?php echo ( $this->edit_mode_value ) ? $this->edit_mode_value : 'd mmmm, yyyy'; ?>" placeholder="e.g. d mmmm, yyyy" />
|
||||
<select name="_format" id="_format" class="umaf-selectjs" style="width: 100%">
|
||||
<option value="j M Y" <?php selected( 'j M Y', $this->edit_mode_value ); ?>><?php echo $ultimatemember->datetime->get_time('j M Y'); ?></option>
|
||||
<option value="M j Y" <?php selected( 'M j Y', $this->edit_mode_value ); ?>><?php echo $ultimatemember->datetime->get_time('M j Y'); ?></option>
|
||||
<option value="j F Y" <?php selected( 'j F Y', $this->edit_mode_value ); ?>><?php echo $ultimatemember->datetime->get_time('j F Y'); ?></option>
|
||||
<option value="F j Y" <?php selected( 'F j Y', $this->edit_mode_value ); ?>><?php echo $ultimatemember->datetime->get_time('F j Y'); ?></option>
|
||||
</select>
|
||||
</p>
|
||||
|
||||
<?php } else { ?>
|
||||
|
||||
@@ -39,6 +39,7 @@ class UM_Admin_API {
|
||||
require_once um_path . 'admin/core/um-admin-actions-modal.php';
|
||||
require_once um_path . 'admin/core/um-admin-actions-fields.php';
|
||||
require_once um_path . 'admin/core/um-admin-actions-ajax.php';
|
||||
require_once um_path . 'admin/core/um-admin-actions.php';
|
||||
|
||||
require_once um_path . 'admin/core/um-admin-filters-fields.php';
|
||||
|
||||
@@ -56,11 +57,12 @@ class UM_Admin_API {
|
||||
|
||||
if ( is_admin() &&
|
||||
current_user_can('manage_options') &&
|
||||
isset($_REQUEST['um_action']) &&
|
||||
$_REQUEST['um_action'] == 'uninstall_ultimatemember'
|
||||
)
|
||||
isset($_REQUEST['um_adm_action']) &&
|
||||
$_REQUEST['um_adm_action'] != ''
|
||||
)
|
||||
{
|
||||
$ultimatemember->uninstall->remove_um();
|
||||
do_action("um_admin_do_action__", $_REQUEST['um_adm_action'] );
|
||||
do_action("um_admin_do_action__{$_REQUEST['um_adm_action']}", $_REQUEST['um_adm_action'] );
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user