Skip to main content
deleted 2 characters in body
Source Link
Clive
  • 167.9k
  • 19
  • 303
  • 337

You're removing the submit handler from the element (see node_form(), towards the end). You should just change what you need to instead of replacing the whole thing:

$form['actions']['submit']['#value'] = t('Activate');

Also for some reason it change button class from btn-primary to btn-default. This shouldn't be happening.

That's not true, it should be happening. The btn-primary class is applied for submits with one of the following values:

  • 'Confirm''Save'
  • 'Filter''Confirm'
  • 'Submit'
  • 'Search'

You're removing the submit handler from the element (see node_form(), towards the end). You should just change what you need to instead of replacing the whole thing:

$form['actions']['submit']['#value'] = t('Activate');

Also for some reason it change button class from btn-primary to btn-default. This shouldn't be happening.

That's not true, it should be happening. The btn-primary class is applied for submits with one of the following values:

  • 'Confirm'
  • 'Filter'
  • 'Submit'
  • 'Search'

You're removing the submit handler from the element (see node_form(), towards the end). You should just change what you need to instead of replacing the whole thing:

$form['actions']['submit']['#value'] = t('Activate');

Also for some reason it change button class from btn-primary to btn-default. This shouldn't be happening.

That's not true, it should be happening. The btn-primary class is applied for submits with one of the following values:

  • 'Save'
  • 'Confirm'
  • 'Submit'
  • 'Search'
Source Link
Clive
  • 167.9k
  • 19
  • 303
  • 337

You're removing the submit handler from the element (see node_form(), towards the end). You should just change what you need to instead of replacing the whole thing:

$form['actions']['submit']['#value'] = t('Activate');

Also for some reason it change button class from btn-primary to btn-default. This shouldn't be happening.

That's not true, it should be happening. The btn-primary class is applied for submits with one of the following values:

  • 'Confirm'
  • 'Filter'
  • 'Submit'
  • 'Search'