arg(1))); $subject = $node->title; break; case 'comment': if (arg(1)=='reply') { if (is_numeric(arg(3))) { $comment = _comment_load(arg(3)); $subject = $comment->subject; } else { $node = node_load(arg(2)); $subject = $node->title; } } else if (arg(1)=='edit' && is_numeric(arg(2))) { $comment = _comment_load(arg(2)); $subject = $comment->subject; } break; } if (!preg_match('/^' . preg_quote(t('Re:')) . '/i', $subject)) { $subject = t('Re:') . ' ' . $subject; } // comment subjects can not be longer than 64 characters $subject = truncate_utf8($subject, 60, TRUE, TRUE); if (variable_get('comment_subject_field', 1) == 1) { $form['subject']['#default_value'] = $subject; } else { // comment subject disabled in comment settings $form['subject'] = array('#type' => 'hidden', '#default_value' => $subject); } } } ?>