Articles of plugins

Send post changes to set email addresses (not users or subscribers)

What I have I am using the “The Events Calendar” plugin on my site to coordinate a team of employees. I want to be able to send an automated email containing the body of an event post (post-type is not $post, but $tribe_events instead) each time it’s updated, but only to the employees concerned by […]

Enable Shortcode for Custom Wordress Widgets

I would like to use a shortcode for a WordPress Widget. I’ve tried inserting add_shortcode(‘test_widget’, ‘test_load_widget’); at the bottom, but when I tried to load it by calling [test_widget] in a post, it doesn’t seem to do anything. I’m new to shortcodes and plugins. Kindly please assist. <?php // Creating the widget class test_widget extends […]

Create a custom page template inside my wordpress plugin

I’m developing a WordPress plugin and I want to create a file to where I want to redirect the user to show some information. I know that a perfect solution for this is using WordPress custom pages. I’ve used it in the past and it was very useful. The problem is I can not use […]

Get list of sites that uses specific plugin or theme

One of most time saving in mutisite is to know where some plugin or theme is used. So i start searching and did not found any solution for this. What i need is help to get list of sites that uses specific plugin or theme. i thought the best will be to add link near […]

WordPress Custom Menu Admin helper plugin

I’m creating learning system in WordPress and I have a lot of pages instead of post. Those pages needs to be in a custom menu with two sub items. It gets really confusing to add pages to the menus because the add to menu section is so tiny. Also some of the sub-pages doesn’t show […]

Table is not created in WAMP

I don’t know where the mistake is. My code is not creating a table in WAMP: function subscribe_table() { global $wpdb; $table_name = $wpdb->prefix.’_databasesubs’; $charset_collate = $wpdb->get_charset_collate(); if ( $wpdb->get_var( ‘SHOW TABLES LIKE ‘. $table_name ) != $table_name ) { $sql = “CREATE TABLE $table_name ( sno int(2) NOT NULL AUTO_INCREMENT, email varchar(25), name varchar(25), […]

Deregister scripts from plugin

I have an own class that deregisters all scripts and styles and creates 2 cached files one for scripts and one for styles that is registered in the end. This runs inside theme, my problem is that I cant move it into plugin, as soon as i move it into plugin it wont work. currently […]

How to request admin-ajax.php correctly when wordpress URL and site URL are different?

When site_url() and home_url() are different, how a request should be directed to admin-ajax.php (both in front-end and admin)? Using A. admin_url(‘wp-admin/admin-ajax.php’) or B. home_url(‘wp-admin/admin-ajax.php’) Usually method A is used. However for some websites this request gives error 404 in front-end. Method B does not work when wordpress is located in some sub-directory with respect […]

Get Current user email as a return string value

if(strpos($query, ‘%get_email%’) !== false){ $query = str_replace(‘%get_email%’, get_the_author_meta( ‘user_email’ ), $query); } Okay so am trying to make a MySQL query and in the plugin I am trying to add a shortcode %get_email% but anyway its not returning any email in the actual query. Like select* from from tablename where email=’%get_email%’; Any idea on how […]

how to incude logo in contcat form 7 email

I am using contact form 7 plugin. how to include logo in emails sending to user and admin. I am new in word press.