đŸ§Ș Launching PDF Potion: Solving the PDF Problem

Creating PDFs with Chinese Characters in Bubble
Just a quick note on using PDF Potion for creating PDFs that contain Chinese characters as a user has enquired about it.

In most cases, if you create a PDF that contains Chinese characters the Chinese characters will not appear in the PDF (you’ll get a blank space).

The solution is to use a font that does support Chinese characters (EG Noto Sans Traditional Chinese). I’ve put together a help doc on how to do this here.

Any questions just let me know :slight_smile:

Make files private - February-25 update
Just released version 1.13.0 of the PDF Potion plugin. You can now make a PDF private and attach it to a ‘thing’ so that it inherits the privacy rules associated with that thing.

Please note: You must specify the unique ID of the thing you are attaching the file to. This is a bit different to the standard Bubble file uploader element, where you can just add the ‘thing’ without including the unique ID.

Full details are available in this doc.

Any questions just let me know :slight_smile:

1 Like

‘Warm’ Create PDF action - March-25 update
Version 1.14.0 of the PDF Potion plugin has a new action called ‘Warmup’. By running this action on page load, you can avoid the 4-6 second ‘cold start’ pause that happens when you run a Bubble server side action (like the ‘Create PDF’ action) for the first time in a 10-15 minute period.

Full details are available in this doc.

Any questions just let me know :slight_smile:

1 Like

How to show / hide pages in a PDF based on a condition - March-25
I got a very good question from a PDF Potion user this week:

