Cleaning up xhtml markup. Code now validates for xhtml 1.0 transitional.

This commit is contained in:
vyshane 2006-02-20 02:15:45 +00:00
parent 7541b03f28
commit af25f45e1a
21 changed files with 224 additions and 135 deletions

View file

@ -1,25 +1,73 @@
<table width="100%"><tr><td span="2">
<form name="fieldsubform" action="<?php echo $CFG->wwwroot; ?>/mod/data/fields.php?d=<?php echo ($field->dataid); ?>" method="POST">
<?php echo ($this->name()); ?></td></tr>
<tr><td><?php echo get_string('fieldname', 'data');?>:</td><td><input style="width:300px;" type="text" name="name" id="name" value = "<?php echo($field->name); ?>" /></td></tr>
<tr><td><?php echo get_string('fielddescription', 'data');?>:</td><td><input style="width:300px;" type="text" name="description" id="description" value = "<? echo ($field->description);?>" /></td></tr>
<tr><td><?php echo get_string('fieldwidthsingleview', 'data');?>:</td><td><input style="width:70px;" type="text" name="param1" id="param1" value = "<? if (!empty($field->param1)) echo $field->param1; ?>" />
<tr><td><?php echo get_string('fieldheightsingleview', 'data');?>:</td><td><input style="width:70px;" type="text" name="param2" id="param2" value = "<? if (!empty($field->param2)) echo $field->param2; ?>" />
<tr><td><?php echo get_string('fieldwidthlistview', 'data');?>:</td><td><input style="width:70px;" type="text" name="param4" id="param4" value = "<? if (!empty($field->param4)) echo $field->param4; ?>" />
<tr><td><?php echo get_string('fieldheightlistview', 'data');?>:</td><td><input style="width:70px;" type="text" name="param5" id="param5" value = "<? if (!empty($field->param5)) echo $field->param5; ?>" />
<tr><td><?php echo get_string('maxsize', 'data'); ?>:</td><td>
<?php
$choices = get_max_upload_sizes($CFG->maxbytes, $course->maxbytes);
choose_from_menu ($choices, "param3", $field->param3, "");
?>
</td>
<form name="fieldsubform" action="<?php echo $CFG->wwwroot; ?>/mod/data/fields.php?d=<?php echo ($field->dataid); ?>" method="post">
<table width="100%">
<tr>
<td colspan="2">
<?php echo ($this->name()); ?>
</td>
</tr>
<tr>
<td>
<?php echo get_string('fieldname', 'data');?>:</td><td><input style="width:300px;" type="text" name="name" id="name" value = "<?php echo($field->name); ?>" />
</td>
</tr>
<tr>
<td>
<?php echo get_string('fielddescription', 'data');?>:
</td>
<td>
<input style="width:300px;" type="text" name="description" id="description" value = "<? echo ($field->description);?>" />
</td>
</tr>
<tr>
<td>
<?php echo get_string('fieldwidthsingleview', 'data');?>:
</td>
<td>
<input style="width:70px;" type="text" name="param1" id="param1" value = "<? if (!empty($field->param1)) echo $field->param1; ?>" />
</td>
</tr>
<tr>
<td>
<?php echo get_string('fieldheightsingleview', 'data');?>:
</td>
<td>
<input style="width:70px;" type="text" name="param2" id="param2" value = "<? if (!empty($field->param2)) echo $field->param2; ?>" />
</td>
</tr>
<tr>
<td>
<?php echo get_string('fieldwidthlistview', 'data');?>:</td><td><input style="width:70px;" type="text" name="param4" id="param4" value = "<? if (!empty($field->param4)) echo $field->param4; ?>" />
</td>
</tr>
<tr>
<td>
<?php echo get_string('fieldheightlistview', 'data');?>:
</td>
<td>
<input style="width:70px;" type="text" name="param5" id="param5" value = "<? if (!empty($field->param5)) echo $field->param5; ?>" />
</td>
</tr>
<tr>
<td>
<?php echo get_string('maxsize', 'data'); ?>:
</td>
<td>
<?php
$choices = get_max_upload_sizes($CFG->maxbytes, $course->maxbytes);
choose_from_menu ($choices, "param3", $field->param3, "");
?>
</td>
</tr>
<tr>
<td>&nbsp;</td>
<td>
<input type="submit" value="<?php if ($newfield) {echo get_string('add');} else {echo get_string('save','data');} ?>" />
<input type="hidden" name="fid" value="<?php echo ($field->id); ?>" />
<input type="hidden" name="mode" value="<?php if ($newfield) {echo 'add';} else {echo 'update';} ?>" />
<input type="hidden" name="type" value="<?php echo $this->type; ?>" />
<input type="submit" value="<?php echo get_string('cancel'); ?>" onclick="document.fieldsubform.mode.value='void';" />
<input name="sesskey" value="<?php echo sesskey(); ?>" type="hidden" />
</td>
</tr>
<tr><td></td><td><input type="submit" value="<?php if ($newfield) {echo get_string('add');} else {echo get_string('save','data');} ?>" />
<input type="hidden" name="fid" value="<?php echo ($field->id); ?>" />
<input type="hidden" name="mode" value="<?php if ($newfield) {echo 'add';} else {echo 'update';} ?>" />
<input type="hidden" name="type" value="<?php echo $this->type; ?>" />
<input type="submit" value="<?php echo get_string('cancel'); ?>" onclick="document.fieldsubform.mode.value='void';" \>
<input name="sesskey" value="<?php echo sesskey(); ?>" type="hidden"></td>
</table>
</form>
</td></tr></table>