WikiSh /
Forms-DiscreteValues
See Forms-RequiredFields for the generic stuff that comes before and after "the interesting stuff".
In this case we will show 2 ways of looking for discrete values.
1. If the list of discrete values is very limited and never changes then you can simply list them in combinations with "or"
(other interesting stuff...) if test "${name}" == "Bob" || test "${name}" == "John" || test "${name}" == "Sally" then echo "%green%Welcome back, ${name}. As a member of the club you enjoy full privileges.%%" else echo "%red%Sorry, ${name}. Since you are not a member of the club you are not welcome here.%%" fi ... (other non-interesting stuff)
2. If the list has a larger number of values or might change then we will put all valid values in a page and search the page:
(other interesting stuff...) if grep "^${name}$" Mygroup.ValidNames then echo "%green%Welcome back, ${name}. As a member of the club you enjoy full privileges.%%" else echo "%red%Sorry, ${name}. Since you are not a member of the club you are not welcome here.%%" fi ... (other non-interesting stuff)