PDF Button Visibility by User Role

PDF button visibility by user role allows you to control who can see the PDF button and generate PDFs from your WordPress content. This feature is perfect when you want to:

  • Restrict PDF generation to logged-in members only
  • Make PDF generation available only to administrators and editors
  • Provide premium content in PDF format exclusively to paid members

Setting Up Role-Based Visibility

  1. Go to DK PDF > Settings
  2. Click on the PDF Button tab
  3. Scroll down to find the “Visibility by role” setting
  4. Click on the dropdown field to see all available options
DK PDF Button Visibility by User Role.

    You can select multiple roles at once:

    1. Click on each role you want to allow access
    2. Selected roles will appear as tags in the field
    3. To remove a role, click the “×” next to it
    DK PDF Button Visibility by User Role selected roles.

    How It Works

    When you select specific user roles, only users with those roles will be able to:

    • See the PDF button on your posts, pages, or WooCommerce products
    • Click the button to generate PDFs
    • Access PDFs directly via URL

    Users without the required role will not see the button at all, and if they try to access a PDF directly, they’ll see an “Access Denied” message.