2022 Developer Survey is open! Take survey.

Questions tagged [theme-customizer]

The Customizer is a framework for staging changes in WordPress. Settings may model anything in a given site (options, theme mods, widgets nav menus, posts, etc.) and the changes are bundled into changesets which are then previewed, saved as drafts, and even scheduled. Themes and plugins alike may extend the Customizer. Questions should be posed related to the Customize API in WordPress, in either PHP and JS.

Filter by
Sorted by
Tagged with
0 votes
0 answers
8 views

How to Add Extra Settings to Appearance/Customizer Sections homepage

I want to exactly add settings to the static_front_page section in the customizer Sections homepage, I wrote code in functions.php for that but it doesn't work. my code in functions.php file: ...
user avatar
0 votes
0 answers
37 views

OOP PHP class extends TwentyTwenty_Customize in Child Theme

Not sure if OOP is covered here but i've copied the class-twentytwenty-customize.php file from the Twenty Twenty parent theme to my child theme and renamed it to class-customize.php because i need to ...
user avatar
2 votes
1 answer
84 views

the Customizer - proper way to instantiate an image upload control via javascript

I am trying to create an image control using: wp.customize.control.add( new wp.customize.Control( myControlSettingID { type: "image", button_labels: {select: 'Select ...
user avatar
  • 148
0 votes
0 answers
14 views

Grabing default from cuztomizer php file instead of other php script

I've seen codes that use something like: $this->default; I don't know the logic for that style of code yet. To grab a default for spesific customizer control or from a configuration file instead of ...
user avatar
0 votes
0 answers
9 views

Astra theme - cannot set short product description under the product title (product name)

I want to have following vertical structure on my products short description: Image->Product Name->Short Description. I've read that by default it is this order. This is the code I'm using: ...
user avatar
  • 1
0 votes
0 answers
9 views

How to add wysiwyg editor in customize screen using customize_register

Welcome I am developing a theme and I need to add wysiwyg editor to the customize screen using the “customize_register()” , I searched a lot here and on other sites about how to add it, and although ...
user avatar
0 votes
1 answer
21 views

require_once not working in plugin wordpress

I'm creating a plugin and I have to add some custom controls through the plugin. Here is the code for the custom control defined in featured-types.php - function ...
user avatar
0 votes
0 answers
14 views

How to register dynamic settings in WordPress Customizer?

I have been experimenting with the Customizer JS API to create Panels, Sections, Settings and Controls in the Customizer. Till now, I have been using the PHP API but decided to try the JS API for the ...
user avatar
0 votes
1 answer
61 views

Multiple jQuery inputs or binds in Customizer Control Javascripts

If I have 2 javascript parts (for the Wordpress customizer), how do I get part_two to have access to use the data entry from part_one? See example below. The part_two script needs access to part_one ...
user avatar
0 votes
0 answers
12 views

How would you set Theme Customizer API Previewer Preview URL of a Logged out Page or Login Screen

How would you set the WP_Customizer preview iframe to a Logged out page like the Login Screen /wp-login.php? I'm aware of how to set the preview page on expansion of panels or sections, but I have ...
user avatar
0 votes
0 answers
11 views

Elementor Sidebar not loading when PRO elements plugin is active

I am currently running into an issue on my site whereby the elementor plugin will not load in the editor view while the PRO elements plugin is installed The issue is that the theme and pre-built site ...
user avatar
  • 1
0 votes
0 answers
7 views

WordPress navigation URL became hashed URL automatically

I'm customizing a WordPress theme and while changing the nav bar I faced an issue. When I add some page Link under the main service page the main service page URL became hashed URL. I've also used a ...
user avatar
0 votes
0 answers
13 views

Let user to upload multiple time

I'm using the Superio WordPress theme and I want to add a feature to the theme but I don't know how! The default logic of the theme is like this: The user would log in to an account and would apply ...
user avatar
0 votes
0 answers
13 views

Don't run code if in customizer or privew

I have a function compiling my sass every time the page loads, IF it's enabled in the theme. This of course gives a couple of seconds load time which is fine, it's only used in development. But I'm ...
user avatar
  • 11
0 votes
1 answer
29 views

How to copy page/post from one theme to another?

I was using default wordpress 2022 theme and created few post & page templates from Appearance -> Editor -> Templates. These templates are lost when I switched to a child theme. Is it ...
user avatar
  • 121
0 votes
0 answers
20 views

Sanitize callback function for select controll in customizer

I've a select type control in customizer. I've used a sanitize_callback function there but it's not working and it's holding my customizer as well. Can you please help me with a sanitize_callback ...
user avatar
0 votes
0 answers
25 views

Illegal string offset in PHP function in via Theme Customizer

I have this setting in wp_customize: // Select share box options. $wp_customize->add_setting( 'single_share_box_options', array( 'default' => $this->defaults['...
user avatar
  • 454
1 vote
0 answers
55 views

Create a range slider to change font-size with different screens sizes in wordpress customizer api

I have been trying to create a theme customizer to change the font size. To do that I have created settings and control. But the issue is I am unable to achieve like as shown in the image. I have used ...
user avatar
0 votes
0 answers
19 views

Want to permanently remove pagination number page/2/ in WordPress

I'm using GeneratePress (GP) theme. They have default infinity scrolling feature. I am using this infinity scrolling instead of pagination. But problem is when I go to homepage or category page and ...
user avatar
0 votes
0 answers
14 views

Twentyseventeen theme customize bug

I have been trying to work out an issue with a clean install of wordpress using the customizer for the TwentySeventeen theme. I use the latest version of the theme. In the details it states that it ...
user avatar
  • 109
0 votes
0 answers
13 views

Issue with Wordpress customize

I am usign Hello Elemntor Child Theme. I am changing woocommerce product thumbnail size. it change in customize preview but when i see it on front end or i refresh the customize page, changes get ...
user avatar
1 vote
0 answers
44 views

How to conditionally show/hide controls & sections in WordPress customizer?

I have some custom sections and controls in the WordPress customizer, including a section where other sections can be turned on and off depending on what elements the user wants on the page. When a ...
user avatar
  • 11
0 votes
1 answer
45 views

Broken Customizer page

​Hello! The (Theme Customizer) is broken. The link from the menu disappeared and when I access it via the URL wp-admin/customize.php I got the attached error on my console. Screenshot: Things I tried ...
user avatar
0 votes
0 answers
28 views

Defining path of content folder in WP-config solves the issue of missing header, footer, theme options. Is this a good approach? Expert Advice needed

The header, footer, theme options went missing on the website. I am using the latest Bitnami WordPress Stack on Amazon Lightsail, Approach A: Bitnami installations using system packages. When I ...
user avatar
0 votes
0 answers
32 views

Creating a WordPress Customizer control/field with react

I know,We can create panels, sections and controls in the Customizer with JavaScript. Is there a way where i can create a custom control using react component, then use it in customizer field.
user avatar
0 votes
0 answers
23 views

How to change listing type permlink?

How to change the listing type permalink? I tried changing it from the admin dashboard permalink field but it’s not working. I am using MyListing theme, i tried to reach them but no response till now ...
user avatar
0 votes
1 answer
24 views

Why would the child theme load in the Customize preview, but not on the site itself?

I have my child theme folder, the style.css sheet with the required template comment and some custom css, and I have the functions.php page with the required enqueing code. Everything seems to be in ...
user avatar
0 votes
0 answers
12 views

Making the menu toggled open on mobile devices Illustratr theme

I would like to make the menu appear the way it does on desktop devices for mobile and tablet devices. It's open on desktop, but a hamburger icon for smaller screens. I looked at this question, but ...
user avatar
  • 113
0 votes
0 answers
45 views

Will WordPress updates remove Gutenberg Additional Classes?

I’m attempting to customize Gutenberg column blocks on my front page. I’ve added a custom class name to a column block using the blocks Additional CSS class feature. In my child theme style sheet, I’...
user avatar
0 votes
0 answers
35 views

Custom link with checkbox that adds additional word to checked menu items

I need to add a checkbox on the custom link field section of the menu customizer, that then adds a hard coded word to the spesific menu names that have the checkbox checked. I don't want a text box ...
user avatar
1 vote
0 answers
8 views

Add fields in customization tab to change background colours of certain classes

I'm maintaining a Wordpress theme for a website that has an annual style change. Nothing fundamental, a few images get switched out and the colour scheme changes as well. The theme uses a pallette of ...
user avatar
0 votes
0 answers
31 views

How to save theme customizer values as sub-array?

I created a custom control cluster for the theme customizer which includes radio input and textarea. I want to save the data as sub-array, as in array( key => array() ) The data attribute data-...
user avatar
  • 59
0 votes
1 answer
24 views

How to get a custom field in theme customizer to live update the element in preview window?

I created a custom field for theme customizer, and all works fine to display the field, save the value to the DB and retrievable via get_theme_mod(), but it does not live update in the preview window. ...
user avatar
  • 59
0 votes
1 answer
14 views

What is the method to switch to specific page on entering theme customizer screen?

On entering the theme customizer, it defaults to the set home page, however I need to change the default to a page with ID 45. The set home page uses a special template and is formatted by the ...
user avatar
  • 59
0 votes
1 answer
33 views

How to add CSS to head by php through echo self::css();

The tutorial https://iamsteve.me/blog/hero-area-series-wordpress-customizer-with-selective-refresh#customizer-setup gives a method for changing color by WordPress Customizer (Color control). It ...
user avatar
0 votes
0 answers
15 views

How to correctly change styles of elements using selective refresh from Customizer

I have a WP_Customize_Color_Control in the Customizer. And I have the following selective_refresh code; $wp_customize->selective_refresh->add_partial( 'bgcolor', ...
user avatar
0 votes
0 answers
48 views

How to Display Error in my WordPress customizer API?

I have been trying to add error to my WordPress customizer API like this error message: I am trying to add custom message when the user enter invalid phone number, here is my custom code: $...
user avatar
0 votes
0 answers
14 views

Create (Use) Custom Widget Area

I'm wondering how to create and use a custom widget area on one of my pages. The theme I'm using already comes with some default areas specified and I created a new one by going to Appearance -> ...
user avatar
  • 1
1 vote
1 answer
108 views

making customizer sections sortable but items not getting sorted first time items are moved

I'm trying to make a panel in customizer whose sections are sortable and the order of the sections determines the order of the areas they control at the front-end. I referred to the following question ...
user avatar
0 votes
1 answer
26 views

customizer refresh breaks with this code but I don't understand why

Below code is a portion of my "wp_nav_menu" code. I don't understand why the 4th part below, the 'menu' section breaks the "customizer refresh". It makes the refresh in customizer ...
user avatar
0 votes
1 answer
70 views

In wordpress customizer div still showing even if I hid it with javascript

I am loading a div in my single.php based on a setting in the customizer. It all works fine in the front-end as expected. But in the customizer that div is still showing even if the setting is ...
user avatar
0 votes
0 answers
20 views

what is the best way to use postMessage refresh in customizer to load a template part using get_template part()?

Let's say I have a checkbox in the customizer. I want to load a file : /template-parts/components/author-info by this: if (get_theme_mod('show_author_info')) { get_template_part('/template-parts/...
user avatar
0 votes
0 answers
24 views

Customizer API postMessage not working when previously unchecked

I'm showing author info in single.php with <?php if ( get_theme_mod( '_themename_display_author_info', true) ) : get_template_part( '/template-parts/single/post-navigation' ); endif;?> I'm ...
user avatar
0 votes
0 answers
26 views

How to send all theme_mod customizer default values to the database upon theme installation?

I'm building a new theme with many customizer settings, which all have default values. I need these default values to be sent to the database immediately upon theme installation, so that they appear ...
user avatar
0 votes
1 answer
38 views

Change a customizer control based on another control's value dynamically

I am creating a Google Font Control in Customizer. I have created a custom control with two settings - one for font-family and other for font-weight. There will be select dropwdowns for both of them ...
user avatar
0 votes
0 answers
28 views

add partial menu and widget in customizer

I added a minimalistic php code to the function.php. this is a menu and a widget. both should be changeable as quickly as possible. the logo has a pencil icon. this allows you to quickly access the ...
user avatar
  • 1
0 votes
1 answer
54 views

how to enqueu customiser/customizer scripts?

my script has one line wp.customize.control('control_id').deactivate() the control DOES exist. as an evidence I inject the above code directly into the browser consol and it works (the control ...
user avatar
0 votes
0 answers
17 views

How to customize a regular user's page

I am new to wordpress. At first I thought the "customizer" is just for newbies who need a WYSIWYG page editor and I should be able to change any setting without using the customizer. Later, ...
user avatar
  • 117
0 votes
0 answers
20 views

Auto-expandable search box and pre-loader progress bar in CSS

I am not very familiar with WordPress and CSS, however, I am trying to describe the scenario. my system info is mentioned below: php 8.0.7 WordPress 5.7.2 woocommerce 5.4.1 elementor pro 3.3.1 theme: ...
user avatar
0 votes
0 answers
34 views

Mini cart list style?

i got some problem with my mini cart. I use apus thème-tumbas The dropdown from the minicart is different if i'm on main page , product page or cart page. I dont Know why .. All those pictures are ...
user avatar

1
2 3 4 5
19