All Questions

Filter by
Sorted by
Tagged with
1
vote
1answer
6 views

How to forward all requests starting with a specific folder name to the same folder

In my Wordpress website main directory, I created a folder servers, which contains two files .htaccess & index.php. In the .htaccess file, I add those lines to redirect all requests to that folder ...
0
votes
0answers
2 views

Wordpress Configuration with SELinux on CentOS 8

My VPS is running with CentOS 8. I installed there Wordpress for my website. After finishing setup of my website, I cannot download/update plugin or theme. I got a solution by disabling SELinux for ...
0
votes
1answer
538 views

How bad is flush_rules() on init hook?

According to the Codex: [...] This function can be extremely costly in terms of performance. It should be used as sparingly as possible - such as during activation or deactivation of plugins or ...
0
votes
0answers
7 views

Migrate ProcessWire to WordPress

Is it possible to migrate content from Processwire CMS to WordPress? If so, any ideas? Any tools? I've spent a good amount of time researching but haven't found anything. I've opened the ProcessWire ...
0
votes
0answers
10 views

Adding per-unit price after product line price in Woocommerce

I'm trying to get my WooCommerce price per unit . Prices added according per package (example:4000$) but customer dont know how much per unit,If a package have 20 i wanna show next to price (20$ per ...
0
votes
1answer
15 views

Move static site to WordPress

I want to move my website https://mysushi.ph/ to a simpler platform like WordPress so I can make small changes myself and don't be dependant on developers (e.g. title meta changes for SEO, posting ...
0
votes
0answers
2 views

creating custom search page

I'm reading about how to create a custom search page. It's not clear for me how to proceed, in the wordpress documentation I've read that I can't use the name search.php for a search page because it's ...
0
votes
0answers
4 views

Fill Drop-down menu of Contact Form 7 using PHP

I want to populate the drop-down menu items of the CF7 from another database. The reason for this is that there might be a large number of items that might dynamically change every week. Adjusting the ...
2
votes
1answer
14k views

Get posts with ajax

