Commit 208090ee authored by drumm's avatar drumm

#82336 by jvandyk. Set the default input format if we don't have one.

parent 99d07eed
......@@ -565,6 +565,9 @@ function block_box_form($edit = array()) {
'#description' => t('The content of the block as shown to the user.'),
'#weight' => -17,
);
if (!isset($edit['format'])) {
$edit['format'] = FILTER_FORMAT_DEFAULT;
}
$form['body_filter']['format'] = filter_form($edit['format'], -16);
$form['submit'] = array('#type' => 'submit', '#value' => t('Save block'));
......
......@@ -1389,6 +1389,9 @@ function comment_form($edit, $title = NULL) {
}
$form['comment_filter']['comment'] = array('#type' => 'textarea', '#title' => t('Comment'), '#rows' => 15, '#default_value' => $edit['comment'] ? $edit['comment'] : $user->signature, '#required' => TRUE);
if (!isset($edit['format'])) {
$edit['format'] = FILTER_FORMAT_DEFAULT;
}
$form['comment_filter']['format'] = filter_form($edit['format']);
$form['cid'] = array('#type' => 'value', '#value' => $edit['cid']);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment