Skip to content
Permalink
Browse files

Some fixes to avoid notices etc

  • Loading branch information...
moodler
moodler committed Jan 29, 2005
1 parent 86db09e commit 63689c58b12ac145765ebde192d82913ce8c434e
Showing with 9 additions and 7 deletions.
  1. +3 −5 blocks/html/block_html.php
  2. +6 −2 blocks/html/config_instance.html
@@ -9,10 +9,8 @@ function init() {
}
function specialization() {
// Does not check if $this->config or $this->config->title
// are empty because if they are then the user wishes the title
// of the block to be hidden anyway
$this->title = $this->config->title;
// We allow empty titles
$this->title = isset($this->config->title) ? $this->config->title : '';
}
function instance_allow_multiple() {
@@ -27,7 +25,7 @@ function get_content() {
}
$this->content = new stdClass;
$this->content->text = $this->config->text;
$this->content->text = isset($this->config->text) ? $this->config->text : '';
$this->content->footer = '';
return $this->content;
@@ -1,15 +1,19 @@
<?php $usehtmleditor = can_use_html_editor(); ?>
<table cellpadding="9" cellspacing="0">
<tr valign="top">
<td align="right"><p><?php print_string('configtitle', 'block_html'); ?>:</td>
<td><input type="text" name="title" size="30" value="<?php echo $this->config->title; ?>" /> (<?php print_string('leaveblanktohide', 'block_html'); ?>)</td>
</tr>
<tr valign="top">
<td align="right"><p><?php print_string('configcontent', 'block_html'); ?>:</td>
<td><?php print_textarea(true, 10, 50, 0, 0, 'text', $this->config->text); ?></td>
<td><?php print_textarea($usehtmleditor, 10, 50, 0, 0, 'text', isset($this->config->text)?$this->config->text:'') ?></td>
</tr>
<tr>
<td colspan="3" align="center">
<input type="submit" value="<?php print_string('savechanges') ?>" /></td>
</tr>
</table>
<?php use_html_editor(); ?>
<?php if ($usehtmleditor) {
use_html_editor();
}
?>

0 comments on commit 63689c5

Please sign in to comment.
You can’t perform that action at this time.