WebAIM - Web Accessibility In Mind

E-mail List Archives

Accessible P Tag Usage

for

From: Isabel Holdsworth
Date: Apr 12, 2019 7:50AM


Hi Duff,

I for one would ideally like to see <p> tags being used where they're
applicable, and whenever I create a text editor based on a
contenteditable <div> I make sure that pressing Enter spawns a <p>
rather than a <div> tag.

But I've never failed this incorrect use of <div> tags during an audit.

Hope this helps.

Cheers, Isabel

On 05/04/2019, Patrick H. Lauke < <EMAIL REMOVED> > wrote:
> On 03/04/2019 02:37, Duff Johnson wrote:
> [...]
>> Here's a snippet of HTML in which we have a "floppy" <div>:
>>
>> <p>…and the bank account number is 123 456 789"<p>
>> <div>223</div>
>>
>> What's the relationship between the <p> and the <div>? We don't know.
>>
>> If it were unambiguously tagged for semantics, it would either be:
>>
>> <p>…and the bank account number is 123 456 789"<p>
>> <p>223</p>
>>
>> or...
>>
>> <p>…and the bank account number is 123 456 789 223<p>
>>
>> These would have very different meanings, and serialization doesn't solve
>> the problem.
>
> It can't be the second one, as the first paragraph is closed already
> (i'm assuming your code sample meant to have </p> and not <p> at the end
> of that line.
>
> Anyway, I'd still say: for heaven's sake, there's so much more important
> stuff that does really cause an actual problem to users. Can we stop
> wasting time on splitting hairs about this?
>
> P
> --
> Patrick H. Lauke
>
> www.splintered.co.uk | https://github.com/patrickhlauke
> http://flickr.com/photos/redux/ | http://redux.deviantart.com
> twitter: @patrick_h_lauke | skype: patrick_h_lauke
> > > > >