SlideShare a Scribd company logo
HTML5 e Css3 [7]
Matteo Magni
Form
Molto Lavoro!
●   Layout
●   Validation
●   Suggest




    More Javascript →
HTML5 e Css3 - 7 | WebMaster & WebDesigner
Responsabilita'
     dei
   Browser
HTML5 WebForm
http://diveintohtml5.info/forms.html
placeholder

<form>
  <input name="q" placeholder="Go to 
a Website">
  <input type="submit" 
value="Search">
</form>
Placeholder




                           Support
 IE     FIREFOX SAFARI   CHROME OPERA IPHONE ANDROID
10.0+     4.0+    4.0+     4.0+  11.0+   4.0+  2.1+
autofocus

<form>
  <input name="b">
  <input name="q" autofocus>
  <input name="c">
  <input type="submit" value="Search">
</form>
Autofocus




                           Support
 IE     FIREFOX SAFARI   CHROME OPERA IPHONE ANDROID
10.0+     4.0+    4.0+     3.0+  10.0+   -     3.0+
Js Or jQuery
<script>
$(document).ready(function() {
  if (!("autofocus" in document.createElement("input"))) {
      $("#q").focus();
  }
});
</script>
<form name="f">
  <input id="q" autofocus>
  <input type="submit" value="Go">
</form>
Email addresses
<form>
  <input type="email">
  <input type="submit" value="Go">
</form>
HTML5 e Css3 - 7 | WebMaster & WebDesigner
Web Addresses
<form>
  <input type="url">
  <input type="submit" value="Go">
</form>
HTML5 e Css3 - 7 | WebMaster & WebDesigner
Number
<form>
    <input name="n" 
      type="number" 
      min="0" max="10" 
      step="2" value="6">
    <input type="submit" value="Go">
  </form>
HTML5 e Css3 - 7 | WebMaster & WebDesigner
HTML5 e Css3 - 7 | WebMaster & WebDesigner
http://modernizr.com/


Modernizr is a JavaScript library that detects
  HTML5 and CSS3 features in the user’s
                  browser.
Modernizr fa un test della presenza di oltre
 20 features HTML5/CSS3, restituendo un
oggetto JavaScript e una serie di classi CSS
che lo sviluppatore può utilizzare per avere
   un quadro preciso delle funzionalità
    supportate dal browser che in quel
  momento sta navigando le sue pagine
Features
●   @font-face            ●   border-image
●   Canvas                ●   border-radius
●   Canvas Text           ●   box-shadow
●   WebGL                 ●   text-shadow
●   HTML5 Audio           ●   Multiple backgrounds
●   HTML5 Audio formats   ●   background-size
●   HTML5 Video           ●   opacity
●   HTML5 Video formats   ●   CSS Animations
●   rgba()                ●   CSS Columns
●   Hsla()                ●   CSS Gradients
Features
●   CSS Reflections          ●   Inline SVG
●   CSS 2D Transforms        ●   SVG Clip paths
●   CSS 3D Transforms
                             ●   SMIL
●   Flexible Box Model
●   CSS Transitions
                             ●   Web SQL Database
●   Geolocation API          ●   IndexedDB
●   Input Types              ●   Web Sockets
●   Input Attributes         ●   hashchange Event
●   localStorage
                             ●   History Management
●   sessionStorage
●   Web Workers
                             ●   Drag and Drop
●   applicationCache         ●   Cross-window Messaging
●   SVG                      ●   Touch Events
HTML5 e Css3 - 7 | WebMaster & WebDesigner
Use Modernizr
<script src="/js/modernizr.js"></script>


if (!Modernizr.inputtypes.number) {
  // no native support for type=number 
fields
  // maybe try jQuery or some other 
JavaScript framework
http://jqueryui.com/spinner/
}
range
<form>
    <input name="n" 
      type="range" 
      min="0" max="10" 
      step="2" value="6">
    <input type="submit" value="Go">
  </form>
Date
<form>
        <input type="date"><br/>
        <input type="datetime"><br/>
        <input type="datetime­local"><br/>
        <input type="month"><br/>
        <input type="week"><br/>
        <input type="time"><br/>
        <input type="submit" value="Go">
</form>
<script>
  var i = document.createElement("input");
  i.setAttribute("type", "date");
  if (i.type == "text") {
  //jquery ui datepicker
  }
                   http://jqueryui.com/datepicker/
</script>


                                            Chrome




                                            Chrome
Search
<form>
<input name="q" type="search">
<input type="submit" value="Find">
</form>
Chrome →




Safari →
Color
<form>
<input name="q" type="color">
<input type="submit" value="Send">
</form>
Chrome &
Validate


<form>
  <input type="email">
  <input type="submit" 
value="Go">
</form>
No Validate
<form novalidate>
  <input type="email" id="addr">
  <input type="submit" 
