Frage

I want to change the text that currently says "log in" on my drupal site.

It is built on drupal 7 on a sub theme of omega. I have made a hook to the login block by following some instructions found here: http://drupal.org/node/1167712, which basically adds some code into the themes template.php and then making a tpl.php in the templates folder in the theme.

I can get it to put more thing into the login block by this method so i know that its hooking to it properly, just dont know how to change the "value" of the "log in" button.

War es hilfreich?

Lösung

Try out the String Overrides module. Good for making a few changes here and there.

Andere Tipps

In your template.php , add a hook_form_alter().

function yourthemenamehere_form_alter(&$form, $form_state, $form_id) {
  //print_r($form) // This will display form elements.
  if($form_id == "user_login") {
      $form['actions']['submit']['#value']= "YOUR TEXT HERE";
  }
}

Though not exactly what you asked. You might find the following link helpful - Add Dyanmic login logut link to primary menu. It should give you a starting point.

Lizenziert unter: CC-BY-SA mit Zuschreibung
Nicht verbunden mit StackOverflow
scroll top