Hide submit button on client script

ggggasgasgasgas
Kilo Contributor

Hi.

How can i hide the submit button with a client script?

I use:     this,jQuery('button').hide();

But it hides all buttons and it is a problem in my form, i need hide only submit button

 

Thanks and greetings

 

 

6 REPLIES 6

dj7887
Tera Expert

Hi There,

Can you please confirm table on which you want to hide Submit button.

We did this for Close task button.

Refer to below code.

 

if(state == '4' || state == '7')
{
var buttons = document.getElementsByClassName("form_action_button header action_context btn btn-default");

for( var i =0; i<buttons.length; i++)
{

if(buttons[i].id == 'close_sc_task')
{
buttons[i].hide();
}
}

 

Please mark helpful or correct if this response helps you to solve your query.

Thanks,

DJ.

 

ggggasgasgasgas
Kilo Contributor

i want to do it in a order guide form.

 

I think it is sc_cat_item_guide table

Can you share screenshot of the page

Thanks,

DJ

ggggasgasgasgas
Kilo Contributor

Sorry dj7887, this doesnt run for me