Enable Subtitles Wordpress Plugin - Rating, Reviews, Demo & Download

Enable Subtitles Wordpress Plugin - Rating, Reviews, Demo & Download
No ratings yet
Free
Follow for free plugins, new theme releases and theme news

Plugin Description

Creates a the_subtitle function for use in WordPress posts and pages, such as for H2 subtitles, that can be called in template files or shortcodes.

Our related OSS projects:

The Long Version

  • Subtitle functions

There are two functions declared only if they do not exists:

function the_subtitle($before = ”, $after = ”, $echo = true) { …

It uses the same WP style allowing parameters to add content before and after the subtitle, and also if shows the subtitle or just return its value.

The next function only retrieves the subtitle data:

function get_the_subtitle($post = 0) { ..

Optionally you can specify the post identifier (the same argument of WP get_post function).

This function implements a filter to modify the result from theme or plugin code (see last section).

  • Subtitle hooks

They are not standard but provide the same functionality of the subtitle functions:

do_action(‘the_subtitle’);

apply_filters(‘get_the_subtitle’, 0);

  • [the_subtitle] shortcode

Added a simple shortcode handler connecting directly to the get_the_subtitle function. It can support an optional parameter “post” indicating the post Id.

  • Direct post_subtitle property

When retrieving data from core WP functions get_post or get_posts (or from an object of the WP_Query class), the results incorporate on each post the property post_subtitle with the value returned from the get_the_subtitle function, e.g.:

$post = get_post();
echo ‘‘.$post->post_subtitle.’‘;

  • Admin area

Finally I added support for the correct tab key order, it was necessary to create a new js file.

Ignored the screen-reader-text accesibility feature.

  • Custom helper filters

In addition the plugin exposes three custom plugin filters:

Modifies the subtitle value:
add_filter(‘post_subtitle’, ‘my_post_subtitle_function_handler’, 10, 2);
function my_post_subtitle_function_handler($subtitle, $post_id) {
.. do something and return modified $subtitle
}

Avoid to remove HTML when save the subtitle, by default it is stripped, but you can change it:
add_filter(‘post_subtitle_strip_tags’, ‘__return_false’);

Avoid to escape HTML when shows the subtitle by the_post function or via shortcode, by default it is escaped, but you can change it:
add_filter(‘post_subtitle_esc_html’, ‘__return_false’);

Compatibility

This plugin has been designed for use on LEMP (Nginx) web servers with PHP 7.0 and MySQL 5.7 to achieve best performance. All of our plugins are meant for single site WordPress installations only; for both performance and security reasons, we highly recommend against using WordPress Multisite for the vast majority of projects.

Defined Constants

The following defined constants are supported by this plugin:

  • define('DISABLE_NAG_NOTICES', true);

Plugin Features

  • Settings Page: No
  • Premium Version Available: Yes (SEO Genius)
  • Includes Media (Images, Icons, Etc): No
  • Includes CSS: No
  • Database Storage: Yes
    • Transients: No
    • Options: Yes
    • Creates New Tables: No
  • Database Queries: Backend + Frontend (SQL Queries + Options API)
  • Must-Use Support: Yes (Use With Autoloader)
  • Multisite Support: No
  • Uninstalls Data: Yes

Nag Notices

This plugin generates multiple Admin Notices in the WP Admin dashboard. The first is a notice that fires during plugin activation which recommends several related free plugins that we believe will enhance this plugin’s features; this notice will re-appear approximately once every 6 months as our code and recommendations evolve. The second is a notice that fires a few days after plugin activation which asks for a 5-star rating of this plugin on its WordPress.org profile page. This notice will re-appear approximately once every 9 months. These notices can be dismissed by clicking the (x) symbol in the upper right of the notice box. These notices may annoy or confuse certain users, but are appreciated by the majority of our userbase, who understand that these notices support our free contributions to the WordPress community while providing valuable (free) recommendations for optimizing their website.

If you feel that these notices are too annoying, than we encourage you to consider one or more of our upcoming premium plugins that combine several free plugin features into a single control panel, or even consider developing your own plugins for WordPress, if supporting free plugin authors is too frustrating for you. A final alternative would be to place the defined constant mentioned below inside of your wp-config.php file to manually hide this plugin’s nag notices:

define('DISABLE_NAG_NOTICES', true);

Note: This defined constant will only affect the notices mentioned above, and will not affect any other notices generated by this plugin or other plugins, such as one-time notices that communicate with admin-level users.

Inspiration

  • https://wordpress.org/plugins/subtitles/
  • [https://wordpress.org/plugins/wp-subtitle/](WP Subtitle)
  • [https://wordpress.org/plugins/add-subtitle/](Add Subtitle)
  • [https://codex.wordpress.org/Function_Reference/the_title](WordPress Codex)
  • [https://developer.wordpress.org/reference/functions/the_title/](WordPress Developer)

  • [https://wordpress.org/plugins/secondary-title/](Secondary Title)

Free Plugins

Premium Plugins

Special Thanks

Disclaimer

We released this plugin in response to our managed hosting clients asking for better access to their server, and our primary goal will remain supporting that purpose. Although we are 100% open to fielding requests from the WordPress community, we kindly ask that you keep the above mentioned goals in mind, thanks!

Screenshots

No screenshots provided


Reviews & Comments