theme-customizer is a set of classes introduced in 3.4 for customizing themes using a live ajax preview. Theme developers can use these classes for theme options.

learn more… | top users | synonyms (1)

0
votes
1answer
9 views

How to Add new Arguments to custom Control of customizer wordpress?

The problem is that new arguments don't display at customizer. at first, we extend WP_Customize_Control with this class: class WP_Customize_Foo_Control extends WP_Customize_Control { public $...
7
votes
2answers
4k views

How do I implement the WordPress Iris picker into my plugin on the front-end?

This question here is asking the same question as I am, but there were no adequate answers nor a selected correct answer so I am asking again hoping if I ask in a more coherent manner I might get a ...
0
votes
1answer
39 views

Function has_custom_logo when used in Customizer

I'm attempting to integrate the custom-logo functionality introduced in 4.5 and I'm running into some issues with the Customizer interface. I'm checking has_custom_logo and, if it's false, I'm ...
0
votes
1answer
22 views

customizer live preview layout picker

I'm trying to create a layout picker option using the wordpress customizer. What i've done so far works except for the live preview. when i change an option in the customizer for example left sidebar ...
0
votes
1answer
420 views

Add new panel inside parent panel in WP Customize?

Is possible, add a panel within another panel. example: First Panel > child Panel > Section > First Setting ... Second Panel > Section > First Setting ...
1
vote
1answer
23 views

From where the header-text can be changed in WordPress custom header?

I am developing a small theme as I am beginner. I am setting up custom-header using add_theme_support() function. From there I can change the header image in the front end. Ok, so far is good. Now In ...
0
votes
1answer
99 views

Adding a Theme Customizer Control for Posts_Per_Page

I am trying to add a Theme Customizer Control to change the number of posts shown in my WP_Query posts_per_page, like so... $posts_per_page_option = get_option( 'posts_per_page_option' ); $...
2
votes
0answers
34 views

Need to run a plugin on Customize.php

I'm running a multisite installation and have a plugin installed that lets users that are given a user meta option to be their specific role on any site that they aren't associated with. So if they ...
0
votes
0answers
19 views

Moving widgets panel in Customizer one level up

When adding widgets into the sidebars using the Customizer, there is one unnecessary step till you get to panel with the "Add a Widget" button. Three steps: Widgets → Sidebar → panel with ...
0
votes
1answer
28 views

unnecessary request call for js and css after calling wp_dequeue_script

called unnecessary js and css request http://www.example.com/wp-content/plugins/includes/js/jquery.form.min.js http://www.example.com/wp-content/plugins/includes/js/scripts.js orignal it was http:/...
2
votes
1answer
420 views

How to enable “shift-click to edit this widget” functionality on a custom widget?

I have created several custom widgets, modeled from the default widgets' code. The widgets all work fine, and I've been using them in production for awhile. I've been working with the new Customizer ...
4
votes
1answer
254 views

Is the theme customizer slowing down my site?

