Thursday 22 September 2016

How to Enable Bootstrap 3 Hover Dropdowns

I love Bootstrap, but I’m not really a fan of the navigation it creates. It works really well when you’re prototyping, but if you’re doing a high-level design project, you’re better off going custom. Bootstap’s default navigation doesn’t have out-of-the-box hover dropdowns, and the mobile menu is arguably pretty boring. If you do use it though, there are some tricks to help you tweak it without going completely custom.
Some clients, sites, or apps will require you to have hover dropdowns on desktop. As you can see below, this doesn’t come out-of-the-box with Bootstrap 3.


Defining Proper Media Queries

Bootstrap has clearly defined breakpoints for different kinds of devices, specified by using CSS media queries. The following are the breakpoint categories used for the different types of devices:
  1. Extra Small Devices (e.g. cell phones) are the default, creating the “mobile first” concept in Bootstrap. This covers devices smaller than 768px wide.
  2. “Small Devices” (e.g. tablets) are targeted with @media (min-width: 768px) and (max-width: 991px) { ... }.
  3. Medium Sized Devices (e.g. Desktops) have a screen size smaller than 1200px and greater than 991px, using @media (min-width: 992px) and (max-width: 1199px) { ... }.
  4. Larger Devices (e.g. wide-screen monitors) are greater than 1200px, targeted using @media (min-width: 1200px) { ... }.

Thursday 1 September 2016

CSS3 modules :

 Some of the most important css3 modules

• Selectors
• Box Model
• Backgrounds and Borders
• Text Effects
• 2D/3D Transformations
• Animations
• Multiple Column Layout
• User Interface
 What new futures added in CSS3 for Borders and how Browser Support it?
following border futures added
• border-radius
• box-shadow
• border-image
Advantages of CSS

  • CSS saves time 
  • Pages load faster 
  •  Easy to maintenance 
  •  Superior styles to HTML 
  •  Multiple Device Compatibility 
  • Global web standards



Who Creates CSS?

CSS is created and maintained through a group of people within the W3C called the CSS Working Group. The CSS Working Group creates documents called specifications. When a specification has been discussed and officially ratified by W3C members, it becomes a recommendation.
CSS Syntax
A CSS comprises of style rules that are interpreted by the browser and then applied to the corresponding elements in your document. It consists of 3 parts
      
  • Selector 
  • Property 
  • Value
1) What is the difference between HTML and HTML5 ?
Ans:  HTML5 is nothing more then upgraded version of HTML where in HTML5 Lot of new future like Audio/mp3,Video,date select function , Canvas, 2D/3D Graphics,  placeholder ,Local SQL Database added so that no need to do external plugin like Flash player or other library

2) What is the <!DOCTYPE> ? Is it necessary to use in HTML5 ?
Ans:  The <!DOCTYPE> is an instruction to the web browser about what version of HTML the page is written in. AND The <!DOCTYPE> tag does not have an end tag and It is not case sensitive.
The <!DOCTYPE> declaration must be the very first thing in HTML5 document, before the <html> tag. As In HTML 4.01, all <! DOCTYPE > declarations require a reference to a Document Type Definition (DTD), because HTML 4.01 was based on Standard Generalized Markup Language (SGML). WHERE AS HTML5 is not based on SGML, and therefore does not require a reference to a Document Type Definition (DTD).


3) How many New Markup Elements you know in HTML5 ?
Ans:  Below are the New Markup Elements added in HTML5
    Tag Description

<article> Specifies independent, self-contained content, could be a news-article, blog post, forum post,
or other articles which can be distributed independently from the rest of the site.

<aside> For content aside from the content it is placed in. The aside content should
be related to the surrounding content

<bdi> For text that should not be bound to the text-direction of its parent elements

<command> A button, or a radiobutton, or a checkbox

<details> For describing details about a document, or parts of a document

<summary> A caption, or summary, inside the details element

<figure> For grouping a section of stand-alone content, could be a video

<figcaption> The caption of the figure section


<footer> For a footer of a document or section, could include the name of the author, the
date of the document, contact information, or copyright information

<header> For an introduction of a document or section, could include navigation

<hgroup> For a section of headings, using <h1> to <h6>, where the largest is the main
heading of the section, and the others are sub-headings

<mark> For text that should be highlighted

<meter> For a measurement, used only if the maximum and minimum values are known

<nav> For a section of navigation

<progress> The state of a work in progress

<ruby> For ruby annotation (Chinese notes or characters)

<rt> For explanation of the ruby annotation
<rp> What to show browsers that do not support the ruby element

<section> For a section in a document. Such as chapters, headers, footers, or any
other sections of the document
<time> For defining a time or a date, or both

<wbr> Word break. For defining a line-break opportunity.

4) Difference between Transitional and Strict doctype.?

Strict : This DTD contains all HTML elements and attributes, but does NOT INCLUDE presentational or deprecated elements (like font). Framesets are not allowed.

Transitional : This DTD contains all HTML elements and attributes, INCLUDING presentational and deprecated elements (like font). Framesets are not allowed.


5)  What are New Semantic/Structural Elements
HTML5 offers new elements for better structure:

Ans:   html5 new tags:-


<article> Defines an article

<aside> Defines content aside from the page content
<bdi> Isolates a part of text that might be formatted in a different direction from other text outside it
<command> Defines a command button that a user can invoke
<details> Defines additional details that the user can view or hide
<dialog> Defines a dialog box or window
<summary> Defines a visible heading for a <details> element
<figure> Specifies self-contained content, like illustrations, diagrams, photos, code listings, etc.
<figcaption> Defines a caption for a <figure> element
<footer> Defines a footer for a document or section
<header> Defines a header for a document or section
<hgroup> Groups a set of <h1> to <h6> elements when a heading has multiple levels
<mark> Defines marked/highlighted text
<meter> Defines a scalar measurement within a known range (a gauge)
<nav> Defines navigation links
<progress> Represents the progress of a task
<ruby> Defines a ruby annotation (for East Asian typography)
<rt> Defines an explanation/pronunciation of characters (for East Asian typography)
<rp> Defines what to show in browsers that do not support ruby annotations
<section> Defines a section in a document
<time> Defines a date/time
<wbr> Defines a possible line-break



6) HTML5  New input Types ?
Ans :
• search
• tel
• time
• color
• email
• month
• date
• datetime
• datetime-local
• number
• range
• url
• week