Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix html structure #77

Closed
wants to merge 1 commit into from
Closed
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
4 changes: 2 additions & 2 deletions renderer.php
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ public function formulation_and_controls(question_attempt $qa, question_display_
if ($question->answerdisplay == "dragdrop") {
$answeroptions = $this->setup_answeroptions($qa);
}
$questiontext = html_writer::empty_tag('div', array('class' => 'qtext'));
$questiontext = html_writer::start_div('qtext');
Copy link
Author

@t-schroeder t-schroeder Aug 4, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This change is just to get rid of the / in the div start tag. See W3C validator:
image

Edit: The W3C validator says the same problem is there for the "answeroptions" div.

$markedgaps = $question->get_markedgaps($qa, $options);

foreach ($question->textfragments as $place => $fragment) {
Expand Down Expand Up @@ -151,7 +151,7 @@ public function app_connect(qtype_gapfill_question $question, string $questionte
if ($question->singleuse == true) {
$questiontext .= "<div id='gapfill_singleuse'></div>";
}
return $questiontext.'</div>';
return $questiontext;
}
/**
* Construct the gaps, e.g. textentry or dropdowns and
Expand Down