Term name of current node in title I'm trying to echo out the current term name that my node is inside of into my function, but it only keeps echoing out 1 and not the name. This is what I have.

function bartik_process_html(&amp;$variables) {
  // Hook into color.module.
  if (module_exists('color')) {
    _color_html_alter($variables);

    if (drupal_is_front_page()) {
      $variables['head_title'] = implode(' - ', $variables['head_title_array']);
    }
    elseif (node_is_page()) {
      $terms_name = print $term_name-&gt;name;
      $variables['head_title'] = implode(' - '.$terms_name.' - ', $variables['head_title_array']);
    }
  }
}


can anyone help?
Your code is using the following line:

$terms_name = print $term_name-&gt;name;


You are assigning to $terms_name the value returned by print $term_name-&gt;name, which is 1.
If you try executing $var = print "ciao";, you will notice that the value assigned to $var is 1.

The other issue with that code is that $term_name is not a variable defined from the code you showed; executing that code, you get an "access to a not defined variable" error.