Edit File by line

Deprecated: str_replace(): Passing null to parameter #2 ($replace) of type array|string is deprecated in /home/sportsfever/public_html/filemanger/function.php on line 93

Warning: Undefined array key "page_file_edit_line" in /home/sportsfever/public_html/filemanger/edit_text_line.php on line 32
/home/sportsfe.../httpdocs/wp-inclu...
File: class-wp-customize-manager.php
}
[5000] Fix | Delete
echo "})( _wpCustomizeSettings.settings );\n";
[5001] Fix | Delete
[5002] Fix | Delete
// Serialize controls one by one to improve memory usage.
[5003] Fix | Delete
echo "(function ( c ){\n";
[5004] Fix | Delete
foreach ( $this->controls() as $control ) {
[5005] Fix | Delete
if ( $control->check_capabilities() ) {
[5006] Fix | Delete
printf(
[5007] Fix | Delete
"c[%s] = %s;\n",
[5008] Fix | Delete
wp_json_encode( $control->id ),
[5009] Fix | Delete
wp_json_encode( $control->json() )
[5010] Fix | Delete
);
[5011] Fix | Delete
}
[5012] Fix | Delete
}
[5013] Fix | Delete
echo "})( _wpCustomizeSettings.controls );\n";
[5014] Fix | Delete
?>
[5015] Fix | Delete
</script>
[5016] Fix | Delete
<?php
[5017] Fix | Delete
wp_print_inline_script_tag( wp_remove_surrounding_empty_script_tags( ob_get_clean() ) );
[5018] Fix | Delete
}
[5019] Fix | Delete
[5020] Fix | Delete
/**
[5021] Fix | Delete
* Returns a list of devices to allow previewing.
[5022] Fix | Delete
*
[5023] Fix | Delete
* @since 4.5.0
[5024] Fix | Delete
*
[5025] Fix | Delete
* @return array List of devices with labels and default setting.
[5026] Fix | Delete
*/
[5027] Fix | Delete
public function get_previewable_devices() {
[5028] Fix | Delete
$devices = array(
[5029] Fix | Delete
'desktop' => array(
[5030] Fix | Delete
'label' => __( 'Enter desktop preview mode' ),
[5031] Fix | Delete
'default' => true,
[5032] Fix | Delete
),
[5033] Fix | Delete
'tablet' => array(
[5034] Fix | Delete
'label' => __( 'Enter tablet preview mode' ),
[5035] Fix | Delete
),
[5036] Fix | Delete
'mobile' => array(
[5037] Fix | Delete
'label' => __( 'Enter mobile preview mode' ),
[5038] Fix | Delete
),
[5039] Fix | Delete
);
[5040] Fix | Delete
[5041] Fix | Delete
/**
[5042] Fix | Delete
* Filters the available devices to allow previewing in the Customizer.
[5043] Fix | Delete
*
[5044] Fix | Delete
* @since 4.5.0
[5045] Fix | Delete
*
[5046] Fix | Delete
* @see WP_Customize_Manager::get_previewable_devices()
[5047] Fix | Delete
*
[5048] Fix | Delete
* @param array $devices List of devices with labels and default setting.
[5049] Fix | Delete
*/
[5050] Fix | Delete
$devices = apply_filters( 'customize_previewable_devices', $devices );
[5051] Fix | Delete
[5052] Fix | Delete
return $devices;
[5053] Fix | Delete
}
[5054] Fix | Delete
[5055] Fix | Delete
/**
[5056] Fix | Delete
* Registers some default controls.
[5057] Fix | Delete
*
[5058] Fix | Delete
* @since 3.4.0
[5059] Fix | Delete
*/
[5060] Fix | Delete
public function register_controls() {
[5061] Fix | Delete
[5062] Fix | Delete
/* Themes (controls are loaded via ajax) */
[5063] Fix | Delete
[5064] Fix | Delete
$this->add_panel(
[5065] Fix | Delete
new WP_Customize_Themes_Panel(
[5066] Fix | Delete
$this,
[5067] Fix | Delete
'themes',
[5068] Fix | Delete
array(
[5069] Fix | Delete
'title' => $this->theme()->display( 'Name' ),
[5070] Fix | Delete
'description' => (
[5071] Fix | Delete
'<p>' . __( 'Looking for a theme? You can search or browse the WordPress.org theme directory, install and preview themes, then activate them right here.' ) . '</p>' .
[5072] Fix | Delete
'<p>' . __( 'While previewing a new theme, you can continue to tailor things like widgets and menus, and explore theme-specific options.' ) . '</p>'
[5073] Fix | Delete
),
[5074] Fix | Delete
'capability' => 'switch_themes',
[5075] Fix | Delete
'priority' => 0,
[5076] Fix | Delete
)
[5077] Fix | Delete
)
[5078] Fix | Delete
);
[5079] Fix | Delete
[5080] Fix | Delete
$this->add_section(
[5081] Fix | Delete
new WP_Customize_Themes_Section(
[5082] Fix | Delete
$this,
[5083] Fix | Delete
'installed_themes',
[5084] Fix | Delete
array(
[5085] Fix | Delete
'title' => __( 'Installed themes' ),
[5086] Fix | Delete
'action' => 'installed',
[5087] Fix | Delete
'capability' => 'switch_themes',
[5088] Fix | Delete
'panel' => 'themes',
[5089] Fix | Delete
'priority' => 0,
[5090] Fix | Delete
)
[5091] Fix | Delete
)
[5092] Fix | Delete
);
[5093] Fix | Delete
[5094] Fix | Delete
if ( ! is_multisite() ) {
[5095] Fix | Delete
$this->add_section(
[5096] Fix | Delete
new WP_Customize_Themes_Section(
[5097] Fix | Delete
$this,
[5098] Fix | Delete
'wporg_themes',
[5099] Fix | Delete
array(
[5100] Fix | Delete
'title' => __( 'WordPress.org themes' ),
[5101] Fix | Delete
'action' => 'wporg',
[5102] Fix | Delete
'filter_type' => 'remote',
[5103] Fix | Delete
'capability' => 'install_themes',
[5104] Fix | Delete
'panel' => 'themes',
[5105] Fix | Delete
'priority' => 5,
[5106] Fix | Delete
)
[5107] Fix | Delete
)
[5108] Fix | Delete
);
[5109] Fix | Delete
}
[5110] Fix | Delete
[5111] Fix | Delete
// Themes Setting (unused - the theme is considerably more fundamental to the Customizer experience).
[5112] Fix | Delete
$this->add_setting(
[5113] Fix | Delete
new WP_Customize_Filter_Setting(
[5114] Fix | Delete
$this,
[5115] Fix | Delete
'active_theme',
[5116] Fix | Delete
array(
[5117] Fix | Delete
'capability' => 'switch_themes',
[5118] Fix | Delete
)
[5119] Fix | Delete
)
[5120] Fix | Delete
);
[5121] Fix | Delete
[5122] Fix | Delete
/* Site Identity */
[5123] Fix | Delete
[5124] Fix | Delete
$this->add_section(
[5125] Fix | Delete
'title_tagline',
[5126] Fix | Delete
array(
[5127] Fix | Delete
'title' => __( 'Site Identity' ),
[5128] Fix | Delete
'priority' => 20,
[5129] Fix | Delete
)
[5130] Fix | Delete
);
[5131] Fix | Delete
[5132] Fix | Delete
$this->add_setting(
[5133] Fix | Delete
'blogname',
[5134] Fix | Delete
array(
[5135] Fix | Delete
'default' => get_option( 'blogname' ),
[5136] Fix | Delete
'type' => 'option',
[5137] Fix | Delete
'capability' => 'manage_options',
[5138] Fix | Delete
)
[5139] Fix | Delete
);
[5140] Fix | Delete
[5141] Fix | Delete
$this->add_control(
[5142] Fix | Delete
'blogname',
[5143] Fix | Delete
array(
[5144] Fix | Delete
'label' => __( 'Site Title' ),
[5145] Fix | Delete
'section' => 'title_tagline',
[5146] Fix | Delete
)
[5147] Fix | Delete
);
[5148] Fix | Delete
[5149] Fix | Delete
$this->add_setting(
[5150] Fix | Delete
'blogdescription',
[5151] Fix | Delete
array(
[5152] Fix | Delete
'default' => get_option( 'blogdescription' ),
[5153] Fix | Delete
'type' => 'option',
[5154] Fix | Delete
'capability' => 'manage_options',
[5155] Fix | Delete
)
[5156] Fix | Delete
);
[5157] Fix | Delete
[5158] Fix | Delete
$this->add_control(
[5159] Fix | Delete
'blogdescription',
[5160] Fix | Delete
array(
[5161] Fix | Delete
'label' => __( 'Tagline' ),
[5162] Fix | Delete
'section' => 'title_tagline',
[5163] Fix | Delete
)
[5164] Fix | Delete
);
[5165] Fix | Delete
[5166] Fix | Delete
// Add a setting to hide header text if the theme doesn't support custom headers.
[5167] Fix | Delete
if ( ! current_theme_supports( 'custom-header', 'header-text' ) ) {
[5168] Fix | Delete
$this->add_setting(
[5169] Fix | Delete
'header_text',
[5170] Fix | Delete
array(
[5171] Fix | Delete
'theme_supports' => array( 'custom-logo', 'header-text' ),
[5172] Fix | Delete
'default' => 1,
[5173] Fix | Delete
'sanitize_callback' => 'absint',
[5174] Fix | Delete
)
[5175] Fix | Delete
);
[5176] Fix | Delete
[5177] Fix | Delete
$this->add_control(
[5178] Fix | Delete
'header_text',
[5179] Fix | Delete
array(
[5180] Fix | Delete
'label' => __( 'Display Site Title and Tagline' ),
[5181] Fix | Delete
'section' => 'title_tagline',
[5182] Fix | Delete
'settings' => 'header_text',
[5183] Fix | Delete
'type' => 'checkbox',
[5184] Fix | Delete
)
[5185] Fix | Delete
);
[5186] Fix | Delete
}
[5187] Fix | Delete
[5188] Fix | Delete
$this->add_setting(
[5189] Fix | Delete
'site_icon',
[5190] Fix | Delete
array(
[5191] Fix | Delete
'type' => 'option',
[5192] Fix | Delete
'capability' => 'manage_options',
[5193] Fix | Delete
'transport' => 'postMessage', // Previewed with JS in the Customizer controls window.
[5194] Fix | Delete
)
[5195] Fix | Delete
);
[5196] Fix | Delete
[5197] Fix | Delete
$this->add_control(
[5198] Fix | Delete
new WP_Customize_Site_Icon_Control(
[5199] Fix | Delete
$this,
[5200] Fix | Delete
'site_icon',
[5201] Fix | Delete
array(
[5202] Fix | Delete
'label' => __( 'Site Icon' ),
[5203] Fix | Delete
'description' => sprintf(
[5204] Fix | Delete
/* translators: %s: Site Icon size in pixels. */
[5205] Fix | Delete
'<p>' . __( 'The Site Icon is what you see in browser tabs, bookmark bars, and within the WordPress mobile apps. It should be square and at least %s pixels.' ) . '</p>',
[5206] Fix | Delete
'<code>512 &times; 512</code>'
[5207] Fix | Delete
),
[5208] Fix | Delete
'section' => 'title_tagline',
[5209] Fix | Delete
'priority' => 60,
[5210] Fix | Delete
'height' => 512,
[5211] Fix | Delete
'width' => 512,
[5212] Fix | Delete
)
[5213] Fix | Delete
)
[5214] Fix | Delete
);
[5215] Fix | Delete
[5216] Fix | Delete
$this->add_setting(
[5217] Fix | Delete
'custom_logo',
[5218] Fix | Delete
array(
[5219] Fix | Delete
'theme_supports' => array( 'custom-logo' ),
[5220] Fix | Delete
'transport' => 'postMessage',
[5221] Fix | Delete
)
[5222] Fix | Delete
);
[5223] Fix | Delete
[5224] Fix | Delete
$custom_logo_args = get_theme_support( 'custom-logo' );
[5225] Fix | Delete
$this->add_control(
[5226] Fix | Delete
new WP_Customize_Cropped_Image_Control(
[5227] Fix | Delete
$this,
[5228] Fix | Delete
'custom_logo',
[5229] Fix | Delete
array(
[5230] Fix | Delete
'label' => __( 'Logo' ),
[5231] Fix | Delete
'section' => 'title_tagline',
[5232] Fix | Delete
'priority' => 8,
[5233] Fix | Delete
'height' => isset( $custom_logo_args[0]['height'] ) ? $custom_logo_args[0]['height'] : null,
[5234] Fix | Delete
'width' => isset( $custom_logo_args[0]['width'] ) ? $custom_logo_args[0]['width'] : null,
[5235] Fix | Delete
'flex_height' => isset( $custom_logo_args[0]['flex-height'] ) ? $custom_logo_args[0]['flex-height'] : null,
[5236] Fix | Delete
'flex_width' => isset( $custom_logo_args[0]['flex-width'] ) ? $custom_logo_args[0]['flex-width'] : null,
[5237] Fix | Delete
'button_labels' => array(
[5238] Fix | Delete
'select' => __( 'Select logo' ),
[5239] Fix | Delete
'change' => __( 'Change logo' ),
[5240] Fix | Delete
'remove' => __( 'Remove' ),
[5241] Fix | Delete
'default' => __( 'Default' ),
[5242] Fix | Delete
'placeholder' => __( 'No logo selected' ),
[5243] Fix | Delete
'frame_title' => __( 'Select logo' ),
[5244] Fix | Delete
'frame_button' => __( 'Choose logo' ),
[5245] Fix | Delete
),
[5246] Fix | Delete
)
[5247] Fix | Delete
)
[5248] Fix | Delete
);
[5249] Fix | Delete
[5250] Fix | Delete
$this->selective_refresh->add_partial(
[5251] Fix | Delete
'custom_logo',
[5252] Fix | Delete
array(
[5253] Fix | Delete
'settings' => array( 'custom_logo' ),
[5254] Fix | Delete
'selector' => '.custom-logo-link',
[5255] Fix | Delete
'render_callback' => array( $this, '_render_custom_logo_partial' ),
[5256] Fix | Delete
'container_inclusive' => true,
[5257] Fix | Delete
)
[5258] Fix | Delete
);
[5259] Fix | Delete
[5260] Fix | Delete
/* Colors */
[5261] Fix | Delete
[5262] Fix | Delete
$this->add_section(
[5263] Fix | Delete
'colors',
[5264] Fix | Delete
array(
[5265] Fix | Delete
'title' => __( 'Colors' ),
[5266] Fix | Delete
'priority' => 40,
[5267] Fix | Delete
)
[5268] Fix | Delete
);
[5269] Fix | Delete
[5270] Fix | Delete
$this->add_setting(
[5271] Fix | Delete
'header_textcolor',
[5272] Fix | Delete
array(
[5273] Fix | Delete
'theme_supports' => array( 'custom-header', 'header-text' ),
[5274] Fix | Delete
'default' => get_theme_support( 'custom-header', 'default-text-color' ),
[5275] Fix | Delete
[5276] Fix | Delete
'sanitize_callback' => array( $this, '_sanitize_header_textcolor' ),
[5277] Fix | Delete
'sanitize_js_callback' => 'maybe_hash_hex_color',
[5278] Fix | Delete
)
[5279] Fix | Delete
);
[5280] Fix | Delete
[5281] Fix | Delete
// Input type: checkbox, with custom value.
[5282] Fix | Delete
$this->add_control(
[5283] Fix | Delete
'display_header_text',
[5284] Fix | Delete
array(
[5285] Fix | Delete
'settings' => 'header_textcolor',
[5286] Fix | Delete
'label' => __( 'Display Site Title and Tagline' ),
[5287] Fix | Delete
'section' => 'title_tagline',
[5288] Fix | Delete
'type' => 'checkbox',
[5289] Fix | Delete
'priority' => 40,
[5290] Fix | Delete
)
[5291] Fix | Delete
);
[5292] Fix | Delete
[5293] Fix | Delete
$this->add_control(
[5294] Fix | Delete
new WP_Customize_Color_Control(
[5295] Fix | Delete
$this,
[5296] Fix | Delete
'header_textcolor',
[5297] Fix | Delete
array(
[5298] Fix | Delete
'label' => __( 'Header Text Color' ),
[5299] Fix | Delete
'section' => 'colors',
[5300] Fix | Delete
)
[5301] Fix | Delete
)
[5302] Fix | Delete
);
[5303] Fix | Delete
[5304] Fix | Delete
// Input type: color, with sanitize_callback.
[5305] Fix | Delete
$this->add_setting(
[5306] Fix | Delete
'background_color',
[5307] Fix | Delete
array(
[5308] Fix | Delete
'default' => get_theme_support( 'custom-background', 'default-color' ),
[5309] Fix | Delete
'theme_supports' => 'custom-background',
[5310] Fix | Delete
[5311] Fix | Delete
'sanitize_callback' => 'sanitize_hex_color_no_hash',
[5312] Fix | Delete
'sanitize_js_callback' => 'maybe_hash_hex_color',
[5313] Fix | Delete
)
[5314] Fix | Delete
);
[5315] Fix | Delete
[5316] Fix | Delete
$this->add_control(
[5317] Fix | Delete
new WP_Customize_Color_Control(
[5318] Fix | Delete
$this,
[5319] Fix | Delete
'background_color',
[5320] Fix | Delete
array(
[5321] Fix | Delete
'label' => __( 'Background Color' ),
[5322] Fix | Delete
'section' => 'colors',
[5323] Fix | Delete
)
[5324] Fix | Delete
)
[5325] Fix | Delete
);
[5326] Fix | Delete
[5327] Fix | Delete
/* Custom Header */
[5328] Fix | Delete
[5329] Fix | Delete
if ( current_theme_supports( 'custom-header', 'video' ) ) {
[5330] Fix | Delete
$title = __( 'Header Media' );
[5331] Fix | Delete
$description = '<p>' . __( 'If you add a video, the image will be used as a fallback while the video loads.' ) . '</p>';
[5332] Fix | Delete
[5333] Fix | Delete
$width = absint( get_theme_support( 'custom-header', 'width' ) );
[5334] Fix | Delete
$height = absint( get_theme_support( 'custom-header', 'height' ) );
[5335] Fix | Delete
if ( $width && $height ) {
[5336] Fix | Delete
$control_description = sprintf(
[5337] Fix | Delete
/* translators: 1: .mp4, 2: Header size in pixels. */
[5338] Fix | Delete
__( 'Upload your video in %1$s format and minimize its file size for best results. Your theme recommends dimensions of %2$s pixels.' ),
[5339] Fix | Delete
'<code>.mp4</code>',
[5340] Fix | Delete
sprintf( '<strong>%s &times; %s</strong>', $width, $height )
[5341] Fix | Delete
);
[5342] Fix | Delete
} elseif ( $width ) {
[5343] Fix | Delete
$control_description = sprintf(
[5344] Fix | Delete
/* translators: 1: .mp4, 2: Header width in pixels. */
[5345] Fix | Delete
__( 'Upload your video in %1$s format and minimize its file size for best results. Your theme recommends a width of %2$s pixels.' ),
[5346] Fix | Delete
'<code>.mp4</code>',
[5347] Fix | Delete
sprintf( '<strong>%s</strong>', $width )
[5348] Fix | Delete
);
[5349] Fix | Delete
} else {
[5350] Fix | Delete
$control_description = sprintf(
[5351] Fix | Delete
/* translators: 1: .mp4, 2: Header height in pixels. */
[5352] Fix | Delete
__( 'Upload your video in %1$s format and minimize its file size for best results. Your theme recommends a height of %2$s pixels.' ),
[5353] Fix | Delete
'<code>.mp4</code>',
[5354] Fix | Delete
sprintf( '<strong>%s</strong>', $height )
[5355] Fix | Delete
);
[5356] Fix | Delete
}
[5357] Fix | Delete
} else {
[5358] Fix | Delete
$title = __( 'Header Image' );
[5359] Fix | Delete
$description = '';
[5360] Fix | Delete
$control_description = '';
[5361] Fix | Delete
}
[5362] Fix | Delete
[5363] Fix | Delete
$this->add_section(
[5364] Fix | Delete
'header_image',
[5365] Fix | Delete
array(
[5366] Fix | Delete
'title' => $title,
[5367] Fix | Delete
'description' => $description,
[5368] Fix | Delete
'theme_supports' => 'custom-header',
[5369] Fix | Delete
'priority' => 60,
[5370] Fix | Delete
)
[5371] Fix | Delete
);
[5372] Fix | Delete
[5373] Fix | Delete
$this->add_setting(
[5374] Fix | Delete
'header_video',
[5375] Fix | Delete
array(
[5376] Fix | Delete
'theme_supports' => array( 'custom-header', 'video' ),
[5377] Fix | Delete
'transport' => 'postMessage',
[5378] Fix | Delete
'sanitize_callback' => 'absint',
[5379] Fix | Delete
'validate_callback' => array( $this, '_validate_header_video' ),
[5380] Fix | Delete
)
[5381] Fix | Delete
);
[5382] Fix | Delete
[5383] Fix | Delete
$this->add_setting(
[5384] Fix | Delete
'external_header_video',
[5385] Fix | Delete
array(
[5386] Fix | Delete
'theme_supports' => array( 'custom-header', 'video' ),
[5387] Fix | Delete
'transport' => 'postMessage',
[5388] Fix | Delete
'sanitize_callback' => array( $this, '_sanitize_external_header_video' ),
[5389] Fix | Delete
'validate_callback' => array( $this, '_validate_external_header_video' ),
[5390] Fix | Delete
)
[5391] Fix | Delete
);
[5392] Fix | Delete
[5393] Fix | Delete
$this->add_setting(
[5394] Fix | Delete
new WP_Customize_Filter_Setting(
[5395] Fix | Delete
$this,
[5396] Fix | Delete
'header_image',
[5397] Fix | Delete
array(
[5398] Fix | Delete
'default' => sprintf( get_theme_support( 'custom-header', 'default-image' ), get_template_directory_uri(), get_stylesheet_directory_uri() ),
[5399] Fix | Delete
'theme_supports' => 'custom-header',
[5400] Fix | Delete
)
[5401] Fix | Delete
)
[5402] Fix | Delete
);
[5403] Fix | Delete
[5404] Fix | Delete
$this->add_setting(
[5405] Fix | Delete
new WP_Customize_Header_Image_Setting(
[5406] Fix | Delete
$this,
[5407] Fix | Delete
'header_image_data',
[5408] Fix | Delete
array(
[5409] Fix | Delete
'theme_supports' => 'custom-header',
[5410] Fix | Delete
)
[5411] Fix | Delete
)
[5412] Fix | Delete
);
[5413] Fix | Delete
[5414] Fix | Delete
/*
[5415] Fix | Delete
* Switch image settings to postMessage when video support is enabled since
[5416] Fix | Delete
* it entails that the_custom_header_markup() will be used, and thus selective
[5417] Fix | Delete
* refresh can be utilized.
[5418] Fix | Delete
*/
[5419] Fix | Delete
if ( current_theme_supports( 'custom-header', 'video' ) ) {
[5420] Fix | Delete
$this->get_setting( 'header_image' )->transport = 'postMessage';
[5421] Fix | Delete
$this->get_setting( 'header_image_data' )->transport = 'postMessage';
[5422] Fix | Delete
}
[5423] Fix | Delete
[5424] Fix | Delete
$this->add_control(
[5425] Fix | Delete
new WP_Customize_Media_Control(
[5426] Fix | Delete
$this,
[5427] Fix | Delete
'header_video',
[5428] Fix | Delete
array(
[5429] Fix | Delete
'theme_supports' => array( 'custom-header', 'video' ),
[5430] Fix | Delete
'label' => __( 'Header Video' ),
[5431] Fix | Delete
'description' => $control_description,
[5432] Fix | Delete
'section' => 'header_image',
[5433] Fix | Delete
'mime_type' => 'video',
[5434] Fix | Delete
'active_callback' => 'is_header_video_active',
[5435] Fix | Delete
)
[5436] Fix | Delete
)
[5437] Fix | Delete
);
[5438] Fix | Delete
[5439] Fix | Delete
$this->add_control(
[5440] Fix | Delete
'external_header_video',
[5441] Fix | Delete
array(
[5442] Fix | Delete
'theme_supports' => array( 'custom-header', 'video' ),
[5443] Fix | Delete
'type' => 'url',
[5444] Fix | Delete
'description' => __( 'Or, enter a YouTube URL:' ),
[5445] Fix | Delete
'section' => 'header_image',
[5446] Fix | Delete
'active_callback' => 'is_header_video_active',
[5447] Fix | Delete
)
[5448] Fix | Delete
);
[5449] Fix | Delete
[5450] Fix | Delete
$this->add_control( new WP_Customize_Header_Image_Control( $this ) );
[5451] Fix | Delete
[5452] Fix | Delete
$this->selective_refresh->add_partial(
[5453] Fix | Delete
'custom_header',
[5454] Fix | Delete
array(
[5455] Fix | Delete
'selector' => '#wp-custom-header',
[5456] Fix | Delete
'render_callback' => 'the_custom_header_markup',
[5457] Fix | Delete
'settings' => array( 'header_video', 'external_header_video', 'header_image' ), // The image is used as a video fallback here.
[5458] Fix | Delete
'container_inclusive' => true,
[5459] Fix | Delete
)
[5460] Fix | Delete
);
[5461] Fix | Delete
[5462] Fix | Delete
/* Custom Background */
[5463] Fix | Delete
[5464] Fix | Delete
$this->add_section(
[5465] Fix | Delete
'background_image',
[5466] Fix | Delete
array(
[5467] Fix | Delete
'title' => __( 'Background Image' ),
[5468] Fix | Delete
'theme_supports' => 'custom-background',
[5469] Fix | Delete
'priority' => 80,
[5470] Fix | Delete
)
[5471] Fix | Delete
);
[5472] Fix | Delete
[5473] Fix | Delete
$this->add_setting(
[5474] Fix | Delete
'background_image',
[5475] Fix | Delete
array(
[5476] Fix | Delete
'default' => get_theme_support( 'custom-background', 'default-image' ),
[5477] Fix | Delete
'theme_supports' => 'custom-background',
[5478] Fix | Delete
'sanitize_callback' => array( $this, '_sanitize_background_setting' ),
[5479] Fix | Delete
)
[5480] Fix | Delete
);
[5481] Fix | Delete
[5482] Fix | Delete
$this->add_setting(
[5483] Fix | Delete
new WP_Customize_Background_Image_Setting(
[5484] Fix | Delete
$this,
[5485] Fix | Delete
'background_image_thumb',
[5486] Fix | Delete
array(
[5487] Fix | Delete
'theme_supports' => 'custom-background',
[5488] Fix | Delete
'sanitize_callback' => array( $this, '_sanitize_background_setting' ),
[5489] Fix | Delete
)
[5490] Fix | Delete
)
[5491] Fix | Delete
);
[5492] Fix | Delete
[5493] Fix | Delete
$this->add_control( new WP_Customize_Background_Image_Control( $this ) );
[5494] Fix | Delete
[5495] Fix | Delete
$this->add_setting(
[5496] Fix | Delete
'background_preset',
[5497] Fix | Delete
array(
[5498] Fix | Delete
'default' => get_theme_support( 'custom-background', 'default-preset' ),
[5499] Fix | Delete
It is recommended that you Edit text format, this type of Fix handles quite a lot in one request
Function