value="Subscribe">
</form>
required


<form>
  <input id="q" required>
  <input type="submit" 
value="Search">
</form>
required
Domande?

             Slide:
http://www.slideshare.net/ilbonzo
             Code:
https://github.com/ilbonzo/Cypher
              mail:
       matteo@magni.me

More Related Content

PDF
HTML5 Forms - KISS time - Fronteers
PDF
HTML5 and CSS3: Exploring Mobile Possibilities - London Ajax Mobile Event
PDF
HTML5 workshop, forms
PPTX
How I Learned to Stop Worrying and Love jQuery (Jan 2013)
PDF
HTML5 - The 2012 of the Web
PDF
Javascript: A sneak preview
PPTX
Javascipt
KEY
The go-start webframework (GTUG Vienna 27.03.2012)
HTML5 Forms - KISS time - Fronteers
HTML5 and CSS3: Exploring Mobile Possibilities - London Ajax Mobile Event
HTML5 workshop, forms
How I Learned to Stop Worrying and Love jQuery (Jan 2013)
HTML5 - The 2012 of the Web
Javascript: A sneak preview
Javascipt
The go-start webframework (GTUG Vienna 27.03.2012)

What's hot (20)

PDF
Assignment4
 
PDF
Game jump: frontend introduction #1
PDF
HTML5 - The 2012 of the Web - Adobe MAX
PDF
Devoxx 2014-webComponents
PPTX
Angular directive filter and routing
PDF
Styling components with JavaScript
PDF
Styling Components with JavaScript: MelbCSS Edition
PDF
Java script
PPTX
Introduction to jQuery Mobile
PPTX
AngularJS
PPTX
Jquery image slider
PPTX
Javascript
PDF
Web Components: The future of Web Application Development
PDF
Interacting with the DOM (JavaScript)
DOCX
Built in filters
PPTX
Javascript inside Browser (DOM)
PDF
JavaScript
PPTX
SVG - Scalable Vector Graphic
KEY
An in-depth look at jQuery UI
PDF
jQuery in 15 minutes
Assignment4
 
Game jump: frontend introduction #1
HTML5 - The 2012 of the Web - Adobe MAX
Devoxx 2014-webComponents
Angular directive filter and routing
Styling components with JavaScript
Styling Components with JavaScript: MelbCSS Edition
Java script
Introduction to jQuery Mobile
AngularJS
Jquery image slider
Javascript
Web Components: The future of Web Application Development
Interacting with the DOM (JavaScript)
Built in filters
Javascript inside Browser (DOM)
JavaScript
SVG - Scalable Vector Graphic
An in-depth look at jQuery UI
jQuery in 15 minutes
Ad

Similar to HTML5 e Css3 - 7 | WebMaster & WebDesigner (20)

PDF
Repaso rápido a los nuevos estándares web
PDF
What you need to know bout html5
PPTX
HTML5 - Pedro Rosa
PPTX
PDF
PDF
Introduccion a HTML5
PPTX
Top 10 HTML5 features every developer should know!
PDF
HTML5 New and Improved
PDF
HTML5 e Css3 - 7 | WebMaster & WebDesigner
PPTX
Top 10 HTML5 features
PDF
HTML5 & CSS3 refresher for mobile apps
PPTX
Edge of the Web
PDF
DevFest Makerere html5 presentation by caesar mukama
PDF
HTML 5 - Overview
PDF
Building iPhone Web Apps using "classic" Domino
PDF
HTML5 Refresher
PPTX
SPTechCon Boston 2015 - Utilizing jQuery in SharePoint
PDF
Html5 CSS3 jQuery Basic
KEY
#NewMeetup Performance
PPTX
JavaScript front end performance optimizations
Repaso rápido a los nuevos estándares web
What you need to know bout html5
HTML5 - Pedro Rosa
Introduccion a HTML5
Top 10 HTML5 features every developer should know!
HTML5 New and Improved
HTML5 e Css3 - 7 | WebMaster & WebDesigner
Top 10 HTML5 features
HTML5 & CSS3 refresher for mobile apps
Edge of the Web
DevFest Makerere html5 presentation by caesar mukama
HTML 5 - Overview
Building iPhone Web Apps using "classic" Domino
HTML5 Refresher
SPTechCon Boston 2015 - Utilizing jQuery in SharePoint
Html5 CSS3 jQuery Basic
#NewMeetup Performance
JavaScript front end performance optimizations
Ad

More from Matteo Magni (20)

