How to retrieve "Grouping" value from Select Box option in Joget?

Confluence User - 12 Jun, 2025

Hi everyone,

I'm currently working on a Select Box with hardcoded options. Each option has a Value, Label, and Grouping field filled in. Here's how my option is set up:

I want to use JavaScript (in Custom HTML) to get the grouping value of the selected option when the user changes the selection. I'm able to get the value and label using val() and text(), but I’m not sure how to access the grouping.

Is there a correct way to read the grouping field from the selected option?
Would appreciate any guidance or code examples!

Thanks in advance!

selectbox

4


12 Jun, 2025 •
confluenceUser •
1 •
confluenceUser •

Hi, you can access the grouping by using the following snippet,

var grouping = selectedOption.attr("grouping");

I hope it works for you!

12 Jun, 2025 •
confluenceUser •
•
confluenceUser •
   var grouping = $(field).find(':selected').attr('grouping');
12 Jun, 2025 •
confluenceUser •
•
confluenceUser •

Thanks!

12 Jun, 2025 •
confluenceUser •
•
confluenceUser •

Thanks!

RELATED QUESTIONS

Your answer


To answer a question you'll need an account.

Print