function pinboard_admin_options_page()
{
    ?>
	<div class="wrap">
		<?php 
    pinboard_admin_options_page_tabs();
    ?>
		<?php 
    if (isset($_GET['settings-updated'])) {
        ?>
			<div class='updated'><p><?php 
        _e('Theme settings updated successfully.', 'pinboard');
        ?>
</p></div>
		<?php 
    }
    ?>
		<form action="options.php" method="post">
			<?php 
    settings_fields('pinboard_theme_options');
    ?>
			<?php 
    do_settings_sections('pinboard_options');
    ?>
			<p>&nbsp;</p>
			<?php 
    $tab = isset($_GET['tab']) ? $_GET['tab'] : 'general';
    ?>
			<input name="pinboard_theme_options[submit-<?php 
    echo $tab;
    ?>
]" type="submit" class="button-primary" value="<?php 
    _e('Save Settings', 'pinboard');
    ?>
" />
			<input name="pinboard_theme_options[reset-<?php 
    echo $tab;
    ?>
]" type="submit" class="button-secondary" value="<?php 
    _e('Reset Defaults', 'pinboard');
    ?>
" />
			<script>
				jQuery(document).ready(function($) {
					$('.wp-color-picker').wpColorPicker();
				});
			</script>
		</form>
	</div>
<?php 
}
Exemple #2
0
function pinboard_admin_options_page() { ?>
	<div class="wrap">
		<?php pinboard_admin_options_page_tabs(); ?>
		<?php if ( isset( $_GET['settings-updated'] ) ) : ?>
			<div class='updated'><p><?php _e( 'Theme settings updated successfully.', 'pinboard' ); ?></p></div>
		<?php endif; ?>
		<form action="options.php" method="post">
			<?php settings_fields( 'pinboard_theme_options' ); ?>
			<?php do_settings_sections('pinboard_options'); ?>
			<p>&nbsp;</p>
			<?php $tab = ( isset( $_GET['tab'] ) ? $_GET['tab'] : 'general' ); ?>
			<input name="pinboard_theme_options[submit-<?php echo $tab; ?>]" type="submit" class="button-primary" value="<?php _e( 'Save Settings', 'pinboard' ); ?>" />
			<input name="pinboard_theme_options[reset-<?php echo $tab; ?>]" type="submit" class="button-secondary" value="<?php _e( 'Reset Defaults', 'pinboard' ); ?>" />
		</form>
	</div>
<?php
}