SlideShare a Scribd company logo
HTML Elements
  Standards


         by: Tiago Cardoso
Why bother? I can still do it
● I can do it all with client-side handling

● Every element is standard-natively clickable

● Prevent any native handling in every custom
  element event scripting (e.preventDefault...)

● it only works with javascript in some cases.
Well, you kinda should bother!
● Yahoo: 2% of their users are jscript-disabled

● Statistics don't tell whole story: No-js-users
  can't reach all pages in only-javascript
  websites and tend not to come back if
  nothing works.
● Browser native styling for elements.

● Screen readers, Mobile Devices, etc...
  devices with other user inputs. Semantics
  very important.

● Focusable elements (tabindex does not
  solve it all)

● Navigable through keyboard tab key.
● Specific events. ex: visited/clicked/etc.... for
  anchor tags.

● - anchor tags get crawled, button tags do not
  ("nofollow" rule is not followed 100%)
Part 1
Anchor Tags and Buttons
Elements
Anchor Tag: <a ....></a>

Button Tag: <button>....</button>

Input Submit: <input type="submit"/>

Input Button: <input type="button"/>
<a href=#a> The Anchor Tag </a>
●    A link is a connection from one Web resource to another.
●    The link starts at the "source" anchor and points to the "destination"
     anchor, which may be any Web resource (e.g., an image, a video clip, a
     sound bite, a program, an HTML document, an element within an HTML
     document, etc.)


x.html                                          c.html


<a href="#b">..</a>                               <html....>
                                                  ...



<a id="b" href="c.html"
>...</a>
<button> The Button Tag </button>
● form inner element

● Defines a push button, submission of form.

● Inside the element you can put content, like
  text or images.
<input type=submit value=Submit/>
● form inner element

● Defines a button for submission of form.

● Label of the button is defined by its value
  attribute. No option to change background
  image natively.
<input type=button value=but /input>

● form inner element

● The input buttons represents a button in a
  form with no default behavior.

● Input buttons and input submits are styled
  similarly (the same difficulties, therefore).

● Typically associated to client-side behaviour.
Conclusion

Links vs. buttons

- Links must never change state, while buttons could potentially change state.

- similar to RESTful semantics; GET vs. POST/PUT/DELETE
Use case: the post action links



             Like/Comment/Share
Use case: the post action links


              like
Use case: the post action links



            comment
Use case: the post action links



             share
Use case: the post action links


     like
Use case: the post action links


    comment
Use case: the post action links


     share
Semantic Analysis
Like Action

Adds a new “Like/Follower” to a post -> changes state in the server.

Comment Action

Makes the comment form visible to the client -> client side flickering.

Share Action

Facebook: Opens a pop-up form
Restorm: Loads an inline form
Use case: the post action links
           semantic match




               3-1
Questions?


Possible Topics:

● discuss the nofollow attribute;

● web-crawling implications in our HTML documents;
End of Part 1
Part Deux
Form Elements
Intro
● Design and Appearance decisions sometimes drive the
  Architectural Design.

● Clients sometimes (most of times?) base their requisites
  on something they saw, like how it looked, but don't
  know what it does. Developers tend to sometimes follow
  that lead.



           Should it be the other way round?
                  Is there a balance?
Why you should use?          (form elements)



● No need to provide script that handles
  functionality

● Works for JS and no-JS forms ( <3 )

● All reasons described in Part 1 that apply to
  them
Why would you run away from it?
● Form native elements are usually hard to
  style.

● Cross-browser styling on top of that (<3 your
  IEs)




(please interrupt me if you have something to add to this list)
Radio Buttons and Checkboxes
Radio Buttons:
   - used for selection of an item from a list of items.

Checkboxes:
   - used for selection of multiple items from a list of items.

checked: Gives the default checkedness of the input element.
name: Gives the name of the input element.
required: When specified, the element is required.
value: Gives the default value of the input element.
Radio Buttons and Checkboxes
Issues:

● how to style them like tag buttons?

● how to make the radio/checkboxes
  disappear and leave only the label?

● And how to make them work in every used
  browser?
Use case - Rightclearing
The Tags




 ● Multiple selection of items, orthodoxly represented by
   checkboxes;
 ● styling concerns led to the decision of implementing
   them with anchor tags supported by an hidden input
   field and a javascript plugin;
Use case - Rightclearing
Pros:
● looks really good in all of the supported browsers!
Cons:
● a lot of client-side scripting (the better part of a custom
    plugin of ours) was written to simulate part of the
    behaviour that the checkbox natively provides.
●   non-focusable, does not respond to keyboard events
    (no mouse, no fun. could be part of the plugin
    mentioned above, but it would just bloat it).
●   javascript-dependent, main reason why the RC search
    doesn’t work without script (correct me if I’m wrong).
LET THE BROWSER WARS BEGIN!
standard css:



