SlideShare a Scribd company logo
2
Most read
8
Most read
9
Most read
JAVASCRIPT
Presented By :- Vishal
15-CSE-2835
Content
• What is JavaScript ?
• History & Versions
• JavaScript Over Java
• Elements of JavaScript
• Applications
• Advantages
• Cautions
What is JavaScript ?
• JavaScript is the programming language for HTML and
the Web.
• It is similar to C language.
History
• First web scripting language.
• It was developed by Netscape & Sun.
• The first version of the Web browser, Mosaic Netscape
0.9, was released in late 1994.
Versions
Version Release Supported
Browser
1.0 March 1996 Netscape 2
1.1 August 1996 Netscape 3
1.2 June 1997 Netscape 4
1.3 October 1998 Netscape 4.06
1.5 November 2000 Netscape 6
1.6 November 2005 Firefox 1.5
1.7 October 2006 Firefox 2
1.8 June 2008 Firefox 3
1.8.1 2009 Firefox 3.5
1.8.2 June 22, 2009 Firefox 3.6
1.8.5 July 27, 2010 Firefox 4
HTML, CSS & JAVASCRIPT
JavaScript is one of the 3 languages all web
developers must learn:
•    1. HTML to define the content of web pages
•    2. CSS to specify the layout of web pages
•    3. JavaScript to program the behavior of web
pages
JavaScript Over Java
Java JavaScript
1.) Java is an OOP
programming language
1.) Java Script is an OOP
scripting language
2.) Java codes is run in a
virtual machine or browser
2.) JavaScript code is run on
a browser only
3.) Java code needs to be
compiled
3.) JavaScript code are all in
text
Elements of JavaScript
• Variables
• Arrays
• Functions
Variables
<script language=“JavaScript”>
<!-- definition of variables-->
var num_car= 25;
var passenger_per_car= 3;
//calculation of total number of people
var total_passenger= num_car * passenger_per_car
Alert(total_passenger);
// end of script -->
</script>
Arrays
var score = new Array(3);
score[0] = 35;
score[1] = 56;
score[2] = 10;
sum=score[0]+score[1]+score[2];
alert(sum) ;
Function
<html>
<head>
<script langauge="JavaScript">
<!-- hide me
function announceTime( ) { //get the date, the hour, minutes, and seconds
var the_date = new Date();
var the_hour = the_date.getHours();
var the_minute = the_date.getMinutes();
var the_second = the_date.getSeconds(); //put together the string and alert with it
var the_time = the_hour + ":" + the_minute + ":" + the_second;
alert("The time is now: " + the_time); } // show me -->
</script>
Cont…
</head>
<body>
<h3>Click the button to get current Date and time</h3>
<input type="button" value=“Show Date" onclick=“announceTime()“/>
</body>
</html>
Applications
• Show slideshow of Images
• Show dropdown menu
• Data checking in forms in client side
• Pop ups in web pages
• Auto pages refresh after a certain time
Advantages
• JavaScript is executed on the client side.
• JavaScript is a relatively easy language.
• JavaScript is relatively fast to the end user.
• Extended functionality to web pages.
• JavaScript is very case sensitive
• Use separate lines for each command
• Be careful with parenthesis and quotes
• Use single quotes within double quotes
• Use a semi-colon after commands as shown in
examples
Cautions...
Thanks…

More Related Content

What's hot (20)

PPT
Javascript
Manav Prasad
 
PPT
javaScript.ppt
sentayehu
 
PDF
JavaScript - Chapter 8 - Objects
WebStackAcademy
 
PPSX
Javascript variables and datatypes
Varun C M
 
PPT
Introduction to Javascript
Amit Tyagi
 
PDF
CSS framework By Palash
PalashBajpai
 
PPTX
Html5 tutorial for beginners
Singsys Pte Ltd
 
PPTX
Java script
Abhishek Kesharwani
 
PDF
jQuery for beginners
Arulmurugan Rajaraman
 
PDF
JavaScript - Chapter 11 - Events
WebStackAcademy
 
PDF
JavaScript Programming
Sehwan Noh
 
PPTX
HTML5 & CSS3
Ian Lintner
 
PPTX
Javascript functions
Alaref Abushaala
 
PPT
Javascript arrays
Hassan Dar
 
PPTX
html5.ppt
Niharika Gupta
 
PPT
Introduction to JavaScript
Andres Baravalle
 
PPTX
Java script
Shyam Khant
 
PPT
Cookies and sessions
Lena Petsenchuk
 
PPT
Js ppt
Rakhi Thota
 
