Can i use a Option set value for sending data to a page in order to get that URL path or does that value have to be in a DB?
You should be able to do that.
thats what I thought but it does not let me, it only lets me do it through URL parameters, but not through URL path
it looks to me like data to send cannot be option sets data
a URL parameter becomes a URL path.
Do you know how slugs work? You could have corresponding slug values to your option set values and this way you could manipulate the URL without using parameters.
yep, my bad , you are completely right. I just missfigured somethiing, thank you!
You the man.
i put the type of content of the loading page to be something else hahahaha, it was left like that from before… hahaha
instead of just leaving it blank
Ahhhh. When you do that, it’s expecting a slug
Here is a great blog post on the subject
Can i use a Option set value for sending data to a page in order to get that URL path or does that value have to be in a DB?
Sure you can…
Just make sure the destination page doesn’t have a defined content-type… then any text you add in the ‘Send Data To Page’ box will be appended to the URL as a path parameter (if you include forward slashes you can have multiple path segments).
e.g. Go Page ‘Store’, data to send = clothing/men/jackets
will navigate to the URL myapp.com/store/clothing/men/jackets
Then, from the destination page you can read the path using Get Data From URL, Path (or path segments as list if using multiple path segments as in the example above).
If you want Bubble to recognise the path value as an Option Set Option, it must be the Option’s Display (as written, with no spaces or special Characters, and Capitalized as it is in the Option Set)…
e.g. to get the ‘men’ option from the URL above you’ll have to have an Option with the display ‘men’ (Men - with a capital M - will not be recognised in this case)…
Then you can use Get data from URL, Path Segments as List (type set as the relevant Options Set), item#3
If you’re using some other attribute (not the display), then you can always use the Path value to filter the option set to find the specific one…
Thanks for this. I was just having the same issue so your answer helped me solve it!