All Questions

Filter by
Sorted by
Tagged with
0
votes
1answer
15 views

Why is my archive.php redirecting to front-page.php?

I generate archives using wp_get_archives() and get list of all my archives. But when I click one of the links its always redirect me to front-page.php which is www.mydomainexample.com. I've created ...
0
votes
1answer
13 views

Ttle color based on category wordpress

I need to set post title bg-color based on category color. I have custom made WordPress template (nes blog) and I have colored category tags (sport- green, politivs - red,...). Now I need to set up bg-...
0
votes
0answers
5 views

Help needed to create a Digital Products marketplace [closed]

so I need to create a Digital Products marketplace, for reference (shutterstock.com, envato.elements.com) Problems: Storage, as there'll be large amount of data, I'm thinking of storing it in S3. But ...
0
votes
1answer
14 views

Delete all users with Editor role and their content mysql

I have a Wordpress site with thousands of editors. I cant delete them from the WP dashboard as its to slow. I need a query to delete all the editor users and their posts from PhpMyAdmin? Thanks
-1
votes
0answers
16 views

How do I turn CPT automatically also into category?

When I create a new post on a CPT I want to automatically turn it also into a category to appear in another CPT. Example: I have a post type called "School Subject" and when I create the ...
0
votes
0answers
8 views

Using CSS, how can I remove a Woocommerce grid from a specific page that has ::before & ::after inserted in it [closed]

The specific page ID is 6329 I have tried different variations of the CSS below, but still can't get it to work! CSS used: .page-id-6329 .products.columns-3 { display: none !important; } and ...
0
votes
0answers
11 views

How to remove 2 carts on e-commerce site [closed]

I have an issue I recently noticed where on my E-Commerce site, my cart page is showing both the product and the subtotal twice. I would like to remove this, but am unsure what the issue is. Has ...
0
votes
1answer
14 views

Print Posts if Custom Field Value Date equal or greater than Today Date

I want to print posts if Custom Field Value (Expiry) formatted as 31 April 2021 is equal to or greater than today date (19 April 2021). I have tried with the below code but not working. <table&...
0
votes
0answers
18 views

WordPress response getting truncated (PHP-FPM + NGINX)

We have a website that used to work but is now giving a blank page when we try to edit a post. On debugging we found that the response sent back to the browser from the wp-admin/post.php endpoint is ...
0
votes
1answer
15 views

Settings API not saving

I've been through this code a hundred times and I just can't spot what's wrong with it. What it does: ✓ display options page, settings section, setting fields ✓ go through the sanitation function at ...
0
votes
1answer
16 views

Avoiding ACF get_field and returning to core Wordpress function

