Hi

Our <abbr> -tag doesn't work in mobile browsers, because there is no "mouse" to hover above.¹

This page https://www.audero.it/blog/2013/12/23/enhancing-the-abbr-element-on-mobile/ suggests a workaround by using fancy CSS code to dynamically enhance abbr-tags to show the message.

I've tested it in my On-Site CSS Markup, but unfortunately I couldn't make it work.

I'm too ignorant about CSS to tell if it ever worked or if I did it wrong.

Interestingly did Corion recently suggest a new HTML way to reveal text on click, using <details><summary> :

Click here to reveal spoiler Here is the hidden content

It would be nice if someone tried to combine the two approaches in a way that clicking on an abbreviation revealed the title text. Such a pure CSS solution has many advantages.

You can use your CSS markup settings for that.

I'm too busy to experiment right now, but wanted at least leave a note for others or for a future me. :)

Cheers Rolf
(addicted to the Perl Programming Language :)
see Wikisyntax for the Monastery

1) Perl Monks Approved HTML tags


In reply to Workarounds for <abbr> tag on mobile browsers by LanX

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.