I have built an awesome theme, which is very flexible, because it has 500 settings in the theme customizer. I generate the live css like it says in the codex: function mytheme_customize_css() { ?&...
5
votes
1answer
83 views

Custom editable content for front page from Theme Customizer

I developed a very basic theme with underscores. I am looking for custom editable content, or a changeable page, from the Theme Customizer for front-page.php. For example, when a user goes to ...
0
votes
1answer
29 views

Theme Customizer for only author.php (per user baisi)

How can the Wordpress Theme Customizer be used only for author.php and settings will be saved per user basis. By which every user can customize their own author.php. How can it be achieved?
1
vote
1answer
30 views

How to output widget

I have the following code to display widgets in the customizer. function arphabet_widgets_init() { register_sidebar( array( 'name' => 'Social Media button', 'id' => ...
1
vote
2answers
854 views

WP Customize refresh problem

Hi I am adding options to WP Customize. Mostly everything works, but One of my variable is not refreshed in the preview window. $wp_customize->add_setting('checkbox', array( 'capability' =...
2
votes
1answer
30 views

Change setting name in Customizer and keep the data

I created a theme while back when I was new to Customizer API and for some weird reasons I named theme settings as: $wp_customize->add_setting('thefunk_theme_options[header_color] Instead of just ...
0
votes
1answer
13 views

Make customizer controls get custom setting type value

I've registered a custom setting type to set a site_option rather than option or theme_mod. I've written the appropriate action hooks to make these values save and preview properly, and can easily ...
1
vote
1answer
28 views

get_theme_mod not working

For some reason I cannot output the color. Everything works, but text_color just doesn't want to output its value. What is going wrong? Back end code (functions.php): $wp_customize->add_setting('...
0
votes
1answer
31 views

Add Social Media icon widget to customizer

How can I add a Customizer widget to add social media icons with links to their social media profiles? To clear it up, I have created a few images with the inspect element. I want to have a section ...
-4
votes
0answers
19 views

How can I create new setting and control with wp.customize.js?

I need to create new settings value on the fly with wp.customize.js api but I didn't find any help about it. How can I create new setting and control (for example, input field for text or image) with ...
0
votes
1answer
53 views

Customizer, change preview url when a control changes

I've a dropdown control that lists all pages of the website. When I select a page in the dropdown I would update the preview iframe to that page. There is the following method to change the ...
1
vote
2answers
58 views

Sidebar not show customizer!

It's showing widgets.php: Not showing customizer: sidebar.php function footer_sidebar() { register_sidebar( array( 'name' => __( 'Footer Sidebar 1', 'footer1' ), ...
5
votes
1answer
95 views

Customizer Active Callback not working

From some reason my active_callback => 'is_front_page' is not working and therefore not showing up inside the customizer on the front-page. I have definitely set my front page to static and ...
3
votes
1answer
46 views

Remove nav_menus from customizer using a theme

Is there a way to remove the "Menu's" or in dev language nav_menus from the customizer? I have tried $wp_customize->remove_section('nav_menus'); but that did not work. $wp_customize->...
2
votes
1answer
906 views

Crop image from get_theme_mod Customizer field

I'm using the following code to allow a user to upload a custom image (in addition to header image) through the customizer. Is there a way to crop the image when displaying it? $wp_customize->...
0
votes
0answers
23 views

Add Google Map with Wp Customizer API

Ideally I would like users to enter their address in the customiser, and then display their map on the contact page. Not being able to do this, I simply added a text area where they can embed / paste ...
0
votes
1answer
16 views

Return value of get_background_color

I want to return the value of get_background_color but that value isn't showing up. <?php echo get_background_color(); ?> I have colors enabled in my customizer, and there is the option '...
1
vote
2answers
21 views

Creating Dependant Text field in Customizer with Checkbox

I'm trying to show a text area in my customizer, only when a checkbox is selected. I followed instruction at this post, but my textarea stays hidden. Any help will be super appreciated! Thank you ...
2
votes
1answer
68 views

How to extend Customizer payload sent when 'Save & Publish' is triggered

By default, customized sent the below payload when the Save & Publish button is clicked. wp_customize:on theme:twentysixteen customized:{"header_color[primary]":"345"} nonce:d2a36386d3 action:...
5
votes
1answer
60 views

How to customize a shortcode using the customizer

General context: I have a plugin which implements a widget and I would like to make the widget into a shortcode. The widget has many options some of them mutually exclusive, and it is never good UX ...
0
votes
0answers
17 views

How to Remove background attachments + Background Image must be 1440x900 px

I want to remove the custom_background features; such as the background attachment, position, background repeat, etc etc. Basically every option below the background uploader as you can see below. PS:...
0
votes
0answers
14 views

HTML inside Customizer

Some themes have that premium button with HTML items in the editor, like this: How did they managed to do that? I tried to look inside the functions.php of Zerif Lite (A theme who also uses HTML ...
4
votes
2answers
45 views

Display custom_background outside wp_head()

My theme is a very small one page theme which really doesn't need all the scripts, so I've created a few options to remove wp_head() and wp_footer() so the user can choose if they want to enable or ...
0
votes
0answers
36 views

widget_sidebar not working

I'm trying to add a widget to my customizer. But it is not being added, it doesn't matter which code I try to add from the WP examples but they're all not showing up. add_action( 'widgets_init', '...
2
votes
1answer
26 views

Removing pre existing menu item

I want to remove the following items from the customizer menu: However, I already tried a few codes from other Stack questions but with no luck! Is it even possible to remove those?
2
votes
1answer
19 views

Does the customizer support multiple templates?

I only started using the WordPress theme customizer lately and was wondering if it can be used for more than editing the front page. Is it possible to add a template (or page/post) selector to the ...
2
votes
1answer
38 views

add_action customize_register not working

I've been working on this for a long time but can't get it fixed. I'm simply trying to get the function below to work but it's refusing to do that. I have put it in functions.php of my theme. ...
3
votes
1answer
149 views

Editing the custom background CSS

I have added the add_theme_support( 'custom-background'); function to my functions.php but the CSS which will be added to the wp_head isn't the way I want it to be. <style type="text/css" id="...
1
vote
1answer
34 views

Customizer options

I'm currently working on a WordPress theme. The design + functionality is already done and it's activated. But this is my first day of creating themes for WordPress (hello, new friends) and I'm unsure ...
3
votes
0answers
19 views

Send data from Customizer Settings to Customizer Preview with settingless control

There are a few ways to speak back and forth with the customizer API. I don't think my scenario is that much f an offshoot so I will give it to you. I have a button in the Customizer to trigger a ...
1
vote
1answer
19 views

Removing http:// from esc url() for wordpress customizer code

I've been trying to figure this out for a few days now and I've now come to the understanding I need help. I've never worked with the wordpress customizer but have been recently interested in adding ...
0
votes
1answer
23 views

get_option in header.php not returning value from customizer

I've set up a new section in the customizer called Social Links, under which I've set up an option and text field control called Facebook. Here's the code in my functions.php: // SOCIAL LINKS $...
0
votes
1answer
573 views

Set image dimension for WP_Customize_Image_Control images

In the customize page for the current theme the Current Header's Choose Image dialog shows - a "select and crop" option But the custom WP_Customize_Image_Control shows only "Choose Image". Is ...
0
votes
1answer
22 views

How to delete old custom-css-stuff in the customizer-live-preview?

I have a problem in the customizer. I want to see the live-preview from the CSS pseudo-elements and custom_css, too. So I append the <style> in the <head> like this, in the customizer.js: ...
0
votes
1answer
326 views

Theme Customizer : how to create multiple-level panel

Is there a way to create deep-level sub Panel in Theme Customizer(like roots of plants) ? My theme that I have been developing seem to be more complicated. I think that if we can create deep-level sub ...
0
votes
1answer
40 views

Why is action customize_register being done twice?

add_action( 'after_setup_theme', 'wdwt_customizer_register' ); function wdwt_customizer_register(){ add_action( 'customize_register', 'wdwt_customizer_add_panels' ); } function ...
6
votes
1answer
56 views

When cropping a header image, retain meta data (i.e. name, description, etc.) from original image?

I'm currently using WordPress's built in Custom Headers to get images for a slideshow on the homepage of my website. For the most part, this has worked as intended; it allows me to upload a set of ...
2
votes
0answers
14 views

Different customizer previewUrls per section

For example if there is a Customizer section that focuses on Woocommerce options, I'd like the user to be on the shop page for that, to see all these changes, live. I can do http://127.0.0.1/wp-...
2
votes
0answers
19 views

Detecting Wordpress Customizer Panel

Recently started developing a Wordpress theme relying heavily on the customizer API. One thing I'm stuck with is detecting when a specific panel has been clicked or opened. Regular old "on click" ...