function slb_subscriber_column_data( $column, $post_id ) { // setup our return text $output = ''; switch( $column ) { case 'title': // get the custom name data $fname = ...
0
votes
1answer
19 views

AWS Lightsail Wordpress - connect to database on instance using mysqli

I have a wordpress website hosted on AWS Lightsail. On that website, I would like to use a shortcode to retrieve data from a database using mysqli. However, everytime the script that connects to the ...
0
votes
0answers
17 views

How do I target a single page to modify the comment form of only that page?

If I want to globally change the comment form for a theme I would use add_filter for "comment_form_default_fields". Then I might use add_action for "comment_form_logged_in_after" ...
0
votes
0answers
11 views

CSS for the Media + Text block

Looking for help writing CSS to customize the Media + Text block: I would like the header in this block to run the width so that it runs over the top of both the image and the text below it.
0
votes
1answer
8 views

About different margin in get_content

I'm on a WP custom Theme. In the page content (get_content) in need to have a margin left & right in all the content except (!) on images (figure tags) in fact. As *:not doesn't work (https://...
0
votes
0answers
15 views

Shortcode not working in CPT taxonomy

This shortcode is working for Post, Page, Tag, Category at the title but not print output in CPT Taxonomy. Also, I want this should also work for Description in all Post, Page, Tag, Cat, Tax. It means ...
0
votes
1answer
16 views

Display Author Registration Date

In author archive, I want to show author registration date in the following format: January 16, 2021 I have found this code: $user_ID = $post->post_author; echo the_author_meta( 'user_registered',...
0
votes
0answers
7 views

How to filter tags by category?

is there a way to add a custom filter in the Tags admin page? I'd like to filter tags by category. I saw plenty of custom filter for the POSTS admin page, like this one that filter posts by format: ...
0
votes
0answers
8 views

After restoration of backup, I am redirected to /wp-admin/install.php

Yesterday I tried restoring an older backup of my website through the panel of my hosting provider, following their instructions. Ever since, when I go to my site, it redirects me to /wp-admin/install....
0
votes
0answers
10 views

Wordpress hosted on AWS Route 53

I was contacted by some colleague of mine, to help him on how to remove off the WordPress site from the domain that's running on route 53,so that we deploy a new site,however,Having gone through a ...
0
votes
0answers
5 views

WooCommerce Default Sorting Filter Drop Down colours CSS [closed]

I have been trying to change the colours for the hovered default sorting filter on the woocommerce shop page but I cannot seem to find the selector in Google Chrome developer tools, I can't seem to ...
0
votes
1answer
21 views

How to deploy gutenberg on my own

I am new to Wordpress plugin programming and I do not understand how it is possible to create Gutenberg.zip from the Source code (zip) from this link. Note: Of course I could just download the already ...
0
votes
1answer
20 views

Cant update the product type [closed]

I am developing a plugin for one of my clients. However when my plugin is active I am not able to update the product type in woocommerce. I am using below code for the same add_action( 'save_post', ...
0
votes
1answer
11 views

Include Carbon Fields via Composer with Mozart

Coen Jacobs' Mozart is a tool to prevent namespace conflicts in Wordpress themes/plugins which utilize Composer for dependency management. It's similar to PHP Scoper but is described as simpler and ...
1
vote
0answers
18 views

why <?php wp_title(); ?> adds '»' symbol?

on last Wordpress when I wrote <?php wp_title(); ?> appear » symbol before the name of the page.. On my functions.php I wrote add_theme_support( 'title-tag' ); Thanks
0
votes
0answers
21 views

PHP Code Not Generating Results

I wanted to create a calculator on my WordPress website. But, my code is not generating results on the page after the form Submission. Please help, Thank you MY CODE: <form method="post" &...
0
votes
0answers
10 views

Changing wp_head to a different post/page

The problem in short: I need to be able to replicate the experience of a post on a static page, including title and meta tags. To do this, I need to set the pages post data to the post I'm cloning. ...
0
votes
0answers
9 views

user_metadata saved but deleted just before display the page

I made custom user fields on wp-admin/user-edit.php?user_id=42. For some reasons, two fields cannot be updated but I can modify an another custom user field which had already a value. I did a load of ...
0
votes
1answer
14 views

Why ever use add_post_meta, and not just update_post_meta?

I stumbled across this nice guide on Smashing Magazine on how to add a custom meta box. In there, I can see this code here, which has me puzzled: /* Save the meta box’s post metadata. */ function ...
0
votes
0answers
12 views

Wpbakery pagebuilder: How to create dropdown with custom taxonomy terms?

I have custom post type and custom taxonomy with it. Trying to create wpbakery pagebuilder's element with a dropdown of terms. Here is my vc_map function: vc_map( array( 'name' ...
0
votes
0answers
10 views

Autoupdate custom type post taxonomy after date set via metafield

I am launching a site with course listings. Using mostly Crocoblock JetEngine, I created a custom post type with a closing_date metafield to enter when the course applications closes. I also created a ...
-1
votes
1answer
19 views

Adding Custom HTML/CSS/JS code in specific page

I've written a HTML/JS code, it's something like a survey which consists of code like this: <div class="Question"> <h3>1. I have the knowledge of procedures needed for ...
0
votes
0answers
7 views

Rent or sell product with bundle products

we need Product Bundles with Rent or sell product option when we select Rent than date option will be show according dates price will be calculated and we select products bundles as well.
0
votes
0answers
20 views

How to render complicated shortcodes inside return

I hope you all having a great day. I'm developing a video player plugin with custom shortcodes and stuff but I'm having a problem with the shortcode render. Currently, my shortcode content is rendered ...
0
votes
0answers
11 views

A way to pre-fill block inserted in InnerBlocks

Is there a way (filter or some other means) to set default block content which is being inserted, depending on block context? I.e. I want for media-text block to show default content upon insertion in ...
0
votes
0answers
10 views

How to run An Ad management in a wordpress blog?

I run a tech blog in which I want to place the Ads of the companies who want to promote their products. So far I am doing manual HTML but it is tedious. I also need to define zones where I could run ...
0
votes
0answers
19 views

I am developing a plugin, in it user can specify that timer will run for like 30 minutes for a number of times

User can set that timer will be shown for 30 minutes at for example 1200 hrs on 17th April. and after that 30 minutes timer will run again for 30 minutes for like 5 times(number of times specified by ...
0
votes
0answers
10 views

Sub domain URL slash / missing after domain and before Post & page slug

WordPress page/page is not working after moved the file to subdirectory. URL structure domain.com/subdirectory/post1 is loading as domain.com/subdirectorypost1 - slash (/) is missing before post/page ...
-2
votes
0answers
14 views

Assign class to headings in ACF using functions.php [closed]

Besides of id I want to add class there //Adding IDs to headings function auto_id_headings( $content ) { $content = preg_replace_callback( '/(\<h[1-6](.*?))\>(.*)(<\/h[1-6]>)/i', ...
0
votes
0answers
26 views

User meta needed in query is serialized - how to unserialize safely?

I'm a complete newbie to php, and I'm trying to use a function suggested by FacetWP to pre-select the post results shown to users. (I'm using this method, rather than pre_get_posts as I want users to ...
0
votes
0answers
16 views

WP-API call function

I'm sorry, I speak a little English. My website API: https://examplee.tld/wp-json If visit my API please run my own plugin: https://examplee.tld/wp-content/plugins/myplugin/myplugin.php <?php /** ...
0
votes
0answers
8 views

WooCommerce Measurement Price Calculator plugin [closed]

How can I set a default value in inputs in the WooCommerce Measurement Price Calculator plugin?
0
votes
0answers
11 views

WP-API new variable

I'm sorry, I speak a little English. My website https://examplee.tld/wp-json return JSON: {"name":"examplee","description":"Just another WordPress site","...
0
votes
0answers
10 views

Gravity forms to local excel doc

Website uses gravity forms, we have a local excel document we use for business processes. We are aiming to either use an integration or an automatic regular download to bring form submissions into the ...
0
votes
0answers
15 views

Hi, Rare Featured Image Error

I have a problem with a website in WordPress. When I create a new post and try to upload the featured image the following happens: The featured image is uploaded to the server, and appears in the ...
0
votes
1answer
14 views

WordPress static home page pagination not working

I am trying to add the pagination on the home page, But it is not working. Can anyone help me to fix the issue? <ul class="xl-products grid- masonry"> <?php if(...
-2
votes
0answers
13 views

WP_Query->get_posts() [closed]

I used the Query Monitor plugin to find slow query on my WordPress site. The below-mentioned WP_Query->get_posts() takes about 18.6200 query time out of the total Database Query time of 19.6249. ...
0
votes
0answers
17 views

Function to recalculate shipping costs on subscriptions after renewal with Automatewoo

I've got a funky plugin that was custom made that adds a new random product from a group that a customer subscribes to. Problem is, that the shipping doesn't change depending on which product is ...
0
votes
0answers
16 views

Wordpress multisite wp-admin to many redirects

I have a WordPress blog set up with the multisite feature. there are two blogs setup on it with the following URLs # Main blog home https://example.com/blog/ # Main blog admin https://example.com/...
0
votes
0answers
14 views

Warning: Undefined variable $post in C:\xampp\htdocs\… after PHP upgrade

I use localhost for testing and debugging sites, before making changes to the live site. Because MySQL failed in XAMPP, I had to install XAMPP from scratch. I'm now using PHP version 8.0.3. ...

15 30 50 per page