.genres {                                      div, span, applet, object, iframe, h1, h2,
  border: medium none;                         h3, h4, h5, h6, p {
  border-radius: 0 0 3px 3px;                    background: none repeat scroll 0 0
  float: left;                                 transparent;
  margin: 0;                                     border: 0 none;
  padding: 5px;                                  font-size: 100%;
  display: inline-block;                         margin: 0;
  vertical-align: middle;                        outline: 0 none;
   background: url("http://www.                  padding: 0;
rightclearing.com/images/rightclearing/blue.     vertical-align: baseline;
png?54f75c7") repeat scroll 0 0 transparent;   }
   margin-right: 0;
}
Tryout 1: Anchor Tag Tags                                                                              (present)

                                                            a {
HTML:                                                         border: 1px solid rgba(33, 33, 38, 0.55);
                                                              color: rgba(33, 33, 38, 0.9);
                                                              cursor: pointer;
                                                              float: left;
                                                              font-size: 13px;
<div class="genres">                                          font-weight: normal;
                                                              line-height: 24px;
    <a href="#" data-value="2" class="genres_2">              margin: 0 0 3px 3px;
                                                              position: relative;
          <div class="left"></div>                            white-space: nowrap;
                                                              border: medium none;
          <div class="center">                                opacity: 1;
                                                              background: none repeat scroll 0 0 transparent;
                                                              border: 0 none;
                <span class="tag_text">Alternative</span>     font-size: 100%;
                                                              outline: 0 none;
          </div>                                              vertical-align: baseline;
                                                              text-decoration: none;
          <div class="right"></div>                         }
                                                            .left {
    </a>                                                      border-radius: 3px 0 0 3px;
                                                              width: 5px;
    <a href="#" data-value="3" class="genres_3 selected">   }
                                                            .right {
          <div class="left"></div>                            border-radius: 0 3px 3px 0;
                                                              width: 5px;
                                                            }
          <div class="center">                              a:hover {
                                                                color: #0096E6;
                <span class="tag_text">Rock</span>              text-shadow: 0 0 4px rgba(0, 150, 230, 0.4);
                                                            }
          </div>                                            a:hover > div {
                                                              background: none repeat scroll 0 0 #0096E6;
          <div class="right"></div>                           color: #FFFFFF;
                                                              text-shadow: 0 0 2px rgba(255, 255, 255, 0.6);
    </a>                                                    }
                                                            a.selected {
</div>                                                                 background: url("http://www.rightclearing.com/images/rightclearing/blue.png?
                                                            54f75c7") repeat scroll 0 0 transparent;
                                                            }




CSS:
a div {
  display: inline-block;
  float: left;
  height: 24px !important;
  color: #FFFFFF;
}
Anchor Tag Tags: Output

Firefox
Anchor Tag Tags: Output

Firefox

Chrome
Anchor Tag Tags: Output

Firefox

Chrome

Opera
Anchor Tag Tags: Output

Firefox

Chrome

Opera

IE9
Anchor Tag Tags: Output

Firefox

Chrome

Opera

IE9

IE8
Anchor Tag Tags: Output

Firefox

Chrome

Opera

IE9

IE8

IE7
Tryout Deux: Checkbox Tags                                                                                (future?)



HTML:                                                CSS:
                                                     label {
                                                       border: 1px solid rgba(33, 33, 38, 0.55);
                                                       color: rgba(33, 33, 38, 0.9);
<div class="genres">                                   cursor: pointer;
                                                       float: left;
  <label>                                              font-size: 13px;
                                                       font-weight: normal;
      <input type="checkbox" name="search[genres]"     line-height: 24px;
                                                       margin: 0 0 3px 3px;
value="2">                                             position: relative;
                                                       white-space: nowrap;
      <div class="title">                              border: medium none;
                                                       opacity: 1;
            Alternative                                background: none repeat scroll 0 0 transparent;
                                                       border: 0 none;
      </div>                                           font-size: 100%;
                                                       outline: 0 none;
  </label>                                             vertical-align: baseline;
                                                     }
   <label>
                                                     .title:hover {
      <input type="checkbox" name="search[genres]"      background: none repeat scroll 0 0 #00AAFA;
value="3">                                              color: #FFFFFF;
                                                        text-shadow: 0 0 2px rgba(255, 255, 255, 0.6);
      <div class="title">                            }

                                                     :root input {
            Rock                                       position: absolute;
                                                       clip: rect(0,0,0,0);
      </div>                                         }

  </label>                                           .title {
                                                        display: inline-block;
</div>                                                  *display: inline;
                                                        border-radius: 3px;
                                                        padding: 0 5px;
                                                     }

                                                     input:checked + .title {

                                                         background: none repeat scroll 0 0 #0096E6;
                                                         color: #FFFFFF;
                                                         text-shadow: 0 0 2px rgba(255, 255, 255, 0.6);
                                                     }
Checkbox Tags: Output

Firefox
Checkbox Tags: Output

Firefox

Chrome
Checkbox Tags: Output

Firefox

Chrome

Opera
Checkbox Tags: Output

Firefox

Chrome

Opera

IE9
Checkbox Tags: Output

Firefox

Chrome

Opera

IE9

IE8
Checkbox Tags: Output

Firefox

Chrome

Opera

IE9

IE8

IE7
Checkbox Tags: Output

Firefox

Chrome

Opera

IE9

IE8

IE7

Safari
 (it will work in IE 10)
Conclusions

Appearance

1 - Everything looks good.   (unsupported css features in the IE <=9, like border-radius and text-shadow)


2 - Everything looks at least functional. Graceful
Degradation.

Functionality

1 - Works with javascript.
2 - Works. point.
Appearance over Functionality
               or
Functionality over Appearance?
Questions?
Possible Topics:

● Why doesn’t the checkbox disappear in the IEs 8-?
(hint: IE is evil)
References
http://developer.yahoo.com/blogs/ydn/posts/2010/10/how-many-users-have-javascript-disabled/
http://www.w3.org/TR/html401/struct/links.html
http://www.w3schools.com/tags/tag_button.asp
http://discuss.joelonsoftware.com/default.asp?design.4.541972.17
http://www.w3.org/wiki/HTML/Elements/input/submit
http://www.w3.org/wiki/HTML/Elements/input/button
http://www.w3.org/wiki/HTML/Elements/input/radio
http://www.w3.org/wiki/HTML/Elements/input/checkbox
http://jsfiddle.net/
http://lea.verou.me/2011/05/rule-filtering-based-on-specific-selectors-support/
http://yfrog.com/h7ja8ep

More Related Content

What's hot

モダンなCSS設計パターンを考える
モダンなCSS設計パターンを考えるモダンなCSS設計パターンを考える
モダンなCSS設計パターンを考える
拓樹 谷
 
This is a test
This is a testThis is a test
This is a test
cmailhotos4
 
HTML5 and CSS3: Exploring Mobile Possibilities - London Ajax Mobile Event
HTML5 and CSS3: Exploring Mobile Possibilities - London Ajax Mobile EventHTML5 and CSS3: Exploring Mobile Possibilities - London Ajax Mobile Event
HTML5 and CSS3: Exploring Mobile Possibilities - London Ajax Mobile Event
Robert Nyman
 
HTML5 and CSS3 – exploring mobile possibilities - Frontend Conference Zürich
HTML5 and CSS3 – exploring mobile possibilities - Frontend Conference ZürichHTML5 and CSS3 – exploring mobile possibilities - Frontend Conference Zürich
HTML5 and CSS3 – exploring mobile possibilities - Frontend Conference ZürichRobert Nyman
 
Responsive Websites
Responsive WebsitesResponsive Websites
Responsive Websites
Joe Seifi
 
Yeşilbayır antika kol saati 0531 9810190 eski kurmalı saat
Yeşilbayır antika kol saati 0531 9810190 eski kurmalı saat Yeşilbayır antika kol saati 0531 9810190 eski kurmalı saat
Yeşilbayır antika kol saati 0531 9810190 eski kurmalı saat
adin sonsuz
 

What's hot (8)

Presentation 2
Presentation 2Presentation 2
Presentation 2
 
Tmx9
Tmx9Tmx9
Tmx9
 
モダンなCSS設計パターンを考える
モダンなCSS設計パターンを考えるモダンなCSS設計パターンを考える
モダンなCSS設計パターンを考える
 
This is a test
This is a testThis is a test
This is a test
 
HTML5 and CSS3: Exploring Mobile Possibilities - London Ajax Mobile Event
HTML5 and CSS3: Exploring Mobile Possibilities - London Ajax Mobile EventHTML5 and CSS3: Exploring Mobile Possibilities - London Ajax Mobile Event
HTML5 and CSS3: Exploring Mobile Possibilities - London Ajax Mobile Event
 
HTML5 and CSS3 – exploring mobile possibilities - Frontend Conference Zürich
HTML5 and CSS3 – exploring mobile possibilities - Frontend Conference ZürichHTML5 and CSS3 – exploring mobile possibilities - Frontend Conference Zürich
HTML5 and CSS3 – exploring mobile possibilities - Frontend Conference Zürich
 
Responsive Websites
Responsive WebsitesResponsive Websites
Responsive Websites
 
Yeşilbayır antika kol saati 0531 9810190 eski kurmalı saat
Yeşilbayır antika kol saati 0531 9810190 eski kurmalı saat Yeşilbayır antika kol saati 0531 9810190 eski kurmalı saat
Yeşilbayır antika kol saati 0531 9810190 eski kurmalı saat
 

Similar to Html standards presentation

Source Code Halaman Web Radio Stremaing [RAMEN RADIO]
Source Code Halaman Web Radio Stremaing [RAMEN RADIO]Source Code Halaman Web Radio Stremaing [RAMEN RADIO]
Source Code Halaman Web Radio Stremaing [RAMEN RADIO]
Rizki Ogawa
 
Dr. Strangelove or: How I learned to stop worrying and love HTML, CSS and Jav...
Dr. Strangelove or: How I learned to stop worrying and love HTML, CSS and Jav...Dr. Strangelove or: How I learned to stop worrying and love HTML, CSS and Jav...
Dr. Strangelove or: How I learned to stop worrying and love HTML, CSS and Jav...
RobotDeathSquad
 
Version1.0 StartHTML000000217 EndHTML000067516 StartFragment0000
Version1.0 StartHTML000000217 EndHTML000067516 StartFragment0000Version1.0 StartHTML000000217 EndHTML000067516 StartFragment0000
Version1.0 StartHTML000000217 EndHTML000067516 StartFragment0000
tidwellerin392
 
Making Links Magical Again with CSS
Making Links Magical Again with CSSMaking Links Magical Again with CSS
Making Links Magical Again with CSS
Jenn Lukas
 
Think Vitamin CSS
Think Vitamin CSSThink Vitamin CSS
Think Vitamin CSS
Nathan Smith
 
Mobile-first OOCSS, Sass & Compass at BBC Responsive News
Mobile-first OOCSS, Sass & Compass at BBC Responsive NewsMobile-first OOCSS, Sass & Compass at BBC Responsive News
Mobile-first OOCSS, Sass & Compass at BBC Responsive NewsKaelig Deloumeau-Prigent
 
Learn to love CSS3 | Joomla! Day Deutschland
Learn to love CSS3 | Joomla! Day DeutschlandLearn to love CSS3 | Joomla! Day Deutschland
Learn to love CSS3 | Joomla! Day Deutschland
ThemePartner
 
Webtech File.docx
Webtech File.docxWebtech File.docx
Webtech File.docx
gambleryeager
 
Learn to Love CSS3 [English]
Learn to Love CSS3 [English]Learn to Love CSS3 [English]
Learn to Love CSS3 [English]
ThemePartner
 
LessCSS Presentation @ April 2015 GTALUG Meeting
LessCSS Presentation @ April 2015 GTALUG MeetingLessCSS Presentation @ April 2015 GTALUG Meeting
LessCSS Presentation @ April 2015 GTALUG Meeting
Myles Braithwaite
 
Css tips & tricks
Css tips & tricksCss tips & tricks
Css tips & tricks
anubavam-techkt
 
Class 3 create an absolute layout with css abs position (aptana)
Class 3  create an absolute layout with css abs position (aptana)Class 3  create an absolute layout with css abs position (aptana)
Class 3 create an absolute layout with css abs position (aptana)Erin M. Kidwell
 
cssblocks.css.b_page{ width 930px; margin 0 auto; position.docx
cssblocks.css.b_page{ width 930px; margin 0 auto; position.docxcssblocks.css.b_page{ width 930px; margin 0 auto; position.docx
cssblocks.css.b_page{ width 930px; margin 0 auto; position.docx
faithxdunce63732
 
Rapid Prototyping
Rapid PrototypingRapid Prototyping
Rapid PrototypingEven Wu
 
PreDevCampSF - CSS3 Tricks
PreDevCampSF - CSS3 TricksPreDevCampSF - CSS3 Tricks
PreDevCampSF - CSS3 Tricks
incidentist
 
Blog skins396734
Blog skins396734Blog skins396734
Blog skins396734pantangmrny
 
pasangh bendera di blog
pasangh bendera di blogpasangh bendera di blog
pasangh bendera di blogellyndra
 

Similar to Html standards presentation (20)

Source Code Halaman Web Radio Stremaing [RAMEN RADIO]
Source Code Halaman Web Radio Stremaing [RAMEN RADIO]Source Code Halaman Web Radio Stremaing [RAMEN RADIO]
Source Code Halaman Web Radio Stremaing [RAMEN RADIO]
 
Dr. Strangelove or: How I learned to stop worrying and love HTML, CSS and Jav...
Dr. Strangelove or: How I learned to stop worrying and love HTML, CSS and Jav...Dr. Strangelove or: How I learned to stop worrying and love HTML, CSS and Jav...
Dr. Strangelove or: How I learned to stop worrying and love HTML, CSS and Jav...
 
Version1.0 StartHTML000000217 EndHTML000067516 StartFragment0000
Version1.0 StartHTML000000217 EndHTML000067516 StartFragment0000Version1.0 StartHTML000000217 EndHTML000067516 StartFragment0000
Version1.0 StartHTML000000217 EndHTML000067516 StartFragment0000
 
Cloudstack UI Customization
Cloudstack UI CustomizationCloudstack UI Customization
Cloudstack UI Customization
 
Making Links Magical Again with CSS
Making Links Magical Again with CSSMaking Links Magical Again with CSS
Making Links Magical Again with CSS
 
Think Vitamin CSS
Think Vitamin CSSThink Vitamin CSS
Think Vitamin CSS
 
Mobile-first OOCSS, Sass & Compass at BBC Responsive News
Mobile-first OOCSS, Sass & Compass at BBC Responsive NewsMobile-first OOCSS, Sass & Compass at BBC Responsive News
Mobile-first OOCSS, Sass & Compass at BBC Responsive News
 
Learn to love CSS3 | Joomla! Day Deutschland
Learn to love CSS3 | Joomla! Day DeutschlandLearn to love CSS3 | Joomla! Day Deutschland
Learn to love CSS3 | Joomla! Day Deutschland
 
Webtech File.docx
Webtech File.docxWebtech File.docx
Webtech File.docx
 
Learn to Love CSS3 [English]
Learn to Love CSS3 [English]Learn to Love CSS3 [English]
Learn to Love CSS3 [English]
 
LessCSS Presentation @ April 2015 GTALUG Meeting
LessCSS Presentation @ April 2015 GTALUG MeetingLessCSS Presentation @ April 2015 GTALUG Meeting
LessCSS Presentation @ April 2015 GTALUG Meeting
 
Css tips & tricks
Css tips & tricksCss tips & tricks
Css tips & tricks
 
Class 3 create an absolute layout with css abs position (aptana)
Class 3  create an absolute layout with css abs position (aptana)Class 3  create an absolute layout with css abs position (aptana)
Class 3 create an absolute layout with css abs position (aptana)
 
Sass compass
Sass compassSass compass
Sass compass
 
cssblocks.css.b_page{ width 930px; margin 0 auto; position.docx
cssblocks.css.b_page{ width 930px; margin 0 auto; position.docxcssblocks.css.b_page{ width 930px; margin 0 auto; position.docx
cssblocks.css.b_page{ width 930px; margin 0 auto; position.docx
 
CSS and CSS3
CSS and CSS3CSS and CSS3
CSS and CSS3
 
Rapid Prototyping
Rapid PrototypingRapid Prototyping
Rapid Prototyping
 
PreDevCampSF - CSS3 Tricks
PreDevCampSF - CSS3 TricksPreDevCampSF - CSS3 Tricks
PreDevCampSF - CSS3 Tricks
 
Blog skins396734
Blog skins396734Blog skins396734
Blog skins396734
 
pasangh bendera di blog
pasangh bendera di blogpasangh bendera di blog
pasangh bendera di blog
 

Recently uploaded

Introduction to CHERI technology - Cybersecurity
Introduction to CHERI technology - CybersecurityIntroduction to CHERI technology - Cybersecurity
Introduction to CHERI technology - Cybersecurity
mikeeftimakis1
 
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdfFIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
FIDO Alliance
 
Monitoring Java Application Security with JDK Tools and JFR Events
Monitoring Java Application Security with JDK Tools and JFR EventsMonitoring Java Application Security with JDK Tools and JFR Events
Monitoring Java Application Security with JDK Tools and JFR Events
Ana-Maria Mihalceanu
 
Welocme to ViralQR, your best QR code generator.
Welocme to ViralQR, your best QR code generator.Welocme to ViralQR, your best QR code generator.
Welocme to ViralQR, your best QR code generator.
ViralQR
 
By Design, not by Accident - Agile Venture Bolzano 2024
By Design, not by Accident - Agile Venture Bolzano 2024By Design, not by Accident - Agile Venture Bolzano 2024
By Design, not by Accident - Agile Venture Bolzano 2024
Pierluigi Pugliese
 
UiPath Test Automation using UiPath Test Suite series, part 4
UiPath Test Automation using UiPath Test Suite series, part 4UiPath Test Automation using UiPath Test Suite series, part 4
UiPath Test Automation using UiPath Test Suite series, part 4
DianaGray10
 
PHP Frameworks: I want to break free (IPC Berlin 2024)
PHP Frameworks: I want to break free (IPC Berlin 2024)PHP Frameworks: I want to break free (IPC Berlin 2024)
PHP Frameworks: I want to break free (IPC Berlin 2024)
Ralf Eggert
 
Generative AI Deep Dive: Advancing from Proof of Concept to Production
Generative AI Deep Dive: Advancing from Proof of Concept to ProductionGenerative AI Deep Dive: Advancing from Proof of Concept to Production
Generative AI Deep Dive: Advancing from Proof of Concept to Production
Aggregage
 
How world-class product teams are winning in the AI era by CEO and Founder, P...
How world-class product teams are winning in the AI era by CEO and Founder, P...How world-class product teams are winning in the AI era by CEO and Founder, P...
How world-class product teams are winning in the AI era by CEO and Founder, P...
Product School
 
Key Trends Shaping the Future of Infrastructure.pdf
Key Trends Shaping the Future of Infrastructure.pdfKey Trends Shaping the Future of Infrastructure.pdf
Key Trends Shaping the Future of Infrastructure.pdf
Cheryl Hung
 
When stars align: studies in data quality, knowledge graphs, and machine lear...
When stars align: studies in data quality, knowledge graphs, and machine lear...When stars align: studies in data quality, knowledge graphs, and machine lear...
When stars align: studies in data quality, knowledge graphs, and machine lear...
Elena Simperl
 
Leading Change strategies and insights for effective change management pdf 1.pdf
Leading Change strategies and insights for effective change management pdf 1.pdfLeading Change strategies and insights for effective change management pdf 1.pdf
Leading Change strategies and insights for effective change management pdf 1.pdf
OnBoard
 
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
DanBrown980551
 
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
UiPathCommunity
 
Accelerate your Kubernetes clusters with Varnish Caching
Accelerate your Kubernetes clusters with Varnish CachingAccelerate your Kubernetes clusters with Varnish Caching
Accelerate your Kubernetes clusters with Varnish Caching
Thijs Feryn
 
Secstrike : Reverse Engineering & Pwnable tools for CTF.pptx
Secstrike : Reverse Engineering & Pwnable tools for CTF.pptxSecstrike : Reverse Engineering & Pwnable tools for CTF.pptx
Secstrike : Reverse Engineering & Pwnable tools for CTF.pptx
nkrafacyberclub
 
Bits & Pixels using AI for Good.........
Bits & Pixels using AI for Good.........Bits & Pixels using AI for Good.........
Bits & Pixels using AI for Good.........
Alison B. Lowndes
 
Elizabeth Buie - Older adults: Are we really designing for our future selves?
Elizabeth Buie - Older adults: Are we really designing for our future selves?Elizabeth Buie - Older adults: Are we really designing for our future selves?
Elizabeth Buie - Older adults: Are we really designing for our future selves?
Nexer Digital
 
Quantum Computing: Current Landscape and the Future Role of APIs
Quantum Computing: Current Landscape and the Future Role of APIsQuantum Computing: Current Landscape and the Future Role of APIs
Quantum Computing: Current Landscape and the Future Role of APIs
Vlad Stirbu
 
Assure Contact Center Experiences for Your Customers With ThousandEyes
Assure Contact Center Experiences for Your Customers With ThousandEyesAssure Contact Center Experiences for Your Customers With ThousandEyes
Assure Contact Center Experiences for Your Customers With ThousandEyes
ThousandEyes
 

Recently uploaded (20)

Introduction to CHERI technology - Cybersecurity
Introduction to CHERI technology - CybersecurityIntroduction to CHERI technology - Cybersecurity
Introduction to CHERI technology - Cybersecurity
 
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdfFIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
 
Monitoring Java Application Security with JDK Tools and JFR Events
Monitoring Java Application Security with JDK Tools and JFR EventsMonitoring Java Application Security with JDK Tools and JFR Events
Monitoring Java Application Security with JDK Tools and JFR Events
 
Welocme to ViralQR, your best QR code generator.
Welocme to ViralQR, your best QR code generator.Welocme to ViralQR, your best QR code generator.
Welocme to ViralQR, your best QR code generator.
 
By Design, not by Accident - Agile Venture Bolzano 2024
By Design, not by Accident - Agile Venture Bolzano 2024By Design, not by Accident - Agile Venture Bolzano 2024
By Design, not by Accident - Agile Venture Bolzano 2024
 
UiPath Test Automation using UiPath Test Suite series, part 4
UiPath Test Automation using UiPath Test Suite series, part 4UiPath Test Automation using UiPath Test Suite series, part 4
UiPath Test Automation using UiPath Test Suite series, part 4
 
PHP Frameworks: I want to break free (IPC Berlin 2024)
PHP Frameworks: I want to break free (IPC Berlin 2024)PHP Frameworks: I want to break free (IPC Berlin 2024)
PHP Frameworks: I want to break free (IPC Berlin 2024)
 
Generative AI Deep Dive: Advancing from Proof of Concept to Production
Generative AI Deep Dive: Advancing from Proof of Concept to ProductionGenerative AI Deep Dive: Advancing from Proof of Concept to Production
Generative AI Deep Dive: Advancing from Proof of Concept to Production
 
How world-class product teams are winning in the AI era by CEO and Founder, P...
How world-class product teams are winning in the AI era by CEO and Founder, P...How world-class product teams are winning in the AI era by CEO and Founder, P...
How world-class product teams are winning in the AI era by CEO and Founder, P...
 
Key Trends Shaping the Future of Infrastructure.pdf
Key Trends Shaping the Future of Infrastructure.pdfKey Trends Shaping the Future of Infrastructure.pdf
Key Trends Shaping the Future of Infrastructure.pdf
 
When stars align: studies in data quality, knowledge graphs, and machine lear...
When stars align: studies in data quality, knowledge graphs, and machine lear...When stars align: studies in data quality, knowledge graphs, and machine lear...
When stars align: studies in data quality, knowledge graphs, and machine lear...
 
Leading Change strategies and insights for effective change management pdf 1.pdf
Leading Change strategies and insights for effective change management pdf 1.pdfLeading Change strategies and insights for effective change management pdf 1.pdf
Leading Change strategies and insights for effective change management pdf 1.pdf
 
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
 
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
 
Accelerate your Kubernetes clusters with Varnish Caching
Accelerate your Kubernetes clusters with Varnish CachingAccelerate your Kubernetes clusters with Varnish Caching
Accelerate your Kubernetes clusters with Varnish Caching
 
Secstrike : Reverse Engineering & Pwnable tools for CTF.pptx
Secstrike : Reverse Engineering & Pwnable tools for CTF.pptxSecstrike : Reverse Engineering & Pwnable tools for CTF.pptx
Secstrike : Reverse Engineering & Pwnable tools for CTF.pptx
 
Bits & Pixels using AI for Good.........
Bits & Pixels using AI for Good.........Bits & Pixels using AI for Good.........
Bits & Pixels using AI for Good.........
 
Elizabeth Buie - Older adults: Are we really designing for our future selves?
Elizabeth Buie - Older adults: Are we really designing for our future selves?Elizabeth Buie - Older adults: Are we really designing for our future selves?
Elizabeth Buie - Older adults: Are we really designing for our future selves?
 
Quantum Computing: Current Landscape and the Future Role of APIs
Quantum Computing: Current Landscape and the Future Role of APIsQuantum Computing: Current Landscape and the Future Role of APIs
Quantum Computing: Current Landscape and the Future Role of APIs
 
Assure Contact Center Experiences for Your Customers With ThousandEyes
Assure Contact Center Experiences for Your Customers With ThousandEyesAssure Contact Center Experiences for Your Customers With ThousandEyes
Assure Contact Center Experiences for Your Customers With ThousandEyes
 

Html standards presentation

  • 1. HTML Elements Standards by: Tiago Cardoso
  • 2. Why bother? I can still do it ● I can do it all with client-side handling ● Every element is standard-natively clickable ● Prevent any native handling in every custom element event scripting (e.preventDefault...) ● it only works with javascript in some cases.
  • 3. Well, you kinda should bother! ● Yahoo: 2% of their users are jscript-disabled ● Statistics don't tell whole story: No-js-users can't reach all pages in only-javascript websites and tend not to come back if nothing works.
  • 4. ● Browser native styling for elements. ● Screen readers, Mobile Devices, etc... devices with other user inputs. Semantics very important. ● Focusable elements (tabindex does not solve it all) ● Navigable through keyboard tab key.
  • 5. ● Specific events. ex: visited/clicked/etc.... for anchor tags. ● - anchor tags get crawled, button tags do not ("nofollow" rule is not followed 100%)
  • 6. Part 1 Anchor Tags and Buttons
  • 7. Elements Anchor Tag: <a ....></a> Button Tag: <button>....</button> Input Submit: <input type="submit"/> Input Button: <input type="button"/>
  • 8. <a href=#a> The Anchor Tag </a> ● A link is a connection from one Web resource to another. ● The link starts at the "source" anchor and points to the "destination" anchor, which may be any Web resource (e.g., an image, a video clip, a sound bite, a program, an HTML document, an element within an HTML document, etc.) x.html c.html <a href="#b">..</a> <html....> ... <a id="b" href="c.html" >...</a>
  • 9. <button> The Button Tag </button> ● form inner element ● Defines a push button, submission of form. ● Inside the element you can put content, like text or images.
  • 10. <input type=submit value=Submit/> ● form inner element ● Defines a button for submission of form. ● Label of the button is defined by its value attribute. No option to change background image natively.
  • 11. <input type=button value=but /input> ● form inner element ● The input buttons represents a button in a form with no default behavior. ● Input buttons and input submits are styled similarly (the same difficulties, therefore). ● Typically associated to client-side behaviour.
  • 12. Conclusion Links vs. buttons - Links must never change state, while buttons could potentially change state. - similar to RESTful semantics; GET vs. POST/PUT/DELETE
  • 13. Use case: the post action links Like/Comment/Share
  • 14. Use case: the post action links like
  • 15. Use case: the post action links comment
  • 16. Use case: the post action links share
  • 17. Use case: the post action links like
  • 18. Use case: the post action links comment
  • 19. Use case: the post action links share
  • 20. Semantic Analysis Like Action Adds a new “Like/Follower” to a post -> changes state in the server. Comment Action Makes the comment form visible to the client -> client side flickering. Share Action Facebook: Opens a pop-up form Restorm: Loads an inline form
  • 21. Use case: the post action links semantic match 3-1
  • 22. Questions? Possible Topics: ● discuss the nofollow attribute; ● web-crawling implications in our HTML documents;
  • 25. Intro ● Design and Appearance decisions sometimes drive the Architectural Design. ● Clients sometimes (most of times?) base their requisites on something they saw, like how it looked, but don't know what it does. Developers tend to sometimes follow that lead. Should it be the other way round? Is there a balance?
  • 26. Why you should use? (form elements) ● No need to provide script that handles functionality ● Works for JS and no-JS forms ( <3 ) ● All reasons described in Part 1 that apply to them
  • 27. Why would you run away from it? ● Form native elements are usually hard to style. ● Cross-browser styling on top of that (<3 your IEs) (please interrupt me if you have something to add to this list)
  • 28. Radio Buttons and Checkboxes Radio Buttons: - used for selection of an item from a list of items. Checkboxes: - used for selection of multiple items from a list of items. checked: Gives the default checkedness of the input element. name: Gives the name of the input element. required: When specified, the element is required. value: Gives the default value of the input element.
  • 29. Radio Buttons and Checkboxes Issues: ● how to style them like tag buttons? ● how to make the radio/checkboxes disappear and leave only the label? ● And how to make them work in every used browser?
  • 30. Use case - Rightclearing The Tags ● Multiple selection of items, orthodoxly represented by checkboxes; ● styling concerns led to the decision of implementing them with anchor tags supported by an hidden input field and a javascript plugin;
  • 31. Use case - Rightclearing Pros: ● looks really good in all of the supported browsers! Cons: ● a lot of client-side scripting (the better part of a custom plugin of ours) was written to simulate part of the behaviour that the checkbox natively provides. ● non-focusable, does not respond to keyboard events (no mouse, no fun. could be part of the plugin mentioned above, but it would just bloat it). ● javascript-dependent, main reason why the RC search doesn’t work without script (correct me if I’m wrong).
  • 32. LET THE BROWSER WARS BEGIN! standard css: .genres { div, span, applet, object, iframe, h1, h2, border: medium none; h3, h4, h5, h6, p { border-radius: 0 0 3px 3px; background: none repeat scroll 0 0 float: left; transparent; margin: 0; border: 0 none; padding: 5px; font-size: 100%; display: inline-block; margin: 0; vertical-align: middle; outline: 0 none; background: url("http://www. padding: 0; rightclearing.com/images/rightclearing/blue. vertical-align: baseline; png?54f75c7") repeat scroll 0 0 transparent; } margin-right: 0; }
  • 33. Tryout 1: Anchor Tag Tags (present) a { HTML: border: 1px solid rgba(33, 33, 38, 0.55); color: rgba(33, 33, 38, 0.9); cursor: pointer; float: left; font-size: 13px; <div class="genres"> font-weight: normal; line-height: 24px; <a href="#" data-value="2" class="genres_2"> margin: 0 0 3px 3px; position: relative; <div class="left"></div> white-space: nowrap; border: medium none; <div class="center"> opacity: 1; background: none repeat scroll 0 0 transparent; border: 0 none; <span class="tag_text">Alternative</span> font-size: 100%; outline: 0 none; </div> vertical-align: baseline; text-decoration: none; <div class="right"></div> } .left { </a> border-radius: 3px 0 0 3px; width: 5px; <a href="#" data-value="3" class="genres_3 selected"> } .right { <div class="left"></div> border-radius: 0 3px 3px 0; width: 5px; } <div class="center"> a:hover { color: #0096E6; <span class="tag_text">Rock</span> text-shadow: 0 0 4px rgba(0, 150, 230, 0.4); } </div> a:hover > div { background: none repeat scroll 0 0 #0096E6; <div class="right"></div> color: #FFFFFF; text-shadow: 0 0 2px rgba(255, 255, 255, 0.6); </a> } a.selected { </div> background: url("http://www.rightclearing.com/images/rightclearing/blue.png? 54f75c7") repeat scroll 0 0 transparent; } CSS: a div { display: inline-block; float: left; height: 24px !important; color: #FFFFFF; }
  • 34. Anchor Tag Tags: Output Firefox
  • 35. Anchor Tag Tags: Output Firefox Chrome
  • 36. Anchor Tag Tags: Output Firefox Chrome Opera
  • 37. Anchor Tag Tags: Output Firefox Chrome Opera IE9
  • 38. Anchor Tag Tags: Output Firefox Chrome Opera IE9 IE8
  • 39. Anchor Tag Tags: Output Firefox Chrome Opera IE9 IE8 IE7
  • 40. Tryout Deux: Checkbox Tags (future?) HTML: CSS: label { border: 1px solid rgba(33, 33, 38, 0.55); color: rgba(33, 33, 38, 0.9); <div class="genres"> cursor: pointer; float: left; <label> font-size: 13px; font-weight: normal; <input type="checkbox" name="search[genres]" line-height: 24px; margin: 0 0 3px 3px; value="2"> position: relative; white-space: nowrap; <div class="title"> border: medium none; opacity: 1; Alternative background: none repeat scroll 0 0 transparent; border: 0 none; </div> font-size: 100%; outline: 0 none; </label> vertical-align: baseline; } <label> .title:hover { <input type="checkbox" name="search[genres]" background: none repeat scroll 0 0 #00AAFA; value="3"> color: #FFFFFF; text-shadow: 0 0 2px rgba(255, 255, 255, 0.6); <div class="title"> } :root input { Rock position: absolute; clip: rect(0,0,0,0); </div> } </label> .title { display: inline-block; </div> *display: inline; border-radius: 3px; padding: 0 5px; } input:checked + .title { background: none repeat scroll 0 0 #0096E6; color: #FFFFFF; text-shadow: 0 0 2px rgba(255, 255, 255, 0.6); }
  • 48. Conclusions Appearance 1 - Everything looks good. (unsupported css features in the IE <=9, like border-radius and text-shadow) 2 - Everything looks at least functional. Graceful Degradation. Functionality 1 - Works with javascript. 2 - Works. point.
  • 49. Appearance over Functionality or Functionality over Appearance?
  • 50. Questions? Possible Topics: ● Why doesn’t the checkbox disappear in the IEs 8-? (hint: IE is evil)