How to enable a wordpress plugin only on blog posts? - php

I would like to enable a wordpress plugin (this one: https://wordpress.org/plugins/chp-ads-block-detector/) only on my blog posts (and not on the whole site), can you help me please?
I have tried with adding a plugin to manage plugins as WP manager etc, but they allow to disable it only on pages and posts so the plugin still appears on woocommerce product pages.
At this time I don't want to create a subdomain for blog posts.
Is there a code that I can add to function.php? Or something else to do please?
Thank you,

You can use this plugin for disabling another plugin in certain conditions, in your case you can set the plugin to disable the https://wordpress.org/plugins/chp-ads-block-detector/ plugin everywhere except on blog posts

Related

Duplicated WordPress plugin activation issues. How to activate both plugins?

I have duplicated a WordPress plugin. Both plugins are working as I need, but the problem is that I can only activate one plugin at a time.
If one plugin is activated then the other plugin activation is not working without giving an error message. (I already have tried WP_DEBUG etc)
The plugin is a custom plugin so can't share the URL or name of the plugin.
First, you need to download the whole plugin and study the core functionality, change the plugin name to a new one, change all the variables used inside it to a new one.
Or you can check this link, there are some plugins
http://wpkicker.com/duplicate-plugins-wordpress/

Can I add my own panel to the widget page in wordpress using a plugin

Is it possible to develop a plugin that is able to add a panel to the widgets page? And could someone point me to a few articles to get me started if there is? I need to achieve something similar to the customisable sidebar plugin where a panel was added via activation of the plugin.
Thanks

Add back-end WP plugin to front-end template

I just need to be pointed the right direction here, I don't expect the exact answer.
Basically, I got a wordpress plugin for woocommerce. It adds a new metabox with options to choose from within the 'add new product' area in admin back-end.
Plugin here https://wordpress.org/plugins/woocommerce-incremental-product-quantities/
My theme with other plugins allow me to add new products from the front-end and so I would like to use this plugin also from the front-end.
So how can I bring the plugin to my theme template to be able to choose its option from the front-end? Or what steps to take that I could google some tutorials and take it from there?
I haven't tried anything just yet, I just have no idea where to start.
Any help is appreciated

Issue with wordpress plugin

What may be reason when i am using multiple plugins then some plugin showing in widget sidebar
but some or not like
plugin "wp-auctions" is showing in widget sidebar but
plugin "ultimate-auction" is not showing.
I am using "twentythirteen" theme.
please help me.
Well, take a look at this, http://wordpress.org/plugins/ultimate-auction/installation/
It seemed ultimate-auction is used on a page, not as a widget
Try create a new Page:
Enter this text "[wdm_auction_listing]" as a shortcode inside this new
page and publish it.
Then visit this page to see the auction list.
Goto the Admin page, choose Appearance->Widgets, check Available Widgets on the left side, ultimate-auction might be there, and you need drag it to the Main Widget Area on the right side.

How to add a widget by its shortcode on Wordpress posts / pages?

Is there any way we can assign a shortcode to already created widget and later use that
shortcode in our specific posts and pages to show that widget instead of trivial method of
showing widgets in sidebar ? I googled about this stuff didn't find anything relative.
Any suggestion would be welcome!
Yes, You can call widget in Post/Page using shortcode. Follow this link to establish a system like that.
http://digwp.com/2010/04/call-widget-with-shortcode/
This might be relevant.
Widgets on Pages
https://wordpress.org/plugins/widgets-on-pages/
Observations and two questions:
This plugin allows insertion of 1 or "sets" of widgets via shortcode into pages, posts, (and Custom post types?) and it will also save a list of configured shortcodes~sets. VERY handy!
When comparing its features to the plugin Widgets Shortcode, that plugin does not provide a means to save "sets" of plugins, rather it seems to focus on inserting widgets individually. In fact, it inserts the shortcode for each widget in the bottom edge of each widget and it assigns different shortcodes to each instance of a widget. Also nice.
https://wordpress.org/plugins/widget-shortcode/
I like the granularity Widgets Shortcode provides with an individual shortcode for every instance of every widget. When running it and your plugin simultaneously even widgets saved in your plugin's "sets" are still assigned individual shortcodes. Those individual shortcodes allow using a specific widget out of a "set" in a different location without needing to create an additional instance of the widget as it appears would be required with your plugin.
Incidently, for anyone who wants both of these features, these two plugins play very nicely together on one of our WP 4.0 Multisite installations with 50+ sites and even on a site using the theme Make.
FYI: We also tested amr shortcode any widget, but had some issues with it and rather than troubleshoot it we moved on. To be fair, we were testing quickly on a site with over 160 plugins active. Yes, 160 plugins. I know, I know, but think about it for a minute. Any plugin that you can activate into that mix of 160 plugins and it does not break things or introduce issues, then it suggests a good probability of it being troublefree to use.... well at least until the next round of WP updates. :)
We also tested Widgetize Pages Light and its pro version Sidebar & Widget Manager and had no issues with either. However, if only seeking to insert widgets into pages and posts these plugins seem like overkill as they provide additional page layout functions that may duplicate theme functions and/or other plugin functions.
I was looking for a "widgets in pages" plugin that provides a TinyMCE button to insert the widget shortcodes.
Can anyone recommend one that has a TinyMCE button to insert the widget shortcodes in pages, posts and CPTs?
Ultimately I selected Widgets On Pages as having the best combination of features for this application. Its simple to understand, easy to use, versatile and has worked flawlessly for us, even along side Widgets Shortcode.
You can do it by wordpress WordPress Widgets Shortcode plugin, you can Embed any widget area/dynamic sidebar to your pages/posts using this plugin as a shortcode
edit widgets in wp :
file in # wp-includes/widgets.php: register_widget()
in source view sample :
public function register( $widget_class ) {
$this->widgets[$widget_class] = new $widget_class();
}

Categories