本文整理汇总了PHP中rich_edit_exists函数的典型用法代码示例。如果您正苦于以下问题:PHP rich_edit_exists函数的具体用法?PHP rich_edit_exists怎么用?PHP rich_edit_exists使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了rich_edit_exists函数的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: _e
<p>
<input type="hidden" name="from" value="profile" />
<input type="hidden" name="checkuser_id" value="<?php
echo $user_ID;
?>
" />
</p>
<h3><?php
_e('Personal Options');
?>
</h3>
<table class="form-table">
<?php
if (rich_edit_exists() && !(IS_PROFILE_PAGE && !$user_can_edit)) {
// don't bother showing the option if the editor has been removed
?>
<tr>
<th scope="row"><?php
_e('Visual Editor');
?>
</th>
<td><label for="rich_editing"><input name="rich_editing" type="checkbox" id="rich_editing" value="false" <?php
checked('false', $profileuser->rich_editing);
?>
/> <?php
_e('Disable the visual editor when writing');
?>
</label></td>
</tr>
示例2: _e
<p>
<input type="hidden" name="from" value="profile" />
<input type="hidden" name="checkuser_id" value="<?php
echo $current_user->ID;
?>
" />
</p>
<h3><?php
_e('Personal Options', 'theme-my-login');
?>
</h3>
<table class="form-table">
<?php
if (rich_edit_exists() && $user_can_edit) {
// don't bother showing the option if the editor has been removed
?>
<tr>
<th scope="row"><?php
_e('Visual Editor', 'theme-my-login');
?>
</th>
<td><label for="rich_editing"><input name="rich_editing" type="checkbox" id="rich_editing" value="false" <?php
checked('false', $profileuser->rich_editing);
?>
/> <?php
_e('Disable the visual editor when writing', 'theme-my-login');
?>
</label></td>
</tr>
示例3: _e
<p>
<input type="hidden" name="from" value="profile" />
<input type="hidden" name="checkuser_id" value="<?php
echo $user_ID;
?>
" />
</p>
<h3><?php
_e('Personal Options');
?>
</h3>
<table class="form-table">
<?php
if (rich_edit_exists()) {
// don't bother showing the option if the editor has been removed
?>
<tr>
<th scope="row"><?php
_e('Visual Editor');
?>
</th>
<td><label for="rich_editing"><input name="rich_editing" type="checkbox" id="rich_editing" value="true" <?php
checked('true', $profileuser->rich_editing);
?>
/> <?php
_e('Use the visual editor when writing');
?>
</label></td>
</tr>
示例4: esc_url
</h2>
<form id="your-profile" action="<?php echo esc_url( self_admin_url( IS_PROFILE_PAGE ? 'profile.php' : 'user-edit.php' ) ); ?>" method="post"<?php do_action('user_edit_form_tag'); ?>>
<?php wp_nonce_field('update-user_' . $user_id) ?>
<?php if ( $wp_http_referer ) : ?>
<input type="hidden" name="wp_http_referer" value="<?php echo esc_url($wp_http_referer); ?>" />
<?php endif; ?>
<p>
<input type="hidden" name="from" value="profile" />
<input type="hidden" name="checkuser_id" value="<?php echo $user_ID ?>" />
</p>
<h3><?php _e('Personal Options'); ?></h3>
<table class="form-table">
<?php if ( rich_edit_exists() && !( IS_PROFILE_PAGE && !$user_can_edit ) ) : // don't bother showing the option if the editor has been removed ?>
<tr>
<th scope="row"><?php _e('Visual Editor')?></th>
<td><label for="rich_editing"><input name="rich_editing" type="checkbox" id="rich_editing" value="false" <?php if ( ! empty( $profileuser->rich_editing ) ) checked( 'false', $profileuser->rich_editing ); ?> /> <?php _e( 'Disable the visual editor when writing' ); ?></label></td>
</tr>
<?php endif; ?>
<?php if ( count($_wp_admin_css_colors) > 1 && has_action('admin_color_scheme_picker') ) : ?>
<tr>
<th scope="row"><?php _e('Admin Color Scheme')?></th>
<td><?php do_action( 'admin_color_scheme_picker' ); ?></td>
</tr>
<?php
endif; // $_wp_admin_css_colors
if ( !( IS_PROFILE_PAGE && !$user_can_edit ) ) : ?>
<tr>
<th scope="row"><?php _e( 'Keyboard Shortcuts' ); ?></th>
示例5: _e
<p>
<input type="hidden" name="from" value="profile" />
<input type="hidden" name="checkuser_id" value="<?php
echo $user_ID;
?>
" />
</p>
<h3><?php
_e('Personal Options');
?>
</h3>
<table class="form-table">
<?php
if (rich_edit_exists() && !(IS_PROFILE_PAGE && !$user_can_edit) && current_user_can('activate_plugins')) {
// don't bother showing the option if the editor has been removed
// LHG: show this option only for admins for testing reasons
?>
<tr>
<th scope="row"><?php
_e('Visual Editor');
?>
</th>
<td><label for="rich_editing"><input name="rich_editing" type="checkbox" id="rich_editing" value="false" <?php
checked('false', $profileuser->rich_editing);
?>
/> <?php
_e('Disable the visual editor when writing');
?>
</label></td>
示例6: _e
<h2><?php $is_profile_page? _e('Your Profile and Personal Options') : _e('Edit User'); ?></h2>
<form name="profile" id="your-profile" action="" method="post">
<?php wp_nonce_field('update-user_' . $user_id) ?>
<?php if ( $wp_http_referer ) : ?>
<input type="hidden" name="wp_http_referer" value="<?php echo clean_url($wp_http_referer); ?>" />
<?php endif; ?>
<p>
<input type="hidden" name="from" value="profile" />
<input type="hidden" name="checkuser_id" value="<?php echo $user_ID ?>" />
</p>
<h3><?php _e('Personal Options'); ?></h3>
<table class="form-table">
<?php if ( rich_edit_exists() ) : // don't bother showing the option if the editor has been removed ?>
<tr>
<th scope="row"><?php _e('Visual Editor')?></th>
<td><label for="rich_editing"><input name="rich_editing" type="checkbox" id="rich_editing" value="true" <?php checked('true', $profileuser->rich_editing); ?> /> <?php _e('Use the visual editor when writing'); ?></label></td>
</tr>
<?php endif; ?>
<tr>
<th scope="row"><?php _e('Admin Color Scheme')?></th>
<td>
<?php
$current_color = get_user_option('admin_color');
if ( empty($current_color) )
$current_color = 'fresh';
foreach ( $_wp_admin_css_colors as $color => $color_info ): ?>
<div class="color-option"><input name="admin_color" id="admin_color_<?php echo $color; ?>" type="radio" value="<?php echo $color ?>" class="tog" <?php checked($color, $current_color); ?> />
<table class="color-palette">
示例7: user_can_richedit
function user_can_richedit() {
global $wp_rich_edit, $pagenow;
if ( !isset($wp_rich_edit) )
$wp_rich_edit = ( 'true' == get_user_option('rich_editing') && !preg_match('!opera[ /][2-8]|konqueror|safari!i', $_SERVER['HTTP_USER_AGENT']) && 'comment.php' != $pagenow && rich_edit_exists() ) ? true : false;
return apply_filters('user_can_richedit', $wp_rich_edit);
}