w3-video.com logo

HTML5 Tutorial

Home HTML5 XAMPP .htaccess Firefox Notepad++

Share it

html style attribute

The style attribute on the html element:

Warning: inline style should be avoided as much as possible, use CSS external style sheets instead.


18.style=CSS property:value<html style="color:#fff"> ... <⁄html>
<html style="font-weight:bold"> ... <⁄html>
<html style="text-decoration:underline"> ... <⁄html>

Video demonstration html style attribute

HTML5 html style attribute Tutorial

min video details
00:02 launch "style.php" file in browser
00:05 open "style.php" file in Notepad++
00:11 the value of the style attribute: CSSproperty:value
00:15 There are 3 different ways of stylying your web page, using:
1. external style - the most recommended
2. internal style
3. inline style - the less recommended
00:15 1. external style - the most recommended
00:20 2. internal style
00:29 3. inline style - the less recommended:
- adding the style attribute on html tag
- adding one CSS property: "CSSproperty:value"
- adding more than one CSS property : "CSSproperty1:value;CSSproperty2:value "
00:39 saving the modifications in Notepad++ and refreshing the file in browser
00:42 testing: <html style="color:#fff">
00:31 result:the page's content is colored in white
html intro html optional html occurrences html browser display html children html syntaxhtml manifest attribute introappcache CACHE sectionappcache NETWORK sectionappcache FALLBACK sectionappcache ADVANTAGESappcache DISADVANTAGEappcache fixes: 1aappcache fixes: 1bappcache fixes: 2aappcache fixes: 2bappcache fixes: 2cappcache fixes: 3html class attributehtml contenteditable attributehtml contextmenu attributehtml dir attributehtml hidden attributehtml id attributehtml lang attributehtml spellcheck attributehtml title attributehtml translate attribute