Can I show or hide certain pages of my PDF based on who is generating it (or some other condition?

The answer is yes.

Here’s how to do it
You may want to show or hide certain pages in your PDF based on some condition (for example the user’s role). You can use URL parameters and conditions to do this.

In the below example, we’ve designed a PDF on the ‘test-quote’ page of our app. There are 5 separate sections (or pages) to our PDF. We’re using a separate group (and 1 repeating group) for each of the pages.

Each user in our app has a ‘role’. They can be either an ‘Admin’ or a ‘Customer’:

Let’s say we only want the ‘Group - Signature’ page to appear in our PDF if the user creating the PDF is an ‘admin’. This is the ‘Group - Signature’ page:

We can control the visibility of this group by adding a URL parameter to the ‘page’ field in the ‘Create PDF’ action.

In the above image, if the current user has an ‘admin’ role, the ‘Page Name’ is going to be:

test-quote?admin=yes

If the current user is a ‘customer’, the ‘Page Name’ is going to be:

test-quote?admin=no

We can use the URL parameter to show/hide the ‘Group - Signature’ page in your PDF. Click on the relevant group and add a condition like the following:

Make sure you check the ‘collapse when hidden’ option on the group:

Now when we create the PDF as a user with the ‘Customer’ role, the signature page does not appear in the PDF:

2025-03-1210.26.57-ezgif.com-optimize

But when we create the PDF as a user with the ‘Admin’ role, the signature page does appear:

2025-03-12 10.28.19

Note: the showing / hiding of pages in your PDF does NOT have to be related to the user’s role. You can use any condition you want and link it to a URL parameter.

Any questions let me know!

Useful links:

Hello Alex,

Is there a way to make images (or group elements) redirect to a URL?

My goal is that the logo (on the pdf) can be clicked and opens browser with associated URL. If that can be done on Group Elements, that’s even better!

Many thanks!

Tim

Hi Tim, good to hear from you.

Yes this is possible, but it does involve a (small) bit of HTML. Here’s how you could approach it:

  1. In the below example I have an image element with a static image. It has fixed width and height of 100px.

  1. You can add a HTML element to your app with the same dimensions as your image and use the following code:
<a href="https://cranfordtech.com" target="_blank">
  <img src="https://f6284c9fd8991dc1f354c3b0e5f4f7e9.cdn.bubble.io/f1712762336249x921020150777024400/cranford-tech-logo-mark-full-color-rgb-2000px-h-300ppi.png"
width="100px" 
height="100px">
</a>

You’ll need to:

  • Replace the href value (“https://cranfordtech.com”) with whatever URL you’re redirecting to
  • Replace the src value with the URL link to your image. Please note you’ll need to make sure this link starts with ‘https:’ (the dynamic image URL on the image element doesn’t include this by default)
  • Update the width and height values with the dimensions you want for your image
  1. You can then replace the image element with this HTML element.

When the user clicks on the HTML element (i.e. the image) in the generated PDF, they’ll be brought to the specified URL.

2025-04-24 10.34.59

One slightly annoying feature is that if you open the PDF using Chrome’s native PDF Viewer and click on the link, it won’t open in a new tab. I’ve looked into this and there is no solution that I’ll be able to implement in the near-term for this.

Hope that helps!

Hi Alex,

Many thanks for your quick feedback, as always.

This will surely work for Logos (simple images).

As for Group Elements, it is a bit more challenging
 I’m using Group Elements with background set to “Image”. I have a Button added as overlay on top of the “image” to call for action (opens the URL).

Any chance you can walk me through this?

Many thanks in advance!!

Tim

This is actually even simpler :slight_smile:

You can use the standard Bubble link element and style it to make it look like a button. It works even in the PDFs generated by PDF Potion.

2025-04-2411.25.20-ezgif.com-optimize (1)

1 Like

Ensuring date/time data matches the user’s timezone - Apr-25 update
Released a new version of PDF Potion today that helps with time/date data in PDFs.

The problem
By default, PDF Potion operates in the UTC time zone. This can result in cases where time/date data in a PDF does not accurately match the time/date in the user’s local timezone.

The solution
However, you can ensure the date/time data in the PDF reflects the user’s own local timezone by following these steps:

  1. Install the Time zone ID plugin (it’s free) from the Bubble plugin marketplace
  2. Add the Time Zone ID element to the page in your Bubble app that you’re generating PDFs from

2025-04-25 12.19.37

  1. Reference the Time Zone ID element’s exposed state (which is called ‘Browser’s Time Zone ID’) in the ‘Time Zone ID’ field of the ‘Create PDF’ action

Any time/data in the PDF generated by PDF Potion will now reflect the user’s own time zone.

Any questions let me know :slight_smile:

Hi

I’m having trouble getting my PDF to show data. My page is a checklist with buttons for each question ‘Yes, No, N/A’, each button has a custom state ‘is active=yes’ to basically select only one option per question.

When I print the PDF it doesn’t show anything up. any ideas how I can resolve?

Thanks

Hi @parkesdude, thanks for checking out PDF Potion.

Are you saving down the responses to your database? If so, I recommend watching this short video on adding dynamic data to a PDF.

If you’re not saving down the responses and just using custom states, you could use the following approach:

I have a page in my Bubble app called ‘checklist’ with some questions

If I click on either the yes or no button for each question, it becomes highlighted.

2025-05-01 17.38.56

I’m using custom states and a conditional for this.

But, as you rightly point out, if we simply create a PDF of the ‘checklist’ page the answers will not be selected in the PDF:

2025-05-01 17.40.57

The solution is to also ‘select’ the relevant answers using a conditional if there is a URL parameter present. EG I have added the below condition to the ‘yes’ button for question 1:

Now if I append

?question-1={CUSTOM STATE FOR QUESTION1}

And I create my PDF again, I’ll get answer 1 highlighted correctly:

2025-05-01 17.46.55

I can apply this same approach to the other buttons and append more URL parameters to my page name:

And I get my PDF with answers correctly selected.

2025-05-01 17.54.10

Hope that helps!

Hi Alex

that has worked and not worked!

it does show them highlighted now, but it only shows the ‘default’ yes or no. If I have default to no, select yes, it still only shows no in the PDF!? I’ve tried various things but I don’t understand it.

Hi @parkesdude - can you share some screenshots or a screen recording if your setup?

Feel free to shoot me a private message if you’re more comfortable doing that.

Complete guide to using PDF Potion - May-25 update
I’ve recorded a couple of fairly detailed videos on how to use PDF Potion, but I recently realised:

  • It’s been some time since I created a full walk-through video
  • The Bubble UI has changed pretty significantly over the past year
  • I’ve added quite a few new features to PDF Potion since the last ‘big’ video

The below video is now the most comprehensive, up-to-date video available on how to use PDF Potion - hopefully some people find it useful!

If you’re interested in using PDF Potion but don’t want to sit through a 1 hour 16 min video (which is very fair!) I would suggest starting with:

Any questions just let me know :slight_smile:

PDF Potion as a SelectPDF alternative for Bubble - May-25
A PDF Potion user left this very kind review for our plugin recently:

It got me thinking about how PDF Potion compares to SelectPDF for Bubble apps, so I put together an article on the subject which you can read at the below link:

Any questions let me know :slight_smile:

PDF usage stats - May-25 update
You can now see how many PDFs you’ve created on a daily basis in the PDF Potion dashboard:

This data was recorded starting from 5th May, so you won’t be able to get stats on PDFs created before that date.

Any questions just let me know.

Best,
Alex

1 Like

Hi Alex, what happen if we exceed the 50 PDF generation in a month when on the free plan? Will it still produce the PDF and we pay for the extra or will the PDF not be generated?
Thanks
Yvain

1 Like

Hi @ythomas, thanks for checking out PDF Potion.

No, if you’re on the free plan and hit the 50 PDF limit, you will not be able to generate any additional PDFs.

You will need to upgrade to a paid plan.

You will get an email notification once you’ve used 90% of your PDF allowance (so 45 PDFs on the free plan).

Hope that helps.

ok, thanks for the fast reply. Is it then showing an error on the website when the workflow is not running or is the workflow just ignored?

The workflow just won’t run.

I have it on my to-do list to provide better error handling, but hopefully the automated email will give you enough advance notice that you’re running out of PDFs.