Project

General

Profile

« Previous | Next » 

Revision a4b5b782

Added by NOYB NOYB over 9 years ago

HTML Compliance - Collapsible Form Section HREF

Bad value for attribute href on element a: Illegal character in fragment: not a URL code point.

<a data-toggle="collapse" href="#<id> .panel-body">
Syntax of URL:Any URL. For example: /hello, #canvas, or http://example.org/. Characters should be represented in NFC and spaces should be escaped as %20.

Fix is to set an id on the target.

View differences:

src/usr/local/www/classes/Form/Section.class.php
81 81

  
82 82
		if ($this->_collapsible & COLLAPSIBLE) {
83 83
			$hdricon = '<span class="widget-heading-icon">' .
84
				'<a data-toggle="collapse" href="#' . $this->_attributes['id'] . ' .panel-body">' .
84
				'<a data-toggle="collapse" href="#' . $this->_attributes['id'] . '_panel-body">' .
85 85
					'<i class="fa fa-plus-circle"></i>' .
86 86
				'</a>' .
87 87
			'</span>';
88
			$bodyclass = '<div class="panel-body collapse ';
88
			$bodyclass = '<div id="' . $this->_attributes['id'] . '_panel-body" class="panel-body collapse ';
89 89
			if (($this->_collapsible & SEC_CLOSED)) {
90 90
				$bodyclass .= 'out">';
91 91
			} else {

Also available in: Unified diff