Pass control values to a Coda page through URL

Is it possible to pass a parameter through the url that can be used when the user who clicked it accesses the Coda page? Example: <page’s URL>?UID=123 Desired behavior: When user clicks on that link (containing parameter UID with value 123), user lands on that page and the value 123 is used as a filter to the table shown in that page.

My goal is having unique links sent to specific people who do not have a Coda login, but still have a customized (=filtered) table for them when they access the page. The value I would pass through the URL is a unique ID for that person (that I can create by hashing that person’s email + salt (a random number) to prevent that hash to be easily deduced)

I know we can pass parameters to a Coda form made public. But then how can I show a filtered table result… in a form?

This is an interesting one! The short answer is no, you can’t access URL parameters like that.

But two things come to mind:

  1. Forms, as you said
  2. Linking directly to a fullscreen table row

Both of these would involve using the subtable design pattern (where you have a Relation column which, when looking at the detail view for a row, can be displayed as a table instead of just a list of row references).

I can’t remember if this is supported in forms though. If it is, there’s your solution. Pre-fill the user hash in the form, and then have the relation column filter based on the hash.

Alternatively, link people directly to their individual row in the people table, in a fullscreen detail view, and display the subtable filtered to just them.

Please note of course that none of this is secure and everyone can see everyone else’s data if sufficiently motivated or coda-knowledgeable.

Would one of those solutions work do you think?

If you create a custom filter or control on the page, updating it will add the filter change to the url.
So if you make a combo box control on a page that filters the table based on user in a row, that would be a url you could share that does what you want.

1 Like

Very interesting @Brendan - I had not noticed the URL changes appending something after a hash tag (like #_L9en). Do you know if there is any way to programatically calculate that URL ending so I can calculate it for each filter I want to use (instead of manually copying the URL)?

I haven’t actually tried unfortunately Jean.

Would be extremely handy if it was possible though. Will let you know if I get a chance to play with it. :slight_smile:

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.