zapobyte / wp-file-block-pdf-icon

Auto PDF icon add File blocks in Wordpress. It adds it to the download links button if files is of type pdf. Tested on Wordpress 6.2.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

WP-File-Block-Pdf-Icon

A custom WordPress plugin that adds a PDF icon to the Download button for native File Blocks in Wordpress.

Installation

  1. Download the plugin code and upload it to your WordPress installation's wp-content/plugins directory.
  2. Activate the plugin through the 'Plugins' menu in WordPress.

Usage

  1. In the WordPress admin area, go to 'WP-File-Block-Pdf-Icon' under the 'Settings' menu.
  2. Enter the custom class name you want to check for in the 'Class Names' field. It is advised to just save with the pre-input value for default File Blocks.
  3. Save the settings.
  4. The front-end script will check all posts for the presence of the custom class on page load. If the class is found, an error message will be logged to the console.

License

This plugin is licensed under the MIT License. See the LICENSE file for details.

About

Auto PDF icon add File blocks in Wordpress. It adds it to the download links button if files is of type pdf. Tested on Wordpress 6.2.


Languages

Language:PHP 58.2%Language:JavaScript 41.8%