Checking if query params are set or not

  • chrislaupama-1313767619131867177

    Chris Laupama

    3 months ago

    I am trying to check if they my id param has a value or not.

    So far I'm using "equals" and "not equals" to null. That works fine when live, but within the designer it will only equal true if the equals is an empty string.

    I don't want to send a null value as a param, so what's the best way to do this? - shouldn't the absence of a param = null?

    eg in production:

    domain.com/?id=1234 - this !=null TRUE
    domain.com/ - this = null TRUE

    that behaviour should work in the designer too tho otherwise it makes designing a bit of a pain as in the designer it works like this:

    domain.com/?id=1234 - this !=null FALSE
    domain.com/ - this = null FALSE
    domain.com/?id=1234 - this !="" TRUE
    domain.com/ - this = "" TRUE
    1313767619496775700-Screenshot_2024-12-04_at_8.17.35_PM.png
  • erikbeus-1313769018930499634

    Erik Beuschau

    3 months ago

    I'll check if there's a discrepancy between preview/editor. If a query parameter is not set, it should be null. In the editor though, it depends on which test value you gave your parameter πŸ€”
  • erikbeus-1313769280675905557

    Erik Beuschau

    3 months ago

    I guess you could use the Size formula for now and check if the size of a query parameter is >0?
  • erikbeus-1313876292977819708

    Erik Beuschau

    3 months ago

    πŸ™ŒπŸ½1

Stop scrolling. Start building.

toddle is a visual web app builder that rivals custom code β€” but accessible to your entire team!

Try toddle β€” it's free!

Β© Copyright 2024 toddle. All rights reserved.