PPT
JavaScript Tutorial
Bui Kiet
 
Javascript
Manav Prasad
 
javaScript.ppt
sentayehu
 
JavaScript - Chapter 8 - Objects
WebStackAcademy
 
Javascript variables and datatypes
Varun C M
 
Introduction to Javascript
Amit Tyagi
 
CSS framework By Palash
PalashBajpai
 
Html5 tutorial for beginners
Singsys Pte Ltd
 
Java script
Abhishek Kesharwani
 
jQuery for beginners
Arulmurugan Rajaraman
 
JavaScript - Chapter 11 - Events
WebStackAcademy
 
JavaScript Programming
Sehwan Noh
 
HTML5 & CSS3
Ian Lintner
 
Javascript functions
Alaref Abushaala
 
Javascript arrays
Hassan Dar
 
html5.ppt
Niharika Gupta
 
Introduction to JavaScript
Andres Baravalle
 
Java script
Shyam Khant
 
Cookies and sessions
Lena Petsenchuk
 
Js ppt
Rakhi Thota
 
JavaScript Tutorial
Bui Kiet
 

Viewers also liked (18)

PPTX
Subject Matter
emileeyy
 
PPTX
Social networking
Tafadzwa Gonera
 
PPTX
Collaborating Online: Tools to Create Effective Virtual Workgroups
St. Petersburg College
 
PPTX
Projectppt
AjitPanadaKumar
 
PDF
Domain Name System (DNS)
Thiago Sinésio
 
PDF
JavaScript - From Birth To Closure
Robert Nyman
 
PPTX
Net Neutrality PPT
Dylan Lee
 
PPT
Mac309 Network Effect: Net Neutrality
Rob Jewitt
 
PPTX
DNS(Domain Name System)
Vishal Mittal
 
PPTX
Final presentation: Net Neutrality
Joey Dweck
 
PPTX
Net neutrality
Bhupender Thakur
 
PPT
Javascript
guest03a6e6
 
PPT
Microprocessor ppt
swaminath kanhere
 
PPT
JavaScript - An Introduction
Manvendra Singh
 
PPT
Chapter 7 multiple access techniques
Kaushal Kabra
 
PDF
DNS - Domain Name System
Peter R. Egli
 
PPTX
Logic gates - AND, OR, NOT, NOR, NAND, XOR, XNOR Gates.
Satya P. Joshi
 
Subject Matter
emileeyy
 
Social networking
Tafadzwa Gonera
 
Collaborating Online: Tools to Create Effective Virtual Workgroups
St. Petersburg College
 
Projectppt
AjitPanadaKumar
 
Domain Name System (DNS)
Thiago Sinésio
 
JavaScript - From Birth To Closure
Robert Nyman
 
Net Neutrality PPT
Dylan Lee
 
Mac309 Network Effect: Net Neutrality
Rob Jewitt
 
DNS(Domain Name System)
Vishal Mittal
 
Final presentation: Net Neutrality
Joey Dweck
 
Net neutrality
Bhupender Thakur
 
Javascript
guest03a6e6
 
Microprocessor ppt
swaminath kanhere
 
JavaScript - An Introduction
Manvendra Singh
 
Chapter 7 multiple access techniques
Kaushal Kabra
 
DNS - Domain Name System
Peter R. Egli
 
Logic gates - AND, OR, NOT, NOR, NAND, XOR, XNOR Gates.
Satya P. Joshi
 
Ad

Similar to Javascript Basics (20)

PDF
CS8651- Unit 2 - JS.internet programming paper anna university -2017 regulation
amrashbhanuabdul
 
PPTX
Client side scripting using Javascript
Bansari Shah
 
PPTX
JavaScript New Tutorial Class XI and XII.pptx
rish15r890
 
PPT
Java script
Soham Sengupta
 
PPTX
Java script
Anuj Singh Rajput
 
PDF
java-scriptcdvcx vnbm,azsdfghjkml;sxdfcgmndxfcgvhb nmfctgvbhjnm ,cfgvb nm,xc ...
kavigamage62
 
PPTX
CHAPTER 3 JS (1).pptx
achutachut
 
PPTX
Chapter 3 INTRODUCTION TO JAVASCRIPT S.pptx
KelemAlebachew
 
DOCX
Basic Java script handouts for students
shafiq sangi
 
PPTX
JavaScript_III.pptx
rashmiisrani1
 
PPTX
Javascript Basics by Bonny
Bonny Chacko
 
PDF
javascriptPresentation.pdf
wildcat9335
 
