Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion classes/local/form/elements/hidden_element.php
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ public function __construct(string $name, string $value) {
*/
public function render_to(render_context $context): void {
$context->add_element('hidden', $this->name, $this->value);
$context->set_type($this->name, PARAM_TEXT);
$context->set_type($this->name, PARAM_RAW);

$this->render_conditions($context, $this->name);
}
Expand Down
2 changes: 1 addition & 1 deletion classes/local/form/elements/text_input_element.php
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ public function render_to(render_context $context): void {
$context->contextualize($this->label),
$attributes
);
$context->set_type($this->name, PARAM_TEXT);
$context->set_type($this->name, PARAM_RAW);

if ($this->default) {
$context->set_default($this->name, $context->contextualize($this->default));
Expand Down
2 changes: 1 addition & 1 deletion edit_questionpy_form.php
Original file line number Diff line number Diff line change
Expand Up @@ -479,7 +479,7 @@ private function validate_options_form(array $data, ?stored_file $package, array
foreach ($errorswithnoelement as $element => $error) {
$listitems[] = get_string('options_form_validation_error_element', 'qtype_questionpy', [
'name' => $element,
'error' => $error,
'error' => s($error),
]);
}
$list = html_writer::alist($listitems);
Expand Down