You are here

function n1ed_admin_form in N1ED - Visual editor as CKEditor plugin with Bootstrap support 7

Admin form to configurable welcome message.

1 string reference to 'n1ed_admin_form'
n1ed_menu in ./n1ed.module
Implementation of hook_menu

File

./n1ed.module, line 125

Code

function n1ed_admin_form($form, &$form_state) {
  $adminJS = '/' . drupal_get_path('module', 'n1ed') . '/js/admin.js';
  if (!variable_get('n1edApiKey')) {
    variable_set('n1edApiKey', 'N1D7DFLT');
  }
  drupal_add_js($adminJS, 'external');
  $form['#attributes'] = [
    'data-apikey' => variable_get('n1edApiKey'),
    'data-token' => variable_get('n1edToken'),
  ];
  $form['n1ed_config'] = [
    '#type' => 'hidden',
    '#required' => FALSE,
  ];
  return system_settings_form($form);
}