Avatar of fayeb
 asked on


I have a multi value dialog list called 'Roles' this does a look up of all the user roles available in the ACL.  A user will then select which roles they want to and submit the form.  On submission this should call the javascript to set the cookie value.

The cookie value will need to store the roles the user has selected in 'Roles' field.  There will then be a field called 'EffectiveRoles' stored on all the forms in the database which will need to get the values of the 'Roles' field stored in the cookie.  If the cookies is empty ie the user has not submitted the form then the field will be set to @UserRoles.

I need to know how to set the multi values of the 'Roles' field in the cookie and then retrieve them in the 'EffectiveRoles' field.
Lotus IBM

Avatar of undefined
Last Comment

8/22/2022 - Mon

why do that at all?  Why not just use @UserRoles on all the forms?  Storing them locally allows them to be hacked by a smart user.

The customer wants the user to be able to select what roles they would like to use.  It's whats been asked for!

All I need to know is how do i read the values from a multivalue field and set them in the cookie e.g. Roles=[role1],[role2];
All of life is about relationships, and EE has made a viirtual community a real community. It lifts everyone's boat
William Peck

In cookie, seperate roles by comma


Whats the javascript that does this?

Log in or sign up to see answer
Become an EE member today7-DAY FREE TRIAL
Members can start a 7-Day Free trial then enjoy unlimited access to the platform
Sign up - Free for 7 days
Learn why we charge membership fees
We get it - no one likes a content blocker. Take one extra minute and find out why we block content.
Not exactly the question you had in mind?
Sign up for an EE membership and get your own personalized solution. With an EE membership, you can ask unlimited troubleshooting, research, or opinion questions.
ask a question

Thanks this is exactly what I needed.
Get an unlimited membership to EE for less than $4 a week.
Unlimited question asking, solutions, articles and more.

You are welcome :-)