Month: October 2018

wordpress

Page Template dropdown missing from page attribute in wordpress

Page Template dropdown missing from page attribute in wordpress: Either you are are added any page template or format is not correct while adding page template name It is because of space after the page template name: wrong code : <?php /* Template Name :Contact page    // No need to add space here */…

wordpress

How to add a logo uploading field in customize settings in wordpress

How to add a logo uploading field in theme customize settings in wordpress While creating our own theme, we need to add a logo adding field in in customize settings of theme (under appearance). add_action( ‘customize_register‘, ‘themecustomizer’ ); function themecustomizer( $wp_customize ) { $wp_customize->add_section( ‘theme_logo’ , array( ‘title’ => __( ‘Logo’, ‘theme’ ), ‘priority’ =>…

wordpress

How to add a new page in wordpress admin

In functions.php  file, Add following code add_action( ‘admin_menu’, ‘mycustompagemenu’ ); function mycustompagemenu(){ add_menu_page( __( ‘My own Settings’, ‘textdomain’ ), ‘my theme settings’, ‘customize’, ‘mythemesettings’, ‘my_theme_settings_fun’, get_template_directory_uri().’/images/icon.png’, 60 ); } function my_theme_settings_fun(){ esc_html_e( ‘Admin Page’, ‘textdomain’ ); }   For more details   add_menu_page()