PDF
Introduzione DevOps con Ansible
PDF
HTML5 e Css3 - 6 | WebMaster & WebDesigner
PDF
HTML5 e Css3 - 5 | WebMaster & WebDesigner
PDF
HTML5 e Css3 - 4 | WebMaster & WebDesigner
PDF
HTML5 e Css3 - 3 | WebMaster & WebDesigner
PDF
HTML5 e Css3 - 2 | WebMaster & WebDesigner
PDF
HTML5 e Css3 - 1 | WebMaster & WebDesigner
PDF
jQuery - 5 | WebMaster & WebDesigner
PDF
jQuery - 4 | WebMaster & WebDesigner
PDF
jQuery - 3 | WebMaster & WebDesigner
PDF
jQuery - 2 | WebMaster & WebDesigner
PDF
jQuery - 1 | WebMaster & WebDesigner
PDF
Javascript - 7 | WebMaster & WebDesigner
PDF
Javascript - 6 | WebMaster & WebDesigner
PDF
Javascript - 5 | WebMaster & WebDesigner
PDF
Javascript - 4 | WebMaster & WebDesigner
PDF
Javascript - 3 | WebMaster & WebDesigner
PDF
Javascript - 2 | WebMaster & WebDesigner
PDF
Javascript - 1 | WebMaster & WebDesigner
PDF
Web Usability - 3 | WebMaster & WebDesigner
Introduzione DevOps con Ansible
HTML5 e Css3 - 6 | WebMaster & WebDesigner
HTML5 e Css3 - 5 | WebMaster & WebDesigner
HTML5 e Css3 - 4 | WebMaster & WebDesigner
HTML5 e Css3 - 3 | WebMaster & WebDesigner
HTML5 e Css3 - 2 | WebMaster & WebDesigner
HTML5 e Css3 - 1 | WebMaster & WebDesigner
jQuery - 5 | WebMaster & WebDesigner
jQuery - 4 | WebMaster & WebDesigner
jQuery - 3 | WebMaster & WebDesigner
jQuery - 2 | WebMaster & WebDesigner
jQuery - 1 | WebMaster & WebDesigner
Javascript - 7 | WebMaster & WebDesigner
Javascript - 6 | WebMaster & WebDesigner
Javascript - 5 | WebMaster & WebDesigner
Javascript - 4 | WebMaster & WebDesigner
Javascript - 3 | WebMaster & WebDesigner
Javascript - 2 | WebMaster & WebDesigner
Javascript - 1 | WebMaster & WebDesigner
Web Usability - 3 | WebMaster & WebDesigner

Recently uploaded (20)

PDF
Spectral efficient network and resource selection model in 5G networks
PDF
Agricultural_Statistics_at_a_Glance_2022_0.pdf
PDF
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
PDF
Blue Purple Modern Animated Computer Science Presentation.pdf.pdf
PPTX
Spectroscopy.pptx food analysis technology
PDF
NewMind AI Weekly Chronicles - August'25 Week I
PPTX
20250228 LYD VKU AI Blended-Learning.pptx
PDF
Electronic commerce courselecture one. Pdf
PDF
Approach and Philosophy of On baking technology
PDF
Reach Out and Touch Someone: Haptics and Empathic Computing
PDF
Optimiser vos workloads AI/ML sur Amazon EC2 et AWS Graviton
PDF
Building Integrated photovoltaic BIPV_UPV.pdf
PPTX
sap open course for s4hana steps from ECC to s4
PPTX
ACSFv1EN-58255 AWS Academy Cloud Security Foundations.pptx
PDF
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
PDF
Mobile App Security Testing_ A Comprehensive Guide.pdf
PDF
Empathic Computing: Creating Shared Understanding
PDF
Architecting across the Boundaries of two Complex Domains - Healthcare & Tech...
PDF
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
PDF
Profit Center Accounting in SAP S/4HANA, S4F28 Col11
Spectral efficient network and resource selection model in 5G networks
Agricultural_Statistics_at_a_Glance_2022_0.pdf
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
Blue Purple Modern Animated Computer Science Presentation.pdf.pdf
Spectroscopy.pptx food analysis technology
NewMind AI Weekly Chronicles - August'25 Week I
20250228 LYD VKU AI Blended-Learning.pptx
Electronic commerce courselecture one. Pdf
Approach and Philosophy of On baking technology
Reach Out and Touch Someone: Haptics and Empathic Computing
Optimiser vos workloads AI/ML sur Amazon EC2 et AWS Graviton
Building Integrated photovoltaic BIPV_UPV.pdf
sap open course for s4hana steps from ECC to s4
ACSFv1EN-58255 AWS Academy Cloud Security Foundations.pptx
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
Mobile App Security Testing_ A Comprehensive Guide.pdf
Empathic Computing: Creating Shared Understanding
Architecting across the Boundaries of two Complex Domains - Healthcare & Tech...
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
Profit Center Accounting in SAP S/4HANA, S4F28 Col11

HTML5 e Css3 - 7 | WebMaster & WebDesigner