PPTX
HNDIT1022 Week 08, 09 10 Theory web .pptx
IsuriUmayangana
 
PPTX
Lecture 5 javascript
Mujtaba Haider
 
PPT
JAVA SCRIPT
Go4Guru
 
PDF
Unit 4(it workshop)
Dr.Lokesh Gagnani
 
DOC
Basics java scripts
ch samaram
 
PPTX
WT Module-3.pptx
RamyaH11
 
PPTX
Java script
Jay Patel
 
CS8651- Unit 2 - JS.internet programming paper anna university -2017 regulation
amrashbhanuabdul
 
Client side scripting using Javascript
Bansari Shah
 
JavaScript New Tutorial Class XI and XII.pptx
rish15r890
 
Java script
Soham Sengupta
 
Java script
Anuj Singh Rajput
 
java-scriptcdvcx vnbm,azsdfghjkml;sxdfcgmndxfcgvhb nmfctgvbhjnm ,cfgvb nm,xc ...
kavigamage62
 
CHAPTER 3 JS (1).pptx
achutachut
 
Chapter 3 INTRODUCTION TO JAVASCRIPT S.pptx
KelemAlebachew
 
Basic Java script handouts for students
shafiq sangi
 
JavaScript_III.pptx
rashmiisrani1
 
Javascript Basics by Bonny
Bonny Chacko
 
javascriptPresentation.pdf
wildcat9335
 
HNDIT1022 Week 08, 09 10 Theory web .pptx
IsuriUmayangana
 
Lecture 5 javascript
Mujtaba Haider
 
JAVA SCRIPT
Go4Guru
 
Unit 4(it workshop)
Dr.Lokesh Gagnani
 
Basics java scripts
ch samaram
 
WT Module-3.pptx
RamyaH11
 
Java script
Jay Patel
 
Ad

Recently uploaded (20)

PPTX
Element 11. ELECTRICITY safety and hazards
merrandomohandas
 
PPTX
Heart Bleed Bug - A case study (Course: Cryptography and Network Security)
Adri Jovin
 
PDF
Water Industry Process Automation & Control Monthly July 2025
Water Industry Process Automation & Control
 
PDF
Introduction to Productivity and Quality
মোঃ ফুরকান উদ্দিন জুয়েল
 
PPTX
Damage of stability of a ship and how its change .pptx
ehamadulhaque
 
PPTX
Element 7. CHEMICAL AND BIOLOGICAL AGENT.pptx
merrandomohandas
 
PPTX
MobileComputingMANET2023 MobileComputingMANET2023.pptx
masterfake98765
 
PPTX
GitOps_Without_K8s_Training_detailed git repository
DanialHabibi2
 
PDF
Zilliz Cloud Demo for performance and scale
Zilliz
 
PPT
Carmon_Remote Sensing GIS by Mahesh kumar
DhananjayM6
 
PDF
Biomechanics of Gait: Engineering Solutions for Rehabilitation (www.kiu.ac.ug)
publication11
 
PPTX
DATA BASE MANAGEMENT AND RELATIONAL DATA
gomathisankariv2
 
PDF
Pressure Measurement training for engineers and Technicians
AIESOLUTIONS
 
PDF
Viol_Alessandro_Presentazione_prelaurea.pdf
dsecqyvhbowrzxshhf
 
PDF
GTU Civil Engineering All Semester Syllabus.pdf
Vimal Bhojani
 
DOC
MRRS Strength and Durability of Concrete
CivilMythili
 
PPTX
fatigue in aircraft structures-221113192308-0ad6dc8c.pptx
aviatecofficial
 
