Switch language
wpseek on Twitter


A WordPress-centric search engine for devs and theme authors




wp_nav_menu_item_link_meta_box [ ]

wp_nav_menu_item_link_meta_box ( No parameters )
Defined at:
Codex



Displays a metabox for the custom links menu item.

Source

function wp_nav_menu_item_link_meta_box() {
	global $_nav_menu_placeholder, $nav_menu_selected_id;

	$_nav_menu_placeholder = 0 > $_nav_menu_placeholder ? $_nav_menu_placeholder - 1 : -1;

	?>
	<div class="customlinkdiv" id="customlinkdiv">
		<input type="hidden" value="custom" name="menu-item[<?php echo $_nav_menu_placeholder; ?>][menu-item-type]" />
		<p id="menu-item-url-wrap">
			<label class="howto" for="custom-menu-item-url">
				<span><?php _e('URL'); ?></span>
				<input id="custom-menu-item-url" name="menu-item[<?php echo $_nav_menu_placeholder; ?>][menu-item-url]" type="text" class="code menu-item-textbox" value="http://" />
			</label>
		</p>

		<p id="menu-item-name-wrap">
			<label class="howto" for="custom-menu-item-name">
				<span><?php _e( 'Link Text' ); ?></span>
				<input id="custom-menu-item-name" name="menu-item[<?php echo $_nav_menu_placeholder; ?>][menu-item-title]" type="text" class="regular-text menu-item-textbox input-with-default-title" title="<?php esc_attr_e('Menu Item'); ?>" />
			</label>
		</p>

		<p class="button-controls">
			<span class="add-to-menu">
				<input type="submit"<?php wp_nav_menu_disabled_check( $nav_menu_selected_id ); ?> class="button-secondary submit-add-to-menu right" value="<?php esc_attr_e('Add to Menu'); ?>" name="add-custom-menu-item" id="submit-customlinkdiv" />
				<span class="spinner"></span>
			</span>
		</p>

	</div><!-- /.customlinkdiv -->
	<?php
}

Top Google Search Results

More ...

User discussions [ wordpress.org ]

User Note(s)