https://www.redmine.org/https://www.redmine.org/favicon.ico?16793021292013-10-24T13:31:52ZRedmineRedmine - Defect #15191: HTML 5 validation failureshttps://www.redmine.org/issues/15191?journal_id=527812013-10-24T13:31:52ZKsenia Altbregen
<ul></ul><p>Connected to Defect <a class="issue tracker-1 status-9 priority-4 priority-default" title="Defect: Non conformances with W3C xhtml transitional standards (Confirmed)" href="https://www.redmine.org/issues/5475">#5475</a>.</p> Redmine - Defect #15191: HTML 5 validation failureshttps://www.redmine.org/issues/15191?journal_id=527932013-10-25T08:24:48ZEtienne Massip
<ul><li><strong>Related to</strong> <i><a class="issue tracker-1 status-9 priority-4 priority-default" href="/issues/5475">Defect #5475</a>: Non conformances with W3C xhtml transitional standards</i> added</li></ul> Redmine - Defect #15191: HTML 5 validation failureshttps://www.redmine.org/issues/15191?journal_id=527952013-10-25T08:27:07ZEtienne Massip
<ul><li><strong>Category</strong> set to <i>Code cleanup/refactoring</i></li></ul><p>Please describe your patch, I don't get the default empty option displayed as an nbsp entity part and <code>"notified_project_ids[]"</code> should remain <code>'notified_project_ids[]'</code> with single quotes, this is not JavaScript.</p> Redmine - Defect #15191: HTML 5 validation failureshttps://www.redmine.org/issues/15191?journal_id=527972013-10-25T09:01:42ZKsenia Altbregen
<ul></ul><p>Well, I used the W3C validator.</p>
<p>The default empty option is really displayed as an nbsp entity, but the generated code<br /><pre><option value=""></option></pre><br />is non-valid, while the<br /><pre><option value="">&nbsp;</option></pre><br />is valid.</p>
<p>The code<br /><pre>check_box_tag(
'notified_project_ids[]',
project.id,
@user.notified_projects_ids.include?(project.id))</pre><br />did not work correctly; it did not convert notified_project_ids[] for each project to notified_project_ids_#{project.id}. The ids for all projects were identical.<br />I added the id parameter manually:<br /><pre> :id => "notified_project_ids_#{project.id}"</pre><br />Now multiple ids work correctly.</p> Redmine - Defect #15191: HTML 5 validation failureshttps://www.redmine.org/issues/15191?journal_id=527982013-10-25T09:41:01ZKsenia Altbregen
<ul><li><strong>File</strong> <a href="/attachments/10658">html_validation_patch.diff</a> <a class="icon-only icon-download" title="Download" href="/attachments/download/10658/html_validation_patch.diff">html_validation_patch.diff</a> added</li></ul><p>Quotes for notified_project_ids[] are single again, sorry.</p> Redmine - Defect #15191: HTML 5 validation failureshttps://www.redmine.org/issues/15191?journal_id=528252013-10-26T08:45:05ZJean-Philippe Langjp_lang@yahoo.fr
<ul><li><strong>Tracker</strong> changed from <i>Patch</i> to <i>Defect</i></li><li><strong>Subject</strong> changed from <i>HTML 5 Validation Venture</i> to <i>HTML 5 validation failures</i></li><li><strong>Status</strong> changed from <i>New</i> to <i>Closed</i></li><li><strong>Assignee</strong> set to <i>Jean-Philippe Lang</i></li><li><strong>Target version</strong> set to <i>2.4.0</i></li><li><strong>Resolution</strong> set to <i>Fixed</i></li></ul><p>I fixed these issues more globally, see associated commits. Thanks for pointing this out.</p> Redmine - Defect #15191: HTML 5 validation failureshttps://www.redmine.org/issues/15191?journal_id=532432013-11-19T09:25:24ZKsenia Altbregen
<ul></ul><p>In <a class="changeset" title="Prevents duplicate element ids (#15191)." href="https://www.redmine.org/projects/redmine/repository/svn/revisions/12236">r12236</a> you've set <pre>:id => nil</pre><br />Is this really acceptable? The elements now have no ids at all.</p>
<p>I've also noticed that these elements have identical names.<br />Both problems could be fixed by explicit transmission of :id and :name values.</p>
<p>P.S. There are several places with this problem (e.g. user[group_ids][] and membership[role_ids][] in users/views).</p> Redmine - Defect #15191: HTML 5 validation failureshttps://www.redmine.org/issues/15191?journal_id=532562013-11-19T19:04:54ZJean-Philippe Langjp_lang@yahoo.fr
<ul></ul><p>Ksenia Altbregen wrote:</p>
<blockquote>
<p>In <a class="changeset" title="Prevents duplicate element ids (#15191)." href="https://www.redmine.org/projects/redmine/repository/svn/revisions/12236">r12236</a> you've set [...]<br />Is this really acceptable? The elements now have no ids at all.</p>
</blockquote>
<p>AFAIK, ids are not required. And they are not needed in this case, so I've set them to nil.</p>
<blockquote>
<p>I've also noticed that these elements have identical names.</p>
</blockquote>
<p>Yes, they have to have the same name to get the values as a single array parameter. Please, have a look at:<br /><a class="external" href="http://guides.rubyonrails.org/action_controller_overview.html#hash-and-array-parameters">http://guides.rubyonrails.org/action_controller_overview.html#hash-and-array-parameters</a></p> Redmine - Defect #15191: HTML 5 validation failureshttps://www.redmine.org/issues/15191?journal_id=1094892023-03-10T01:38:44ZGo MAEDA
<ul><li><strong>Related to</strong> <i><a class="issue tracker-1 status-5 priority-4 priority-default closed" href="/issues/25337">Defect #25337</a>: Redmine patch for Rails breaks functionality of select_tag</i> added</li></ul>