Movatterモバイル変換


[0]ホーム

URL:


Predhin Sapru, profile picture
Uploaded byPredhin Sapru
PDF, PPTX2,757 views

Html,javascript & css

This document provides an overview of HTML, CSS, and JavaScript for web development. It discusses the basics of each technology, how they work together, and includes the following key points:- HTML is the markup language that defines the structure and content of a web page. CSS is used to style and lay out elements on the page. JavaScript adds interactive functionality.- Events, functions, and variables are important JavaScript concepts. Events trigger actions, functions contain reusable code, and variables store and retrieve data. - CSS selectors allow styling elements by type, class, ID, and other attributes. The box model, positioning, and other properties control layout. - Common debugging tools like Firebug help

Embed presentation

Download as PDF, PPTX
HTML,JAVASCRIPT &CSSWeb is a book outlet and our website is abook
Agenda•••••Basics to Html, CSS, JavaScriptWhere this fits in Website developmentDebuggingExamplesQ/A
Introduction•Core Concept of web development••HTML + CSS + JavaScriptContent + Style + Behavior
HTML• What?• Web server: a system on the internet contains one or more web site• Web site: a collection of one or more web pages• Web pages: single disk file with a single file name• Home pages: first page in websiteo What for ?• Think about the sort of information(content) you want to put on the Web.• Set the goals for the Web site.• Organize your content into main topics.• Come up with a general structure for pages and topics.
HTML
HTML••HTML is not a programming language, it is a markup languageHTML markup tags are usually called HTML tagsoooo•••HTML tags are keywords surrounded by angle brackets like <html>HTML tags normally come in pairs like <b> and </b>The first tag in a pair is the start tag, the second tag is the end tagStart and end tags are also called opening tags and closing tagsHTML documents describe web pagesThe purpose of a web browser (like Internet Explorer or Firefox) is toread HTML documents and display them as web pages. The browserdoes not display the HTML tags, but uses the tags to interpret thecontent of the pageNote:••••The text between <html> and </html> describes the web pageThe text between <body> and </body> is the visible page contentThe text between <h1> and </h1> is displayed as a headingThe text between <p> and </p> is displayed as a paragraph
HTML••When you save an HTML file, you can use either the .htm or the .htmlfile extensionElements:Start tag *<p><ahref="default.htm" ><br />Element content End tag *This is a</p>paragraphThis is a link</a>
HTML•HTML Attributesoooo•HTML elements can have attributesAttributes provide additional information about an elementAttributes are always specified in the start tagAttributes come in name/value pairs like: name="value“Sample Attributes:Attribute ValueDescriptionclassclassname Specifies a classname for anelementididSpecifies a unique id for anelementstylestyle_defin Specifies an inline style for anitionelementtitletooltip_tex Specifies extra informationtabout an element (displayedas a tool tip)
HTML•Website Layoutso•HTML Different Doctypeso•External style sheetInternal style sheetInline stylesHtml head element:o•The doctype declaration is not an HTML tag; it is an instruction to the web browserabout what version of the markup language the page is written in.There are three ways of inserting a style sheet:ooo•Most websites have put their content in multiple columns (formatted like a magazineor newspaper)Head,Script,Base,Style,meta,titleThe HTML noscript ElementoThe <noscript> tag is used to provide an alternate content for users that havedisabled scripts in their browser or have a browser that doesn’t support client-sidescripting.
HTML
CSS•••The biggest advantage of using CSS is that, if you place the CSScode in an external style sheet, your site becomes MUCH EASIER tomaintain. You can change the layout of all your pages by editingone fileSeparates design elements from structural logicRule Structure:
CSS•Class Selectors<H1 CLASS=“warning”>Danger!</H1><P CLASS=“warning”>Be careful…</P>…….In your HTML code H1.warning {color: red;}OR to an entire class….warning {color:red;}• Css are not even• Make sure your CSS properties are supported
CSSPatternMeaning*Universal selector: matches any element.EType selector: matches any E element (i.e., an element of type E; e.g. H1 or P).EFDescendant selector: matches any F element that is a descendant of an E element.E>FChild selector: matches any F element that is a child of an element E.E+FAdjacent siblings selector: Matches any F element immediately preceded by an element E.E[foo]Attribute selector: matches any E element with the "foo" attribute set (whatever the value).E[foo="warning"]Attribute selector: matches any E element whose "foo" attribute value is exactly equal to "warning".E[foo~="warning"]Attribute selector: matches any E element whose "foo" attribute value is a list of space-separatedvalues, one of which is exactly equal to "warning".E[lang|="en"]Attribute selector: matches any E element whose "lang" attribute has a hyphen-separated list ofvalues beginning (from the left) with "en“ (e.g. en-US).DIV.warningHTML only. The same as DIV[class~="warning"].E#myidID selector: matches any E element ID equal to "myid".E:lang(c)Pseudo-class selector: matches element of type E if it is in (human) language c (the documentlanguage specifies how language is determined).E:first-childPseudo-class selector: matches element E when E is the first child of its parent.E:link, E:visitedPseudo-class selector: matches element E if E is the source anchor of a hyperlink of which thetarget is not yet visited (:link) or already visited (:visited).E:active, E:hover, E:focusDynamic Pseudo-class selector: matches E during certain user actions.E:first-line, E:first-letterPseudo-element selector: matches the first formatted line or letter of element E.
JavaScript•••••••••#
JavaScript• Eventso Events are mostly caused by user actions.o We want our JavaScript program to react to certain events. Thiscan be done with the help of event-handlerso example of the event-handler onClick: <form><inputtype="button" value="Click me" onClick="alert(’Yo’)"></form> whynot onClick="alert(“Yo”)“?o Events are normally used in combination with functions, and thefunction will not be executed before the event occurs!o Eg: <html> <head> <script type="text/javascript"> <!-- functionpopup() { alert("Hello World") } //--> </script> </head> <body><input type="button" value="Click Me!" onclick="popup()"><br /><a href="#" onmouseover="" onMouseout="popup()"> HoverMe!</a> </body> </html>
JavaScript• EventsEventAttributeDescriptionDOMclickonclickThe event occurs when the user clicks on an element2dblclickondblclickThe event occurs when the user double-clicks on anelement2mousedownonmousedownThe event occurs when a user presses a mouse buttonover an element2mousemoveonmousemoveThe event occurs when a user moves the mouse pointer 2over an elementmouseoveronmouseoverThe event occurs when a user mouse over an elementmouseoutonmouseoutThe event occurs when a user moves the mouse pointer 2out of an elementmouseuponmouseupThe event occurs when a user releases a mouse buttonover an element22
JavaScript• Variableso Variables are used to store data.o A variable is a "container" for information youwant to store. A variable's value can changeduring the script. You can refer to a variable byname to see its value or to change its value.o Rules for variable names:o Variable names are case sensitiveo They must begin with a letter or the underscorecharacter• strname – STRNAME (not same)
JavaScript• Event Hierarchyo Take the case of a Login Page
JavaScript• JavaScript No'so Global variables• var foo = "global"; //Don't do this function(){ var bar = "local"; //This is ok }();• function(){ foo = "global"; //Don't do this var bar = "local"; //This is ok }();o Inline JavaScript• Inline JavaScript is any JavaScript code that is mixed with HTML. There are twoprimary ways in which you can do this:o Eval• Also like most other programming languages, using eval in JavaScript isconsidered.. well, evil. If you find yourself using eval, there’s a big chance yourapproach is wrong.• Eg:var strJSON = '{"result":true,"count":1}';var objJSON = eval("(function(){return " + strJSON + ";})()");alert(objJSON.result);alert(objJSON.count);
JavaScript• JavaScript No'so alert("In your face")• Most of the time, using the alert method is unnecessary. The most prevalentmisuse of this method is for debugging purposes, but using tools such as Firebugand equivalents for other browsers is a much better and more efficient way todebug JavaScript code.o element.style• You can change an element’s style directly by changing properties on its styleproperty:• el.style.backgroundColor = "#ff0000";el.style.color = "#00ff00"; This is usually not agood idea because you want to keep the styling separate from the behaviourand changing an element’s style directly will override anything you’ve definedin your CSS. Better way here is to add a class to the element
Debugging• Firebug
Q/A

Recommended

PPTX
HTML, CSS And JAVASCRIPT!
PPTX
Html n CSS
PDF
Web front end development introduction to html css and javascript
PPTX
Css Basics
PDF
HTML and CSS crash course!
PPTX
Html notes with Examples
 
PPTX
PPTX
Basic of HTML, CSS(StyleSheet), JavaScript(js), Bootstrap, JSON & AngularJS
PPTX
HTML-(workshop)7557.pptx
ODP
Introduction of Html/css/js
PPTX
HTML, CSS and Java Scripts Basics
PPSX
Html introduction
PDF
Introduction to HTML and CSS
PPTX
Html
PPT
Html Ppt
PPTX
Css selectors
PDF
Html / CSS Presentation
PDF
Intro to HTML and CSS basics
PPTX
Html5 and-css3-overview
PPT
JavaScript - An Introduction
PDF
Intro to HTML & CSS
PPT
CSS Basics
PPT
CSS for Beginners
PPTX
HTML Forms
PPTX
Html forms
ODP
Html
ODP
CSS Basics
PPT
@Html
PPSX
Putting SOAP to REST

More Related Content

PPTX
HTML, CSS And JAVASCRIPT!
PPTX
Html n CSS
PDF
Web front end development introduction to html css and javascript
PPTX
Css Basics
PDF
HTML and CSS crash course!
PPTX
Html notes with Examples
 
PPTX
PPTX
Basic of HTML, CSS(StyleSheet), JavaScript(js), Bootstrap, JSON & AngularJS
HTML, CSS And JAVASCRIPT!
Html n CSS
Web front end development introduction to html css and javascript
Css Basics
HTML and CSS crash course!
Html notes with Examples
 
Basic of HTML, CSS(StyleSheet), JavaScript(js), Bootstrap, JSON & AngularJS

What's hot

PPTX
HTML-(workshop)7557.pptx
ODP
Introduction of Html/css/js
PPTX
HTML, CSS and Java Scripts Basics
PPSX
Html introduction
PDF
Introduction to HTML and CSS
PPTX
Html
PPT
Html Ppt
PPTX
Css selectors
PDF
Html / CSS Presentation
PDF
Intro to HTML and CSS basics
PPTX
Html5 and-css3-overview
PPT
JavaScript - An Introduction
PDF
Intro to HTML & CSS
PPT
CSS Basics
PPT
CSS for Beginners
PPTX
HTML Forms
PPTX
Html forms
ODP
Html
ODP
CSS Basics
HTML-(workshop)7557.pptx
Introduction of Html/css/js
HTML, CSS and Java Scripts Basics
Html introduction
Introduction to HTML and CSS
Html
Html Ppt
Css selectors
Html / CSS Presentation
Intro to HTML and CSS basics
Html5 and-css3-overview
JavaScript - An Introduction
Intro to HTML & CSS
CSS Basics
CSS for Beginners
HTML Forms
Html forms
Html
CSS Basics

Viewers also liked

PPT
@Html
PPSX
Putting SOAP to REST
PDF
HTML & JavaScript Introduction
PPTX
Fundamentos técnicos de internet
PPT
Fundamentos técnicos de internet
PPT
Web 2.0 Introduction
PPTX
Fundamentos técnicos de internet
PPTX
DNS & HTTP overview
PDF
An introduction to Web 2.0: The User Role
PPTX
Web basics
PPT
Introduction to Web 2.0
PPT
Dns introduction
PPT
Web of Science: REST or SOAP?
PPTX
TCP/IP and DNS
DOCX
Kanchan Ghangrekar_SrTestingAnalyst
PPTX
TCP/IP Protocols
PPT
Software Deployment Principles & Practices
PPTX
Web Application Development
PDF
Restful web services by Sreeni Inturi
PDF
Architecture of the Web browser
@Html
Putting SOAP to REST
HTML & JavaScript Introduction
Fundamentos técnicos de internet
Fundamentos técnicos de internet
Web 2.0 Introduction
Fundamentos técnicos de internet
DNS & HTTP overview
An introduction to Web 2.0: The User Role
Web basics
Introduction to Web 2.0
Dns introduction
Web of Science: REST or SOAP?
TCP/IP and DNS
Kanchan Ghangrekar_SrTestingAnalyst
TCP/IP Protocols
Software Deployment Principles & Practices
Web Application Development
Restful web services by Sreeni Inturi
Architecture of the Web browser

Similar to Html,javascript & css

PPTX
Presentation
PPTX
Tech Winter Break GDG Oncampus Sri Vasavi Engineering College
PDF
Presentation on htmlcssjs-130221085257-phpapp02.pdf
PPTX
Dsc Charusat Learning React Part 1
PPTX
Introduction to Web Development.pptx
PPTX
Introduction to Web Development.pptx
PPTX
Introduction to Web Development.pptx
PPT
Dhtml chapter2
PPTX
Web Development Fundamentals UNIT 1 & 2.pptx
PPTX
Bootcamp - Web Development Session 2
PPT
SDP_-_Module_4.ppt
PDF
Fccwc326
PPTX
WELCOME (recovernjkgnjvnvnfjkvnjknnbfjked).pptx
PPTX
Web technologies-course 07.pptx
PDF
HTML_CSS_JS Workshop
PPTX
An Overview of HTML, CSS & Java Script
PPTX
Before start
PDF
WEB DEVELOPMENT20CS41.pdf
PPT
A quick guide to Css and java script
Presentation
Tech Winter Break GDG Oncampus Sri Vasavi Engineering College
Presentation on htmlcssjs-130221085257-phpapp02.pdf
Dsc Charusat Learning React Part 1
Introduction to Web Development.pptx
Introduction to Web Development.pptx
Introduction to Web Development.pptx
Dhtml chapter2
Web Development Fundamentals UNIT 1 & 2.pptx
Bootcamp - Web Development Session 2
SDP_-_Module_4.ppt
Fccwc326
WELCOME (recovernjkgnjvnvnfjkvnjknnbfjked).pptx
Web technologies-course 07.pptx
HTML_CSS_JS Workshop
An Overview of HTML, CSS & Java Script
Before start
WEB DEVELOPMENT20CS41.pdf
A quick guide to Css and java script

Recently uploaded

PPTX
Cybersecurity Best Practices - Step by Step guidelines
PPTX
Software Analysis &Design ethiopia chap-2.pptx
PPTX
From Backup to Resilience: How MSPs Are Preparing for 2026
 
PPT
software-security-intro in information security.ppt
PDF
GPUS and How to Program Them by Manya Bansal
PDF
TrustArc Webinar - Looking Ahead: The 2026 Privacy Landscape
PDF
Internet_of_Things_IoT_for_Next_Generation_Smart_Systems_Utilizing.pdf
PDF
Energy Storage Landscape Clean Energy Ministerial
PDF
Unlocking the Power of Salesforce Architecture: Frameworks for Effective Solu...
PPTX
Building Cyber Resilience for 2026: Best Practices for a Secure, AI-Driven Bu...
PPTX
AI in Cybersecurity: Digital Defense by Yasir Naveed Riaz
PDF
Day 1 - Cloud Security Strategy and Planning ~ 2nd Sight Lab ~ Cloud Security...
PDF
Is It Possible to Have Wi-Fi Without an Internet Provider
PPTX
Cybercrime in the Digital Age: Risks, Impact & Protection
PDF
Decoding the DNA: The Digital Networks Act, the Open Internet, and IP interco...
PDF
Usage Control for Process Discovery through a Trusted Execution Environment
PDF
The year in review - MarvelClient in 2025
PDF
The major tech developments for 2026 by Pluralsight, a research and training ...
PDF
Day 5 - Red Team + Blue Team in the Cloud - 2nd Sight Lab Cloud Security Class
PDF
Eredità digitale sugli smartphone: cosa resta di noi nei dispositivi mobili
Cybersecurity Best Practices - Step by Step guidelines
Software Analysis &Design ethiopia chap-2.pptx
From Backup to Resilience: How MSPs Are Preparing for 2026
 
software-security-intro in information security.ppt
GPUS and How to Program Them by Manya Bansal
TrustArc Webinar - Looking Ahead: The 2026 Privacy Landscape
Internet_of_Things_IoT_for_Next_Generation_Smart_Systems_Utilizing.pdf
Energy Storage Landscape Clean Energy Ministerial
Unlocking the Power of Salesforce Architecture: Frameworks for Effective Solu...
Building Cyber Resilience for 2026: Best Practices for a Secure, AI-Driven Bu...
AI in Cybersecurity: Digital Defense by Yasir Naveed Riaz
Day 1 - Cloud Security Strategy and Planning ~ 2nd Sight Lab ~ Cloud Security...
Is It Possible to Have Wi-Fi Without an Internet Provider
Cybercrime in the Digital Age: Risks, Impact & Protection
Decoding the DNA: The Digital Networks Act, the Open Internet, and IP interco...
Usage Control for Process Discovery through a Trusted Execution Environment
The year in review - MarvelClient in 2025
The major tech developments for 2026 by Pluralsight, a research and training ...
Day 5 - Red Team + Blue Team in the Cloud - 2nd Sight Lab Cloud Security Class
Eredità digitale sugli smartphone: cosa resta di noi nei dispositivi mobili

Html,javascript & css

  • 1.
    HTML,JAVASCRIPT &CSSWeb isa book outlet and our website is abook
  • 2.
    Agenda•••••Basics to Html,CSS, JavaScriptWhere this fits in Website developmentDebuggingExamplesQ/A
  • 3.
    Introduction•Core Concept ofweb development••HTML + CSS + JavaScriptContent + Style + Behavior
  • 4.
    HTML• What?• Webserver: a system on the internet contains one or more web site• Web site: a collection of one or more web pages• Web pages: single disk file with a single file name• Home pages: first page in websiteo What for ?• Think about the sort of information(content) you want to put on the Web.• Set the goals for the Web site.• Organize your content into main topics.• Come up with a general structure for pages and topics.
  • 5.
  • 6.
    HTML••HTML is nota programming language, it is a markup languageHTML markup tags are usually called HTML tagsoooo•••HTML tags are keywords surrounded by angle brackets like <html>HTML tags normally come in pairs like <b> and </b>The first tag in a pair is the start tag, the second tag is the end tagStart and end tags are also called opening tags and closing tagsHTML documents describe web pagesThe purpose of a web browser (like Internet Explorer or Firefox) is toread HTML documents and display them as web pages. The browserdoes not display the HTML tags, but uses the tags to interpret thecontent of the pageNote:••••The text between <html> and </html> describes the web pageThe text between <body> and </body> is the visible page contentThe text between <h1> and </h1> is displayed as a headingThe text between <p> and </p> is displayed as a paragraph
  • 7.
    HTML••When you savean HTML file, you can use either the .htm or the .htmlfile extensionElements:Start tag *<p><ahref="default.htm" ><br />Element content End tag *This is a</p>paragraphThis is a link</a>
  • 8.
    HTML•HTML Attributesoooo•HTML elementscan have attributesAttributes provide additional information about an elementAttributes are always specified in the start tagAttributes come in name/value pairs like: name="value“Sample Attributes:Attribute ValueDescriptionclassclassname Specifies a classname for anelementididSpecifies a unique id for anelementstylestyle_defin Specifies an inline style for anitionelementtitletooltip_tex Specifies extra informationtabout an element (displayedas a tool tip)
  • 9.
    HTML•Website Layoutso•HTML DifferentDoctypeso•External style sheetInternal style sheetInline stylesHtml head element:o•The doctype declaration is not an HTML tag; it is an instruction to the web browserabout what version of the markup language the page is written in.There are three ways of inserting a style sheet:ooo•Most websites have put their content in multiple columns (formatted like a magazineor newspaper)Head,Script,Base,Style,meta,titleThe HTML noscript ElementoThe <noscript> tag is used to provide an alternate content for users that havedisabled scripts in their browser or have a browser that doesn’t support client-sidescripting.
  • 10.
  • 11.
    CSS•••The biggest advantageof using CSS is that, if you place the CSScode in an external style sheet, your site becomes MUCH EASIER tomaintain. You can change the layout of all your pages by editingone fileSeparates design elements from structural logicRule Structure:
  • 12.
    CSS•Class Selectors<H1 CLASS=“warning”>Danger!</H1><PCLASS=“warning”>Be careful…</P>…….In your HTML code H1.warning {color: red;}OR to an entire class….warning {color:red;}• Css are not even• Make sure your CSS properties are supported
  • 13.
    CSSPatternMeaning*Universal selector: matchesany element.EType selector: matches any E element (i.e., an element of type E; e.g. H1 or P).EFDescendant selector: matches any F element that is a descendant of an E element.E>FChild selector: matches any F element that is a child of an element E.E+FAdjacent siblings selector: Matches any F element immediately preceded by an element E.E[foo]Attribute selector: matches any E element with the "foo" attribute set (whatever the value).E[foo="warning"]Attribute selector: matches any E element whose "foo" attribute value is exactly equal to "warning".E[foo~="warning"]Attribute selector: matches any E element whose "foo" attribute value is a list of space-separatedvalues, one of which is exactly equal to "warning".E[lang|="en"]Attribute selector: matches any E element whose "lang" attribute has a hyphen-separated list ofvalues beginning (from the left) with "en“ (e.g. en-US).DIV.warningHTML only. The same as DIV[class~="warning"].E#myidID selector: matches any E element ID equal to "myid".E:lang(c)Pseudo-class selector: matches element of type E if it is in (human) language c (the documentlanguage specifies how language is determined).E:first-childPseudo-class selector: matches element E when E is the first child of its parent.E:link, E:visitedPseudo-class selector: matches element E if E is the source anchor of a hyperlink of which thetarget is not yet visited (:link) or already visited (:visited).E:active, E:hover, E:focusDynamic Pseudo-class selector: matches E during certain user actions.E:first-line, E:first-letterPseudo-element selector: matches the first formatted line or letter of element E.
  • 14.
    JavaScript•••••••••#"https://www.slideshare.net/slideshow/htmljavascript-css/29381671#15">JavaScript• Eventso Eventsare mostly caused by user actions.o We want our JavaScript program to react to certain events. Thiscan be done with the help of event-handlerso example of the event-handler onClick: <form><inputtype="button" value="Click me" onClick="alert(’Yo’)"></form> whynot onClick="alert(“Yo”)“?o Events are normally used in combination with functions, and thefunction will not be executed before the event occurs!o Eg: <html> <head> <script type="text/javascript"> <!-- functionpopup() { alert("Hello World") } //--> </script> </head> <body><input type="button" value="Click Me!" onclick="popup()"><br /><a href="#" onmouseover="" onMouseout="popup()"> HoverMe!</a> </body> </html>
  • 16.
    JavaScript• EventsEventAttributeDescriptionDOMclickonclickThe eventoccurs when the user clicks on an element2dblclickondblclickThe event occurs when the user double-clicks on anelement2mousedownonmousedownThe event occurs when a user presses a mouse buttonover an element2mousemoveonmousemoveThe event occurs when a user moves the mouse pointer 2over an elementmouseoveronmouseoverThe event occurs when a user mouse over an elementmouseoutonmouseoutThe event occurs when a user moves the mouse pointer 2out of an elementmouseuponmouseupThe event occurs when a user releases a mouse buttonover an element22
  • 17.
    JavaScript• Variableso Variablesare used to store data.o A variable is a "container" for information youwant to store. A variable's value can changeduring the script. You can refer to a variable byname to see its value or to change its value.o Rules for variable names:o Variable names are case sensitiveo They must begin with a letter or the underscorecharacter• strname – STRNAME (not same)
  • 18.
    JavaScript• Event HierarchyoTake the case of a Login Page
  • 19.
    JavaScript• JavaScript No'soGlobal variables• var foo = "global"; //Don't do this function(){ var bar = "local"; //This is ok }();• function(){ foo = "global"; //Don't do this var bar = "local"; //This is ok }();o Inline JavaScript• Inline JavaScript is any JavaScript code that is mixed with HTML. There are twoprimary ways in which you can do this:o Eval• Also like most other programming languages, using eval in JavaScript isconsidered.. well, evil. If you find yourself using eval, there’s a big chance yourapproach is wrong.• Eg:var strJSON = '{"result":true,"count":1}';var objJSON = eval("(function(){return " + strJSON + ";})()");alert(objJSON.result);alert(objJSON.count);
  • 20.
    JavaScript• JavaScript No'soalert("In your face")• Most of the time, using the alert method is unnecessary. The most prevalentmisuse of this method is for debugging purposes, but using tools such as Firebugand equivalents for other browsers is a much better and more efficient way todebug JavaScript code.o element.style• You can change an element’s style directly by changing properties on its styleproperty:• el.style.backgroundColor = "#ff0000";el.style.color = "#00ff00"; This is usually not agood idea because you want to keep the styling separate from the behaviourand changing an element’s style directly will override anything you’ve definedin your CSS. Better way here is to add a class to the element
  • 21.
  • 22.

[8]ページ先頭

©2009-2025 Movatter.jp