All Questions

Filter by
Sorted by
Tagged with
1
vote
0answers
21 views

Automatically create child pages and grandchild pages when saving a (parent) page

I have a bit of a tricky one... I have a hierarchical Custom Post Type ('shows') that represents events. Is it possible for the user to create a new page (ie show), save the page and for Wordpress to ...
0
votes
1answer
29 views

How to add automatically bootstrap 4 order-lg-1 and order-lg-2 classes for columns in foreach loop based on the count?

How to add automatically bootstrap 4 order-lg-1 and order-lg-2 classes for columns in foreach loop based on the count? PHP and Html Code <?php //get your custom posts ids as an array $...
0
votes
0answers
14 views

PHP Warning: A non-numeric value encountered in

I am currently getting the "PHP Warning: A non-numeric value encountered in" on two lines of a Wordpress plugin I am using... Here is the code from the plugin that is causing the issue ...
0
votes
2answers
30 views

How to show my post type TEAM in dynamic way?

Hi everyone, I am starting now to develoo my first wordpress Theme and please, I need your help with code. With this code I created my post type Team, the problem is to show them, I do not know how to ...
0
votes
1answer
24 views

ACF Date Based wp_query

I've been trying to order these exhibitions based on the end_date custom field created with Advanced Custom Fields. I'm not able to properly get this working. I need the most recent dates first. I ...
0
votes
1answer
27 views

Custom permalink structure for custom post types including multiple taxonomy

The goal is to have a structure like this: example.com/tax_1/tax_2/post_name This code produces the right structure but the post can't be found (404) // Register custom post types function ...
1
vote
1answer
15 views

Add icon/badge next to posttitle of specific category

I would like to place an icon in the post title of every article from the category "plus". This is my attempt for function.php, but it doesn't work that way. Can someone please give me some ...
0
votes
1answer
15 views

WooCommerce minimum order amount for specific country excluding local pickup [closed]

I am trying to craft a code for WooCommerce to set a minimum order amount for specific countries, but I want to let them order if they select "local pickup" as their shipping method. ...
0
votes
0answers
14 views

MyListing + WCFM - Change path on click (redirect?) [closed]

Im attemptng to tweak MyListing and WCFM so they can play nicely together but im having some trouble. The main issue is that when a user has registered and created a listing it creates the url domain....
0
votes
0answers
13 views

Is it possible to edit a wordpress category with Gutenberg?

i woud like to use Gutenberg to create custom category layouts. Is that possible somehow to activate it for categories?
0
votes
0answers
15 views

I want to capture the front page for Genesis Infinity pro child theme in functions.php [closed]

I am using Genesis Infinity Pro child theme. It is using widgets as Home page layout. That's why when I am trying to capture the front page using is_front_page() function, it is returning false when ...
0
votes
0answers
10 views

Filter by language in gutenberg posts block (polylang)

I use polylang and have posts in two languages. I created a page with a posts block using the gutenberg editor but the block shows me posts in all languages, only allowing me to filter by category. Is ...
1
vote
0answers
20 views

How to create pagination for custom taxonomy in Wordpress

my code it's this, and i can't create the pagination for that, its working good the pages 1, 2, 3 and etc.. but its just that the pagination links are not showing in the template. I created a template ...
0
votes
2answers
32 views

$post->ID not working in combination with a custom query