I want to get posts with ajax by click function. Jquery $(".get-posts").click(function(){ $.ajax({ type: 'POST', url: '<?php echo admin_url('admin-ajax.php');?>', data: { ...
0
votes
0answers
7 views

Building a Featured Gallery component for Gutenberg

I'm building a Featured Gallery component for Gutenberg. As a guide, I'm using the existing Featured Image component from Gutenberg. Basically, instead of storing a single image id, the component ...
0
votes
1answer
814 views

Types plugin custom post add_action hooks

I'm using the wp-types plugin to create a custom post type. I'm developing my own plugin which I need to fire whenever a post of my custom post type is updated. Right now add_action( 'save_post', '...
0
votes
1answer
7 views

File ownership for file tree php user ID - Folder permission 775

I have the same issue as the below topic, where all my folder are set to 755 but I am unable to run updates or upload new media due to folder permissions. Once I set it to 775, the problem is resolved....
0
votes
1answer
36 views

Why does wordpress generate more thumbnails than the 3 standard sizes?

If I upload an image in Wordpress, it usually generates more images sizes than what I have indicated in my settings -> media (small 150, medium 300, large 1024). For example, if I upload a 4K image,...
0
votes
0answers
9 views

Google photos integration. Can view images in media library but not insert to post [closed]

In Gutenberg post-editor. I select Gallery-block--> Select images --> Google photos. All my Google photos are now visible. When I select one or multiple images and click insert I get "...
0
votes
2answers
424 views

If Child or Grandchild of Page

I'm serving a different header in Wordpress depending what section you are within the site, 'residential' , 'business' or other by using the following code. Although i need to extend it to work with ...
0
votes
0answers
6 views

TinyMCE on frontend stylle not working

I use TinyMCE advanced on my Wordpress website. My logged-in users have the ability to fill forms with WYSIWYG fields. I don't understand why some styles are not applied on those fields while it ...
0
votes
1answer
529 views

How to fix 404 error in pagination in categories of woocommerce with common url base /shop/?

I can’t find a solution — unification of url bases of products and categories in woocommerce. I have found only one working solution: In Settings -> Permalinks: Category base change on shop Custom ...
33
votes
2answers
73k views

How to get the path to the current theme?

This code is used to get the directory of the current plugin: plugin_dir_url( __FILE__ ). What should I use to get the directory of the current theme?
0
votes
1answer
618 views

Why are previous_post_link/next_post_link skipping some posts?

I have a single page template for one of my custom post types. Are the top of this page I have... <?php previous_post_link('%link', 'Prev Project'); ?> <?php next_post_link('%link', 'Next ...
1
vote
1answer
608 views

How to dynamically generate wordpress editor on frontend?

I want to initialize the wordpress editor dynamically on frontend. I have tried to include the following scripts: wp_enqueue_script('editor'); wp_enqueue_script('media-upload'); wp_enqueue_script('...
1
vote
2answers
61 views
+50

Redirect Single Post from CPT to a specific URL

I have a domain.com and subdomain materials.domain.com At the domain.com scope I created a custom post type called resources and a portfolio grid (using elementor) to display the resource's feature ...
0
votes
1answer
803 views

Work and Display a Custom Post Type as a normal Post

I've created some Custom Posts for my Wordpress page and I can work fine with them. I can create a new one, edit it and display it in "archive-custom_post_type_name.php" and many more things. I can ...
0
votes
1answer
19 views

How to retrieve category NAME instead of ID in a function with a taxonomy custom field?

I'm trying to change the post title (both back-end and front-end) for a specific post type through custom field. The custom field I'm using is a taxonomy field where you I choose from different ...
0
votes
0answers
9 views

Migration from environment to master Wordpress

Is there any way to migrate the project from one environment to another? You mean exactly the difference between them? Let's say I have a plugin in dev that is not in the master, can I somehow ...
0
votes
1answer
17 views

How to remove gap/space between widget and layout child in Elementor?

in Elementor, by default if we add layout inside an widget, we can see there's a gap or space between widget and layout (widget's child), as seen in below picture: other example: another example: ...
1
vote
1answer
518 views

gravity forms file upload field

I have created sample form using gravity forms which has some fields with file upload field. when form loads, it will check for existing data and if there it will populate it from database. Once ...
0
votes
1answer
32 views

Let any visitors delete a post if they know Id nr & password?

I've got only one function left that I need to solve (if it's solvable). I've got a frontend post system for unregistered users. But there are no way for the users to delete a post if they later want....
1
vote
1answer
905 views

Adding user data to an existing user_id

I'm using phpMyAdmin to add some new user records to the existing users within a WordPress database. The database is for a WordPress Multisite network. I had to migrate my old WP site to the new site,...
6
votes
4answers
13k views

Empty search input returns all posts

So today I've decided to implement a search form onto my site that obviously returns a result when the user searches for it, but I've run into a little problem. My Problem When the user searches for ...
38
votes
13answers
28k views

Sort on meta value but include posts that don't have one

I've been modifying the built in WP search using the pre_get_posts filter, allowing the user to sort the posts (including a bunch of custom post types) by different fields. The problem I'm having ...
4
votes
4answers
6k views

Way to include posts both with & without certain meta_key in args for wp_query?

EDIT 2: Rather than figuring out the real solution I've decided to use a workaround, and am simply setting the default value for book_in_series to '0'. Thanks to @eddiemoya for all his the time he ...
0
votes
0answers
11 views

WordPress lightbox plugin with Ajax functionality [closed]

I would like to approximate the lightbox/Ajax behavior on this page. The site uses a (no longer supported) theme by TommusRhodus along with the Ebor Template Builder plugin. The template creates a 4-...
0
votes
2answers
555 views

add_rewrite_rule() driving me crazy, rewrite not working when analyzer says it should

I have a special situation and need some help achieving the final step. Background: When I access mydomain.com/category/postname, I get the post as expected. When I access mydomain.com/category/...
0
votes
0answers
7 views

What, if any, tools exist to establish SSO between WordPress and a MediaWiki?

I would like to have a MediaWiki on a directory within a WordPress installation. Are there any tools? I searched plugins and found no obvious candidate. If there are not existing solutions, how should ...
0
votes
2answers
723 views

Remove actions/filters that are set with create_function()

This theme I was handed from another dev company is littered with add_action/filter( 'hook/filter', create_function( '', 'return blah('blah')' ); We will be moving this site to a server running php 7....
1
vote
1answer
580 views

re-register custom post type with custom capabilities

I have created custom post type as below. register_post_type( 'connector', array( 'labels' => array( 'name' => __( 'Connectors' ), 'singular_name' => __( '...
0
votes
1answer
557 views

Wordpress Pagination Custom Rewrite Rule for Pages

Hi I am trying to run a pagination rule for the following for some custom pages that are getting data from an external api the current structure is like and it working fine http://domain.com/?...
0
votes
2answers
17 views

How to fix “Object of class WP_Term could not be converted to string”?

I basically want to loop through each post I have and get the taxonomy/category id. After that I want to output those id's into a single string (not as a numeric value), separated by a space. I get ...
2
votes
3answers
6k views

WordPress template_include filter not working properly

I am working on a plugin. The plugin make custom post type "product". First i use template_redirect action for redirection to single and category pages. Here is my template_redirect code: add_action(...
0
votes
1answer
17 views

IF statement not working - Any suggestions?

So I have a function which counts the amount of customer orders. I want to show a congratulations modal that appears when a customer hits a specific amount of orders. All of my code is working fine, ...
0
votes
3answers
738 views

How to delay display of page elements until enqueued script has injected html

I am enqueuing some javascript that injects SVGs into my page's DOM (called SVGInjector); it works great except for one thing: there is an undesirable "blink"/shift of elements on my screen ...
0
votes
1answer
1k views

Custom Post Type and single-posttype template

I created CPT topic function wpse100_create_cpt() { register_post_type( 'topic', array( 'labels' => array( //..... ), 'public' => true, '...
62
votes
7answers
38k views

Custom Post Type Templates from Plugin Folder?

I'd like to offer my custom post type as a Plugin, so that people can use it without touching their theme folder. But custom post type templates -- such as single-movies.php -- reside in the theme ...
0
votes
1answer
10 views

Windows-hosted new site shows no preview: “Future home of something quite cool.” message is displayed

I added a theme and made a sample home page. What could cause the site to display no previews or even display no changes when published? Note: I did my best to search similar previously-asked ...
0
votes
1answer
16 views

Headers already sent warning in Admin source is media.php 3140

After years of running fine, I am suddenly getting this dreaded message after updating to 5.42. However it only happens in the Admin: Warning: strpos() expects parameter 1 to be string, array given in ...
-1
votes
1answer
11 views

How to load css file in my menu in wordpress

Anyone know how to load css file in my menu in wordpress. use this but it didn't work function wmt_theme_style() { wp_enqueue_style( 'bootstrap-styles', get_template_directory_uri() . '/css/...
0
votes
3answers
826 views

Add text specifically to order-proceessing-email in WooCommerce

I am trying to add some text to the customer-order-processing email from WooCommerce, and it should ONLY be added in this particular email and ONLY if chosen payment method is Paypal. I have come so ...
3
votes
3answers
7k views

How Do I Programmatically Force Custom Permalinks with My Theme?

I'm making a custom theme. It's a highly specialized theme to make WordPress into like an application rather than a CMS system or blog. For instance, a Dental Office Scheduling System (with CMS and ...
0
votes
1answer
1k views

Highlighting Active Page in Navigation when Viewing Child Pages

I am trying to do something seemingly simple. I have invested a good amount of time researching and have not been able to resolve this one on my own. I would like to have the "Portfolio" page of my ...
2
votes
2answers
27 views

Importing New Posts from Live Site into Local Dev Site

I'm currently developing an updated version of a live site in a local environment. It's a very large site and the local dev site is using a entirely new theme without many of the live site's plugins ...

15 30 50 per page
1
2 3 4 5
2092