Plugins are tools to extend the functionality of WordPress. This tag should not be used to mark requests for plugin recommendations, which are off-topic per the FAQ.

learn more… | top users | synonyms (3)

5
votes
3answers
139 views
+50

how to include other plugins css files in a shortcode?

I've coded a plugin that creates a shortcode, among other things. That shortcode expects a post_id parameter, it extracts the content of that post and it returns the filtered content of that post ...
1
vote
2answers
34 views

Output array into one table cell

I'm trying to output an array into one table cell. Here is a truncated version of what I have now: $prerequisites = get_post_meta($post->ID, 'opl_prerequisites', true); $output .= '<td>'; ...
-1
votes
0answers
11 views

Lightbox Plugins Not Working

I had a responsive lightbox plugin installed on our site and it's recently stopped working, I've tried installing other plugins but it seems no lightbox plugin will work. Does anyone know what could ...
-1
votes
0answers
17 views

Is there a page builder plugin that doesn't require itself to be installed [closed]

I'm wondering if there is a page builder that generates layout in such a way that the plugin itself can be removed and the layout will remain? e.g., I'm thinking if one has built a bunch of pages ...
-4
votes
0answers
16 views

What is difference between bldg in WP (hosted on WP Exchange) and something like Elegant Themes?

New to WP...can someone explain the difference between building a website in WP (hosted on say WP Exchange) vs. bldg the site in say Elegant Themes using a Divi Page Builder? Are there any security ...
0
votes
1answer
12 views

Symlink a plugin in local development, works but got Debug error message - Windows 10