What is the reason that $post->ID is not working in metabox_callback after adding a custom query. How can I avoid this? Should I use $post_id = isset( $_GET['post'] ) ? $_GET['post'] : ( isset( $...
0
votes
0answers
16 views

Template category.php with page (no posts)

on my home page I have clickable images that redirect me to custom pages. On each page, I've made sure I can assign categories. Now, I want to filter these categories by clicking on the button ...
0
votes
1answer
9 views

WooCommerce: Force coupon for existing/registered customers [closed]

I have some specific regular customers for which I have particular coupons, like 10%, 15% etc. I want the coupon codes to be fixed in their useraccounts so that they do NOT need to enter it during ...
0
votes
1answer
13 views

How to add the google ad conversion tracking code into the thank you page

How to add the google ad conversion tracking code into the thank you page (Contact form7 - Redirected thank you page) in WordPress. I’ve tried to place the tracking code on this specific page but ...
0
votes
1answer
18 views

meta_query order by date present -> future then show null

Thanks for taking the time to read this. I've been struggling with a meta_query for an events site I'm working on. I have used ACF to create a field for date start and date end, but not all events ...
0
votes
0answers
7 views

WP Multisite - domain mapping to domain.com and separate site to domain.com/help

I'm considering setting up a WP multisite network. It would seem to fit my situation perfectly. There's one thing I still need to find out about domain mapping. Say I have the multisite installed on ...
0
votes
1answer
26 views

CF7 select value get to function and reciept value from function

Si I try to asking different How I can get the value from following field: <label> Geburtsjahr/ année de naissance (Pflichtfeld) [select* annee include_blank "1940" "1941" &...
0
votes
0answers
10 views

append currency to URL

I have a wordpress site with multilingual content (WPML) and multiple currencies. What I want to achieve is that I can assign a specific currency through a URL and that that currency then stays "...
0
votes
2answers
31 views

has_excerpt() not working inside wp_query

I am trying to check for an excerpt and if it doesn't exist then show the content but trimmed. Currently nothing is showing. <?php if (has_excerpt() ): ?> <p><?php echo ...
0
votes
1answer
16 views

Ajax filter - show all results that contain at least one filter

For a project I use Timber (TWIG) with WordPress. I'm trying to implement ajax filter with tags on a video template. But it doesn't work like I would like. For the moment my system is too strict. ...
0
votes
0answers
15 views

Call WP Rest-Api to GET /users/me returned NOTHING in console

I am trying to get the login details of my wordpress account via WP Rest-Api with Cookies Auth in the logged-in wordpress condition. However, when I run it through a web browser I do not get anything ...
1
vote
1answer
26 views

How can I add more “filters” to my products? (Categories, attributes, etc.)

I want to make a shop that sells car parts. In order to do so I need additional categories such as make, model, year and so on. The reason why I don't want to put everything in the "categories&...
-1
votes
0answers
16 views

How to use the following code on a WordPress site?

I have been trying to make a custom page for a custom post type to be displayed for a logged in user. I stumbled across this article. I am relatively new to programming, can you please tell me how to ...
0
votes
0answers
9 views

ACF relationship field group by taxonomy

How i can use ACF relationship filed to show output group by taxonomies. For example: I have post type "courses" with taxonomies "Undergraduate" & "Postgraduate". If ...
0
votes
0answers
15 views

reply comment below the comment box without reload page

I make a comment form before comment list and I want to show a comment form inside the comment box that chose to reply without refresh the page the website I inspired the idea Novin.com
0
votes
0answers
8 views

How to add and edit comments in wordpress admin panel

I'm using cocoon theme, and now customizing it in child theme. I want to add and edit comments of posts. But in admin panel I can only see the comments that users made. Please help me.
0
votes
0answers
8 views

Wordpress Theme , plugin for corporate traning [closed]

I am in search of themes , plugins for corporate training business . Please suggest The website may loook similar to https://www.wiculty.com/docker-and-kubernetes-certified-training , edureka.com etc
0
votes
0answers
11 views

In my wordpress woocommerce site, I want to received shipping amount online when placing order and order amount on cash on delivery [closed]

On my woocommerce website. How can I, received shipping amount online and order amount as cash on delivery at the time of placing Order? I tried so many plugins, but I was failed to find such a plugin....
0
votes
1answer
20 views

How to dynamically set a background image with the customizer without putting the css as an inline-style

Here is what I am using currently, <div class="home-header" style="background-image:url('<?php echo get_theme_mod( 'home-header-img' ); ?>'); height: 500px; width: 100%; ...
0
votes
0answers
8 views

How do I filter comments and display it only form the page that the comments belong to?

Say I have community page and a feedback page. Comments from both pages go to comment section in the dashboard. How do I filter community page's comment and display it in the community page and same ...
1
vote
1answer
20 views

How to implement Google Tag Manager?

Trying to use google tag manager. It requires code in the . I tried editing the theme for our website but its returning a white screen see the below code before I add Tag Manager echo '<body ...
0
votes
1answer
13 views

Write/saved logs in Wordpress

I´m doing a plugin which includes a query to import data from external API into custom post types/taxonomies/medias etc... The query can be really heavy. I had to make logs to know exactly what ...
0
votes
0answers
12 views

wp_editor not working in Visual mode and becomes empty on save

I have created a custom widget, and want to transform the textarea into a wysiwyg editor. The widget looks like this, I've stripped out all the unnecessary parts. class Sponsor_Widget extends ...
0
votes
0answers
16 views

how can I restrict one (product category) so it can only be purchased with partial payment i.e mycred + PayPal [closed]

how can I restrict one (product category) so it can only be purchased with partial payment i.e mycred points + PayPal (70% points + 30% currency ), rest of the product categories can be paid by 100% ...
0
votes
0answers
10 views

BeTheme - improve search results [closed]

I'm using BeTheme with Muffin Builder to my create a website and I was almost done. But unfortunately when I tested the search mechanism (using the default wordpress search system) I've found out that ...
0
votes
1answer
17 views

Extend meta query arguments

I have this meta query: $args = array( 'post_type' => 'events', 'meta_query' => array( array( 'key' => 'fl_type', 'value' => 'Awards' ) )...
0
votes
0answers
10 views

How can I have a filterable video library

I am trying to have a membership video library on my website and not sure how to do it. User should be able to filter videos based on Drop down, checkbox or other filter types. Example is shown below. ...
0
votes
1answer
14 views

$wpdb not working wordpress plugin ajax call

i am trying to make a dependend picklist set in a wordpress plugin. Within the plugin i have a javascript with the following method $('#am_organisation').change(function(){ ...
4
votes
1answer
43 views

How can I remove a hooked action created by a plugin?

public function orddd_capabilities() { $role = get_role( 'shop_manager' ); if ( $role != '' ) { $role->add_cap( 'manage_options' ); } } add_action( '...
0
votes
1answer
15 views

Echoing a variable comes out with lots of white space

I'm having trouble when I get variables from WP function come out very long. How do I trim that down? trim and substr do not see the spaces before or after. Why is it so long? <?php $...
0
votes
0answers
14 views

How to submit the settings api data by ajax on theme options page

Instead of reloading i need to submit the data by ajax. it is because theme options having customized tab sections and all the fields are in array in a single field of settings api. //Displaying and ...
0
votes
0answers
17 views

How to get taxonomy list by custom post id via REST API?

I have an issue with custom post types taxonomies. I can't get taxonomy by the custom post id, instead I'm getting all taxonomies list, even if custom post hasn't any taxonomy. I tried: /wp-json/wp/v2/...
0
votes
1answer
16 views

API endpoint to get most-read and popular posts

I am reading Endpoint reference exposed from wordpress api but I don't see an endpoint to get most read post(s) and popular post. There is an endpoint to retreive all posts https://example.com/wp-json/...
0
votes
0answers
14 views

How to filter menu of categories on attribute archive pages

The following PHP displays menu of WooCommerce product categories: <?php $orderby = 'name'; $order = 'asc'; $hide_empty = true ; $cat_args = array( 'orderby' => $orderby, 'order' ...
0
votes
1answer
18 views

Two e-commerce in two different folders of the same domain

I need to create two e-commerce with woocommerce, one in the main directory of my site in Italian and English for online sales in Europe, and one in a subfolder or subdirectory exclusive for ...
0
votes
1answer
35 views

Clear Terms from Taxonomy for Specific Post IDs?

Trying figure out how I can use some SQL/$wpdb->query to delete all the terms from a taxonomy that are related to specific post IDs. The following works beautifully to delete all the terms from a ...
0
votes
1answer
24 views

Function to automatically rename the base category permalink

I need a function to paste in my theme that automatically rename the base category permalink from category to genre after activating the theme, example: http://localhost/category/drama/ to http://...

15 30 50 per page
1
3 4
5
6 7
2091