當前位置: 首頁>>代碼示例>>PHP>>正文


PHP mu_dropdown_languages函數代碼示例

本文整理匯總了PHP中mu_dropdown_languages函數的典型用法代碼示例。如果您正苦於以下問題:PHP mu_dropdown_languages函數的具體用法?PHP mu_dropdown_languages怎麽用?PHP mu_dropdown_languages使用的例子?那麽, 這裏精選的函數代碼示例或許可以為您提供幫助。


在下文中一共展示了mu_dropdown_languages函數的5個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: do_settings_fields

</select></td>
</tr>
<?php 
do_settings_fields('general', 'default');
$languages = get_available_languages();
if (is_multisite() && !empty($languages)) {
    ?>
	<tr>
		<th width="33%" scope="row"><?php 
    _e('Site Language');
    ?>
</th>
		<td>
			<select name="WPLANG" id="WPLANG">
				<?php 
    mu_dropdown_languages($languages, get_option('WPLANG'));
    ?>
			</select>
		</td>
	</tr>
<?php 
}
?>
</table>

<?php 
do_settings_sections('general');
?>

<?php 
submit_button();
開發者ID:Telemedellin,項目名稱:feriadelasfloresmedellin,代碼行數:31,代碼來源:options-general.php

示例2: get_site_option

            $lang_files[] = $lang_file;
        }
    }
}
$lang = get_site_option('WPLANG');
if (is_array($lang_files) && !empty($lang_files)) {
    ?>
				<tr valign="top"> 
					<th width="33%"><?php 
    _e('Default Language');
    ?>
</th> 
					<td>
						<select name="WPLANG" id="WPLANG">
							<?php 
    mu_dropdown_languages($lang_files, get_site_option('WPLANG'));
    ?>
						</select>
					</td>
				</tr> 
				<?php 
}
// languages
?>
		</table>

		<h3><?php 
_e('Menus <em>(Enable or disable WP Backend Menus)</em>');
?>
</h3> 
		<table class="form-table">
開發者ID:alx,項目名稱:blogsfera,代碼行數:31,代碼來源:wpmu-options.php

示例3: edit_user_profile

    /**
     * Display Users Extra Fields
     *
     * @access	public
     * @since	0.1
     * @uses	get_available_languages, mu_dropdown_languages, _e
     * @return	void
     */
    public function edit_user_profile($user)
    {
        $languages = get_available_languages();
        $user_language = $this->get_user_language($user->data->ID);
        ?>
		<tr>
			<th><label for="mlp_user_language"><?php 
        _e('Choose the language which you want to use in the backend', 'multilingualpress');
        ?>
</label></th>
			<td>
				<select name="mlp_user_language" id="mlp_user_language">
					<?php 
        mu_dropdown_languages($languages, $user_language);
        ?>
				</select>
			</td>
		</tr>
		<?php 
    }
開發者ID:m-godefroid76,項目名稱:devrestofactory,代碼行數:28,代碼來源:class-Multilingual_Press_User_Backend_Language.php

示例4: printf

				<td><?php printf( _x( '%s KB', 'File size in kilobytes' ), '<input name="fileupload_maxk" type="number" min="0" style="width: 100px" id="fileupload_maxk" value="' . esc_attr( get_site_option( 'fileupload_maxk', 300 ) ) . '" />' ); ?></td>
			</tr>
		</table>

<?php
		$languages = get_available_languages();
		if ( ! empty( $languages ) ) {
			$lang = get_site_option( 'WPLANG' );
?>
		<h3><?php _e( 'Language Settings' ); ?></h3>
		<table class="form-table">
				<tr>
					<th><label for="WPLANG"><?php _e( 'Default Language' ); ?></label></th>
					<td>
						<select name="WPLANG" id="WPLANG">
							<?php mu_dropdown_languages( $languages, get_site_option( 'WPLANG' ) ); ?>
						</select>
					</td>
				</tr>
		</table>
<?php
		} // languages
?>

		<h3><?php _e( 'Menu Settings' ); ?></h3>
		<table id="menu" class="form-table">
			<tr>
				<th scope="row"><?php _e( 'Enable administration menus' ); ?></th>
				<td>
			<?php
			$menu_perms = get_site_option( 'menu_items' );
開發者ID:staylor,項目名稱:develop.svn.wordpress.org,代碼行數:31,代碼來源:settings.php

示例5: signup_language_signup_form

/**
 * Renders the selection box on signup form
 *
 * @since 1.0
 */
function signup_language_signup_form($errors)
{
    include_once ABSPATH . 'wp-admin/includes/ms.php';
    $languages = get_available_languages();
    ?>
	<div id="language-selection">
		<p class="language-option">
			<label for="language"><?php 
    _e('Select a language', 'signup_language');
    ?>
</label>
			<?php 
    if ($errmsg = $errors->get_error_message('language')) {
        ?>
				<p class="error"><?php 
        echo $errmsg;
        ?>
</p>
			<?php 
    }
    ?>
			<select name="language" id="language">
				<?php 
    mu_dropdown_languages($languages, get_site_option('WPLANG'));
    ?>
			</select>
		</p>
	</div>

	<?php 
}
開發者ID:nayabbukhari,項目名稱:circulocristiano,代碼行數:36,代碼來源:signup-language.php


注:本文中的mu_dropdown_languages函數示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。