I read that WP 3.9+ supports symlink (Article here). So, my plugin resides in C:\Github\my-plugin. while my project is at C:\Project\my-site. I successfully symlink it by using this command (run as ...
-6
votes
1answer
33 views

How can I add “table of contents” in any post? [closed]

I want to add content menu in any post like Wikipedia Is there any built-in tool for this job, Or should I add it manually?
-3
votes
0answers
20 views

Rewrite rules for EDD product page

I am using easy digital downloads plugin to sell product and having just 2 categories: – plugins – themes Now, i have changed 'download' slug with EDD_SLUG function as 'product' Ex. ...
0
votes
1answer
18 views

Using activated_plugin to run code

I am using Site Origins Page Builder plugin and want it to install when my theme is installed, so to do that I am using TGMPluginActivation. This correctly installs and activates a bunch of plugins. ...
0
votes
0answers
26 views

Reorder posts in a custom Meta Box

I have a list of Posts (of a Custom Post Type) that is displayed in a Meta Box for a different CPT. In this Meta Box I need to enable the user to reorder the posts. Currently, the list of posts is ...
2
votes
1answer
16 views

What user roles should have wp_unique_post_slug_is_bad_flat_slug filter applied?

I have a plugin where I need to reserve some slugs so I am using the filters wp_unique_post_slug_is_bad_flat_slug and wp_unique_post_slug_is_bad_hierarchical_slug. I apply them like this on my plugin ...
1
vote
1answer
16 views

how an array index could be a file path

In the function below at the end the variable $plugin_path is used as an index of an array. How could it be possible since some lines above we have the call to a function which returns a string (see ...
1
vote
2answers
27 views

How to add an image from web-link?

I currently have this code from a plugin. [imdbi meta_name=poster] This cache an Image Link, and it simply display the link, I want it to display it as an image. Is this possible?
0
votes
0answers
16 views

Display admin notice on category creation

I'm trying to display a custom admin notice when admin creates new category but can't make it work. My code so far is: function pippin_admin_notice() { echo '<div ...
-1
votes
1answer
33 views

Is there a WP-Plugin to convert PNG to GIF? [closed]

I want to upload PNG-files, which convert wordpress in GIF-files. Is there a WP-Plugin to convert PNG to GIF? Thank you
0
votes
0answers
19 views

Plugin - overwritting entire non-pluggable function

In order to achieve what I want to do with my plugin I need to modify several functions inside comment.php and comment-template.php ( for instance some code lines like if ( is_user_logged_in() ) : ) ...
3
votes
1answer
35 views

What exactly does $wp_filesystem->abspath() return?

The real problem I have when using the $wp_filesystem is defining the correct paths. In the documentation of the filesystem the path (for example for the plugins directory) is usually set like this: ...
-6
votes
0answers
35 views

Polylang and permalinks in my WordPress site

I install Polylang plugin for multilingual WordPress website and for better SEO I want to make different permalinks. This is the link for my site: http://www.elefantti.iq.pl/ What I want to do is ...
0
votes
0answers
20 views

Why a WP_Query instance using 'tag' doesn't work?

everybody. I'm developing a small plugin and I need to fetch some posts with a very simple query: $args = array( 'tag' => $tag ); $fc_query = new WP_Query( $args ); The point here is ...
0
votes
0answers
9 views

Incorporate Co-Authors Plus template tags into Unpress theme

I am not quite familiar with coding and need help. Currently, I am managing a website that uses UnPress theme on Wordpress and installing co-author plus pluggin. I would like to incorporate the ...
0
votes
1answer
16 views

Add custom columns in custom post type browse page

I made a plugin which adds a "member" custom post type. I customized the edit view (with the editor hook) to get only the fields I want and store them in the database. I have fields like "name, ...
-1
votes
0answers
9 views

Elements overlapping each other using isotope and YIT infinite scroll

i am using YIT infinite scroll plugin along in isotope (masonry) layout. New posts are called when i scroll down the page. The problem i am facing is that new posts are getting overlapped over ...
0
votes
0answers
8 views

Hook into Post Exirator's expiration code

I need to run some code when a post from a custom post type is set to draft, which occurs automatically with the Post Expirator plugin. My code is set to run on the publish_to_draft action, however I ...
-3
votes
1answer
49 views

Embed php code in custom field of a plugin [closed]

I am using this plugin https://wordpress.org/plugins/emailcoauthoronpost/ in my website. This plugin shoots an email to the author of the post with a link to my website. But I need to send the ...
-1
votes
0answers
19 views

I have created custom image widget but image is not showing in the sidebar of my theme [on hold]

Here is my code, add_action( 'widgets_init', create_function( '', 'register_widget("pu_media_upload_widget");' ) ); class pu_media_upload_widget extends WP_Widget { /** ...
-3
votes
0answers
27 views

restrict access to pages based on geolocation [closed]

I've seen this question asked here before but have yet to find the answer: I'm making a site for an on-demand delivery store with a limited delivery area. It is built with woocommerce and I had a ...
0
votes
1answer
21 views

How do I disable Photon on a non-premium WordPress site?

I have a site with an image in the sidebar hosted on an external server. I change this image every so often on the external site, but the name of the file stays the same. Recently, I've noticed that ...
0
votes
0answers
35 views

How to include JavaScript script only on specific page [duplicate]

I am creating my own widget. I need to use custom css and js files. I have used wp_register_style`wp_enqueue_styleandwp_register_script\wp_enqueue_script` functions in order to register custom styles ...
-1
votes
0answers
25 views

Insert Text into TinyMCE from JQuery

I wrote a WordPress plugin that adds a button next to the "Add media" button, above the TinyMCE editor. Here's the relevant portion of my plugin: <?php // Handle the shortcode function ...
-2
votes
0answers
29 views

How to move a caller code from head to plugin?

For my theme option, I place this code on my header.php: <?php $yer_options = mytheme_get_options(); ?> to call this function from function.php: function mytheme_get_options() { ...
-3
votes
0answers
21 views

Change the content of my post and save [duplicate]

How would a function to edit all posts put a link at the end and then save. I need to edit the posts to put the link. It can not be otherwise
1
vote
0answers
24 views

Disable plugins on cron and ajax page

I want to disable few wordpress plugins on my cron and an ajax page. I have already tried option_active_plugins filter but it's not working. I have checked and found most of the people say that ...
0
votes
2answers
46 views

Surviving Wordpress and plugin updates

In the phase of developing a new wordpress-based site, I'm evaluating also future pitfalls such as upgrades. Unfortunately, there's no guarantee that a third party plugin will not be discontinued. But ...
0
votes
1answer
22 views

How to get all posts belongs to a user between a certain date

I am writing a plugin for my company so I need to get all posts belongs to a user between a certain date which is given by another user. Then I want to count words for each post and finally add them ...
0
votes
0answers
12 views

change template by permalink endpoint via plugin

I'm trying to change template using this code: add_filter( 'query_vars', 'add_query_vars'); function add_query_vars($vars){ $vars[] = "photos"; return $vars; } function ...
0
votes
0answers
19 views

Multi-tier Categories by post type?

We've been using CPT UI to allow us to create segregated categories for different post types. Unfortunately, this plugin only allows single-tier category view in the admin area. What I'm after is ...
3
votes
2answers
338 views

Get php var inside javascript file (making plugin)

I was making a plugin and I have a javascript file where I want to take some options saved in the database to show well the function. So I have this: function wp_home(){ wp_enqueue_script( ...
4
votes
0answers
47 views

Development of a Wordpress Search Plugin - Best Practices

Searching for around two days to find an answer to my question, I finally registered for this StackExchange. :) My Question is not simple, so I need to start at the very beginning. But to give you an ...
1
vote
1answer
40 views

Suggestions on Approach to New Plugin I'm Stuck On

I'm a newbie plugin developer, and I've had an idea for what I though would be a simple to build debut plugin, but I seem to have reached a brick wall with it and wonder if anyone can suggest some ...
0
votes
0answers
16 views

WordPress loop by three meta values with random order

We have three custom fields with names plan_name1,plan_name2 and plan_name3. Need to check if these meta keys has values (1,2,3) OR (2,3,1) OR (1,3,2) OR (2,1,3) OR (3,2,1) OR (3,1,2) We mean ...
0
votes
2answers
29 views

Create Custom Post type that uses Page.php template

I am creating a plugin that registers a custom post type, and I want it to be displayed using the theme's page.php template, rather than the post.php. I set the hierarchical flag when I register it, ...
0
votes
0answers
24 views

Customizing a category archive page through plugin

I have created a plugin that adds a custom post type called "Activities". This post type's archive shows all the categories, and then the categories each have a page that includes the posts contained ...
0
votes
0answers
14 views

install problem can't find wp-load.php file

This is probably a simple problem, but can't figure it out... 1) I installed the wordpress file directly under the xxxx directory; wp-admin, wp-content, wp-includes are all within wordpress file. 2) ...
0
votes
0answers
14 views

Multi-step Frontend Filtering to Reveal Content

I'm not even really sure the best and easiest way to go about doing this - or what the right verbiage is to properly describe what I'm wanting to do. On my site I'm looking to change this selection ...
0
votes
2answers
42 views

How to quickly reorder posts in the admin panel that will persist for the wp-api

I generally use the Intuitive Custom Post Order plugin for any WordPress sites I work with so clients can order their posts visually. For this project, I'm using WordPress as an admin panel and ...
0
votes
1answer
21 views

What goes into wp_postmeta and why?

we are using WordPress in a site that has Places and eventsOn running, however we notice that sometimes the newly inserted place data goes into the wp_postmeta table others it doesn't... Searched for ...
0
votes
0answers
17 views

Escaping and sanitization

I have created a custom metabox for a certain plugin - events CPT. In it I can add talks by event days, with images, speaker names, descriptions, titles and times. So all either input fields or ...
-1
votes
0answers
29 views

Headers already sent error when activation hook

This code : <?php class Planner_plugin{ public function __construct(){ register_activation_hook( __FILE__, array( 'Planner_plugin' , 'install')); ... } ...
0
votes
1answer
31 views

function of parent not working in childtheme

I have a plugin used on a parent theme which uses shortcode. The plugin (shortcode) works on the parent theme but when I switch to child theme it no longer works. I've only added the child theme code ...
3
votes
3answers
89 views

PHP Script to Download Latest PLUGIN Version

I use the following code in my PHP script to automatically download the latest version of WordPress... $wordpress_zip_file_url = 'https://wordpress.org/latest.zip'; file_put_contents("wordpress.zip", ...