• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar

RocketGeek

Home of WP-Members, The Original WordPress Membership Plugin

  • WordPress Plugins
    • WP-Members
      • FAQs
      • Quick Start
      • Documentation
      • Extensions
    • Advanced Options
      • Documentation
      • Purchase the Plugin
      • Get the Pro Bundle
    • Download Protect
      • Documentation
      • Purchase the Plugin
      • Get the Pro Bundle
    • Invite Codes
      • Documentation
      • Purchase the Plugin
      • Get the Pro Bundle
    • MailChimp Integration
      • Documentation
      • Purchase the Plugin
      • Get the Pro Bundle
    • PayPal Subscriptions
      • Documentation
      • Purchase the Plugin
      • Get the Pro Bundle
    • Salesforce Web-to-Lead
    • Security
      • Documentation
      • Purchase the Plugin
      • Get the Pro Bundle
    • Text Editor
      • Purchase the Plugin
      • Get the Pro Bundle
    • User List
      • Documentation
      • Purchase the Plugin
      • Get the Pro Bundle
    • User Tracking
      • Documentation
      • Purchase the Plugin
      • Get the Pro Bundle
    • Memberships for WooCommerce
    • WordPass
  • Blog
    • Basics
    • Tips and Tricks
    • Filters
    • Actions
    • Code Snippets
    • Shortcodes
    • Design
    • Release Announcements
  • Store
    • Cart
    • Checkout
  • Contact
  • Log In
  • Show Search
Hide Search
Home » Plugins » Download Protect » Download Protect Documentation » Shortcodes

Shortcodes

[wpmem_dp_error]

This shortcode is used to create the Download Error page.  It does not accept any attributes.

Place this shortcode on the file you want users to be directed to when there is an error (such as a non-logged in user clicking a download link).  This will give the user an opportunity to log in and access the file.

[wpmem_dp_list]

This shortcode displays a link of all possible download files.  It does not accept any attributes.

You can use this shortcode to display a bullet list of available files to be downloaded.

[wpmem_file]

This shortcode displays a link to a specific file.  It MUST include the file key as an attribute in the shortcode.  For example, if the file key was b0df458f9a11ac9b646aa4f6d9655984, then the shortcode would be used as follows:

[wpmem_file b0df458f9a11ac9b646aa4f6d9655984]

Note that the table of files found under Media > Download Protect will give you not only the file keys for each file, but will display the [wpmem_file] shortcode you can copy/paste for each file.

[wpmem_video]

Currently experimental, version 1.7.0 and higher

To display a video where the file key is b0df458f9a11ac9b646aa4f6d9655984:

[wpmem_video key=b0df458f9a11ac9b646aa4f6d9655984]

Attributes:

  • key (the file key)
  • height
  • width
  • controls
  • autoplay
  • controlslist
  • loop
  • muted
  • poster
  • preload
  • no_key (for messages if the file key is missing)
  • logged_out (for error message if the user is logged out)
  • error (for message if the user’s browser does not support HTML5 embedded videos)

In version 1.7.3 or later, you can omit the file key attribute name (i.e. giving just the key) as long as it is the first attribute given.  For example:

[wpmem_video b0df458f9a11ac9b646aa4f6d9655984]

[wpmem_video b0df458f9a11ac9b646aa4f6d9655984 height=300 width=900]

[wpmem_pdf_embed]

This shortcode allows you to embed a PDF into a page for display.

To display a pdf, pass the file key as an attribute:

[wpmem_pdf_embed b0df458f9a11ac9b646aa4f6d9655984]

You can define a style attribute to set the size of the display (which will vary depending upon your theme):

[wpmem_pdf_embed b0df458f9a11ac9b646aa4f6d9655984 style="width: 100%; min-height:600px;"]

WP-Members Download Protect

Plugin Info

Current Stable Version: 1.9.9
Minimum WordPress Version: 5.0
Tested up to WordPress Version: 6.6
Last Updated: 2024-10-17

Documentation

    • Installation
    • Settings
    • Upload Files
    • Download Tracking
    • Shortcodes
    • Filter Hooks
    • WP CLI Commands
    • FAQs
    • Change Log

Get the Plugin

  • Purchase the Plugin
  • Get the Pro Bundle

Ready to get started?

Join Today!

© 2025 · butlerblog.com · RocketGeek is built using WordPress, WP-Members, and the Genesis Framework

  • butlerblog.com
  • WP-Members Support Subscription
  • Terms of Service
  • Privacy Policy
  • Refund Policy