How to hide Order Now button in portal when variable changes.
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-02-2024 07:25 AM
I have a requirement where I need to hide Order Now button in portal when a variable option is selected Yes.
2 REPLIES 2

Community Alums
Not applicable
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-02-2024 07:30 AM
Hi @prash4 ,
You need to use onChange Catalog Client Script.
Here is the sample script:
var choice = g_form.getValue('choice_field');
if(choice=='no'){
g_form.setValue('no_order_now','true');
}
else{
g_form.setValue('no_order_now','false');
}
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-02-2024 07:55 AM - edited 09-02-2024 07:57 AM
Hi Sandeep, here variable type is Yes or No
when option is 'yes' then we need to hide Order Now, if 'No' then we need to show the button.