[wp-trac] [WordPress Trac] #43161: add_theme_support('custom-header')

WordPress Trac noreply at wordpress.org
Fri Jan 26 07:50:05 UTC 2018


#43161: add_theme_support('custom-header')
----------------------------+-----------------------------
 Reporter:  santipm         |      Owner:
     Type:  defect (bug)    |     Status:  new
 Priority:  normal          |  Milestone:  Awaiting Review
Component:  General         |    Version:  4.9.2
 Severity:  normal          |   Keywords:
  Focuses:  administration  |
----------------------------+-----------------------------
 No Working
 {{{#!php
 <?php

 $defaults = array(
                         'default-image'          => '',
                         'width'                  => 0,
                         'height'                 => 0,
                         'flex-height'            => false,
                         'flex-width'             => false,
                         'uploads'                => false,
                         'random-default'         => true,
                         'header-text'            => true,
                         'default-text-color'     => '#000',
                         'wp-head-callback'       => '_entro',
                         'admin-head-callback'    => 'admin_header_style',
                         'admin-preview-callback' => '',
                 );

 add_theme_support( 'custom-header', $defaults );

 //Access Panel admin Aparencce->Header
 function admin_header_style() {
         echo '<script type=""text/javascript">console.log("admin
 script")</script>';
 }



 //its works
 add_action('admin-head','admin_header_style' );

 }}}

--
Ticket URL: <https://core.trac.wordpress.org/ticket/43161>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list