LogoLogo
Highlight and ShareGet QuotesDLXDLX PluginsMediaRon
Highlight and Share
Highlight and Share
  • Welcome to Highlight and Share
  • Getting Started
    • Installing the Plugin
    • Finding the Plugin's Settings
    • How Highlight and Share Works
    • Configuring the Display Settings
    • Enabling the Social Networks
    • Enabling Shortlinks
    • Advanced Selectors
    • Changing Themes and Appearance
      • The Theme Preview
      • Reordering the Social Networks
      • Choosing a Theme
      • Configuring a Custom Theme
  • Inline Highlighting
    • What is Inline Highlighting
    • How to Add Inline Highlighting to Text
    • Configure Inline Highlighting
  • Image Sharing
    • What is Image Sharing?
    • Configuring Image Sharing
  • Click to Share Shortcode
    • Shortcode Parameters
    • Custom Shortcode Themes
  • Click to Share Block
    • The Click to Share Block
    • Configuring the Block Editor Settings
  • Emails
    • Email Sharing
    • Email Admin Settings
  • Developers
    • Available Social Networks
    • Actions and Filters
      • Disable or Enable Text Selection
      • Changing Labels and Tooltips
      • Disabling CSS
      • Enabling or Disabling Social Networks
    • GitHub Repo
  • Quick Links
    • Highlight and Share Home
    • Highlight and Share Download
    • Support
    • MediaRon Home
    • DLX Plugins Home
    • Brand Assets
Powered by GitBook
On this page

Was this helpful?

Export as PDF
  1. Developers
  2. Actions and Filters

Enabling or Disabling Social Networks

These are the filters you can use to enable or disable social networks.

PreviousDisabling CSS

Last updated 10 months ago

Was this helpful?

There are filters for each social network where you can enable/disable each network programmatically.

An example of hiding a social network via code would look like this:

Filter: has_show_twitter
<?php
add_filter(
	'has_show_twitter',
	function( $show_twitter ) {
		if ( is_page() ) {
			return false;
		}
		return $show_twitter;
	}
);

Available Filters

Each filter returns a boolean:

  • has_show_twitter

  • has_show_facebook

  • has_show_linkedin

  • has_show_email

  • has_show_copy

  • has_show_reddit

  • has_show_telegram

  • has_show_whatsapp

Filters for Hiding/Showing Social Networks