PDF
International Journal of Information Technology Convergence and services (IJI...
ijitcsjournal4
 
PPTX
Green Building & Energy Conservation ppt
Sagar Sarangi
 
PDF
AI TECHNIQUES FOR IDENTIFYING ALTERATIONS IN THE HUMAN GUT MICROBIOME IN MULT...
vidyalalltv1
 
Element 11. ELECTRICITY safety and hazards
merrandomohandas
 
Heart Bleed Bug - A case study (Course: Cryptography and Network Security)
Adri Jovin
 
Water Industry Process Automation & Control Monthly July 2025
Water Industry Process Automation & Control
 
Introduction to Productivity and Quality
মোঃ ফুরকান উদ্দিন জুয়েল
 
Damage of stability of a ship and how its change .pptx
ehamadulhaque
 
Element 7. CHEMICAL AND BIOLOGICAL AGENT.pptx
merrandomohandas
 
MobileComputingMANET2023 MobileComputingMANET2023.pptx
masterfake98765
 
GitOps_Without_K8s_Training_detailed git repository
DanialHabibi2
 
Zilliz Cloud Demo for performance and scale
Zilliz
 
Carmon_Remote Sensing GIS by Mahesh kumar
DhananjayM6
 
Biomechanics of Gait: Engineering Solutions for Rehabilitation (www.kiu.ac.ug)
publication11
 
DATA BASE MANAGEMENT AND RELATIONAL DATA
gomathisankariv2
 
Pressure Measurement training for engineers and Technicians
AIESOLUTIONS
 
Viol_Alessandro_Presentazione_prelaurea.pdf
dsecqyvhbowrzxshhf
 
GTU Civil Engineering All Semester Syllabus.pdf
Vimal Bhojani
 
MRRS Strength and Durability of Concrete
CivilMythili
 
fatigue in aircraft structures-221113192308-0ad6dc8c.pptx
aviatecofficial
 
International Journal of Information Technology Convergence and services (IJI...
ijitcsjournal4
 
Green Building & Energy Conservation ppt
Sagar Sarangi
 
AI TECHNIQUES FOR IDENTIFYING ALTERATIONS IN THE HUMAN GUT MICROBIOME IN MULT...
vidyalalltv1
 

Javascript Basics

  • 1. JAVASCRIPT Presented By :- Vishal 15-CSE-2835
  • 2. Content • What is JavaScript ? • History & Versions • JavaScript Over Java • Elements of JavaScript • Applications • Advantages • Cautions
  • 3. What is JavaScript ? • JavaScript is the programming language for HTML and the Web. • It is similar to C language.
  • 4. History • First web scripting language. • It was developed by Netscape & Sun. • The first version of the Web browser, Mosaic Netscape 0.9, was released in late 1994.
  • 5. Versions Version Release Supported Browser 1.0 March 1996 Netscape 2 1.1 August 1996 Netscape 3 1.2 June 1997 Netscape 4 1.3 October 1998 Netscape 4.06 1.5 November 2000 Netscape 6 1.6 November 2005 Firefox 1.5 1.7 October 2006 Firefox 2 1.8 June 2008 Firefox 3 1.8.1 2009 Firefox 3.5 1.8.2 June 22, 2009 Firefox 3.6 1.8.5 July 27, 2010 Firefox 4
  • 6. HTML, CSS & JAVASCRIPT JavaScript is one of the 3 languages all web developers must learn: •    1. HTML to define the content of web pages •    2. CSS to specify the layout of web pages •    3. JavaScript to program the behavior of web pages
  • 7. JavaScript Over Java Java JavaScript 1.) Java is an OOP programming language 1.) Java Script is an OOP scripting language 2.) Java codes is run in a virtual machine or browser 2.) JavaScript code is run on a browser only 3.) Java code needs to be compiled 3.) JavaScript code are all in text
  • 8. Elements of JavaScript • Variables • Arrays • Functions
  • 9. Variables <script language=“JavaScript”> <!-- definition of variables--> var num_car= 25; var passenger_per_car= 3; //calculation of total number of people var total_passenger= num_car * passenger_per_car Alert(total_passenger); // end of script --> </script>
  • 10. Arrays var score = new Array(3); score[0] = 35; score[1] = 56; score[2] = 10; sum=score[0]+score[1]+score[2]; alert(sum) ;
  • 11. Function <html> <head> <script langauge="JavaScript"> <!-- hide me function announceTime( ) { //get the date, the hour, minutes, and seconds var the_date = new Date(); var the_hour = the_date.getHours(); var the_minute = the_date.getMinutes(); var the_second = the_date.getSeconds(); //put together the string and alert with it var the_time = the_hour + ":" + the_minute + ":" + the_second; alert("The time is now: " + the_time); } // show me --> </script>
  • 12. Cont… </head> <body> <h3>Click the button to get current Date and time</h3> <input type="button" value=“Show Date" onclick=“announceTime()“/> </body> </html>
  • 13. Applications • Show slideshow of Images • Show dropdown menu • Data checking in forms in client side • Pop ups in web pages • Auto pages refresh after a certain time
  • 14. Advantages • JavaScript is executed on the client side. • JavaScript is a relatively easy language. • JavaScript is relatively fast to the end user. • Extended functionality to web pages.
  • 15. • JavaScript is very case sensitive • Use separate lines for each command • Be careful with parenthesis and quotes • Use single quotes within double quotes • Use a semi-colon after commands as shown in examples Cautions...

Editor's Notes

  • #16: &amp;lt;number&amp;gt;