<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://www.w3.org/Bugs/Public/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.4"
          urlbase="https://www.w3.org/Bugs/Public/"
          
          maintainer="sysbot+bugzilla@w3.org"
>

    <bug>
          <bug_id>21436</bug_id>
          
          <creation_ts>2013-03-29 17:24:15 +0000</creation_ts>
          <short_desc>@longdesc should, like @src, be a valid *non-empty* URL.</short_desc>
          <delta_ts>2013-04-10 03:29:39 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>HTML WG</product>
          <component>HTML Image Description Extension</component>
          <version>unspecified</version>
          <rep_platform>PC</rep_platform>
          <op_sys>All</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc>http://www.w3.org/TR/2013/WD-html-longdesc-20130312/#longdesc</bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords>a11y, a11y_text-alt</keywords>
          <priority>P2</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Leif Halvard Silli">xn--mlform-iua</reporter>
          <assigned_to name="Charles McCathieNevile">chaals</assigned_to>
          <cc>hans.hillen</cc>
    
    <cc>public-html-admin</cc>
    
    <cc>xn--mlform-iua</cc>
          
          <qa_contact name="HTML WG Bugzilla archive list">public-html-bugzilla</qa_contact>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>85153</commentid>
    <comment_count>0</comment_count>
    <who name="Leif Halvard Silli">xn--mlform-iua</who>
    <bug_when>2013-03-29 17:24:15 +0000</bug_when>
    <thetext>PROPOSAL:

  Update the definition of the content of the @longdesc attribute to match the requirements for the @src attribute.


CURRENT SITUATION:

  Referring to its definition in HTML5,[1] the HTML Image Description Extension spec currently says that the content of the @longdesc attribute MUST be:

   ]] a valid URL potentially surrounded by spaces [[

  This definition, however, is too loose. For contrast, the definition of the img element’s @src attribute pointes to HTML5’s definition of &apos;a validt non-empty URL&apos;.[2] Thus, @src is required to be: [3]

   ]] a valid non-empty URL potentially surrounded by spaces [[


WHY CURRENT SITUATION IS DANGEROUS:

  The consequence of the above is that the HTML5 validator whines if the @src attribute only contains the empty string (including the empty string surrounded by spaces) - which is nice. But, conversely, if the @longdesc attribute contains the empty string (potentially surrounded by spaces), the validator does (currently) not whine.[4] 

  It is also worth mentioning that in the infamous Longdesc Lottery, then &quot;is blank&quot; (followed by &quot;is not a valid URL&quot;), is the first mentioned example of longdesc misuse.[5] When possible, the HTML Image Description Extension spec should demonstrate that it tries to avoid the issues that the Longdesc Lottery article takes up.

[1] http://www.w3.org/html/wg/drafts/html/master/infrastructure.html#valid-url-potentially-surrounded-by-spaces
[2] http://www.w3.org/html/wg/drafts/html/master/infrastructure.html#valid-non-empty-url
[3] http://www.w3.org/TR/html5/embedded-content-0.html#attr-img-src
[4] http://tinyurl.com/emptyLongdesc
[5] http://blog.whatwg.org/the-longdesc-lottery</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>85159</commentid>
    <comment_count>1</comment_count>
    <who name="Leif Halvard Silli">xn--mlform-iua</who>
    <bug_when>2013-03-29 20:03:56 +0000</bug_when>
    <thetext>As part of this bug fix, please do as well replace the following text - this:

 ]] If a longdesc attribute has invalid content, [[

With the following text: 

 ]] If the content of a longdesc attribute is not a
&lt;a href=&quot;
http://www.w3.org/html/wg/drafts/html/master/infrastructure.html#valid-non-empty-url
&quot; &gt;valid non-empty-url&lt;/a&gt; [[</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>85182</commentid>
    <comment_count>2</comment_count>
    <who name="Charles McCathieNevile">chaals</who>
    <bug_when>2013-03-31 12:12:47 +0000</bug_when>
    <thetext>I agree. I&apos;ll update this in the next draft. (I thought I had this already, actually)</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>85489</commentid>
    <comment_count>3</comment_count>
    <who name="Charles McCathieNevile">chaals</who>
    <bug_when>2013-04-03 12:33:42 +0000</bug_when>
    <thetext>Fixed as of https://dvcs.w3.org/hg/html-proposals/raw-file/0dd2e510d4e1/longdesc1/longdesc.html</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>