Skip to main content

Unanswered Questions

852 questions with no answers
3 votes
0 answers
78 views

How to find out what blocks are added by a plugin

I am creating a plugin, which adds a number of blocks defined by JS/PHP as per Gutenberg documentation. I want to display these block names on an admin page. Is there a hook or function I can use ...
3 votes
0 answers
259 views

Gutenberg - What is the best way to save/update post meta?

What would be the best way in Gutenberg to save/update post meta (not from a block). I can't find an API for it. I was thinking of doing some ajax in componentDidMount using wp.ajax.post Any advice ...
3 votes
0 answers
347 views

Make default new sites https (multisite)

Quick background case: If I use Softaculous to install WP in cPanel, I can specify which protocol I would like the site to be in... (so they have something that addresses this). However with my ...
3 votes
0 answers
47 views

Script won't execute in the media manager

I'm trying to execute a jquery script on the click of a button in a custom tab of the media manager, but it does not seem to work. I have been told this might be due to the button not being loaded ...
3 votes
0 answers
629 views

Making a custom widget that includes a tinymce and works in Site Origin Page Builder

For a client I'm using Site Origins Page Builder plugin. It enables the client to make rich layouts for each page by dragging and dropping widgets. Site Origin widgets that require a WYSIWYG-editor ...
3 votes
0 answers
191 views

How to create a repeatable / reusable divs in the metabox?

I have a meta box: <?php function custom_meta_box_markup() { global $post; $meta_box_text = get_post_meta( $post->ID, 'meta-box-text', true ); $meta_box_text_day = get_post_meta( $...
3 votes
0 answers
1k views

How to overwrite JS variable with wp_localize _script?

The function wp_localize_script( $handle, $name, $data ); does not work when trying to overwrite the same variable, that is when calling the function second time with the same $handle and $name but ...
3 votes
0 answers
316 views

Theme Customiser not live previewing changes on pseudo elements

I've been working with the Theme Customiser API lately and found that pseudo elements are not live updating using the previewer. In my project I have an image containing a transparent overlay using ...
2 votes
0 answers
80 views

How to Use Webpack with WordPress Script Modules and Enqueue a Custom Class

I am working on a WordPress project using version 6.5, which introduced support for JavaScript modules. I have a parent theme that exports a JavaScript class, and I want to import this class in a ...
2 votes
0 answers
43 views

Block style variations not enqueued for blocks inside HTML code dynamically rendered via JS

The new WP 6.6 will let anyone style any registered block style variations in theme.json via the styles.blocks.blockName.variations property. Check the following post for more info: https://developer....
2 votes
0 answers
28 views

get_meta_sql hook is not firing

WP_Query uses WP_Meta_Query. I thought this calls the WP_Meta_Query::get_sql() to define the meta query SQL which is where the get_meta_sql filter is applied. I can't get the get_meta_sql filter to ...
2 votes
0 answers
63 views

Can't find elemnts on the DOM using Custom Control in Customizer API

I'am creating a Custom Control on Customizer API, I add Multiple Checkbox as my custom type. When I wanna add a live preview, the jQuery doesn't find the selector that I want. Here's functions.php ...
2 votes
0 answers
400 views

Gutenberg move post/page title to Editor sidebar document panel

I have not liked the way that the post/page title in Wordpress 6 / Gutenberg is contained directly in the block editor. I have found many ways to remove it with filters and / or restyle it but ...
2 votes
0 answers
48 views

configure additonal build files in the @wordpress/create-block

I'm using the @wordpress/create-block package to create my block plugin. It comes with preconfigured webpack settings to build all the assets. By default as js in the src/ folder is built in the build/...
2 votes
0 answers
78 views

Is there any halfway decent documentation on the wp.media JS class?

Sorry for the somewhat rambly question, but has anyone ever seen any good piece of documentation, or maybe even a tutorial on the wp.media JS class? All that i could find documentation-wise is this ...

15 30 50 per page
1
2
3 4 5
57