Announcements Due dates extended: Project 1B—Wednesday by 10pm 1-1-1 rule Thursday by 10pm Lab 5—Friday by 10pm Next week Labs 6/7—Tuesday by 10pm 11/19/2015D.A.

Slides:



Advertisements
Similar presentations
Essentials for Design JavaScript Level One Michael Brooks
Advertisements

Java Script Session1 INTRODUCTION.
Computers Are Your Future
CS105 INTRODUCTION TO COMPUTER CONCEPTS INTRO TO PROGRAMMING Instructor: Cuong (Charlie) Pham.
Understand Web Page Development Software Development Fundamentals LESSON 4.1.
Languages for Dynamic Web Documents
Chapter Concepts Review Markup Languages
Lecture 3B: Client-Side Scripting IT 202—Internet Applications Based on notes developed by Morgan Benton.
Computer Concepts 5th Edition Parsons/Oja Page 546 CHAPTER 11 Software Engineering Section A PARSONS/OJA Computer Programming.
XP 1 Working with JavaScript Creating a Programmable Web Page for North Pole Novelties Tutorial 10.
Russell Taylor Lecturer in Computing & Business Studies.
An Introduction to Programming with C++ Fifth Edition Chapter 1 An Introduction to Programming.
Mgt 240 Lecture Website Construction: Software and Language Alternatives March 29, 2005.
2012 •••••••••••••••••••••••••••••••••• Summer WorkShop Mostafa Badr
Programming Concepts and Languages Chapter 12 – Computers: Understanding Technology, 3 rd edition 1November
CSE 1301 J Lecture 2 Intro to Java Programming Richard Gesick.
* The basic components of a web site are: * Content – information displayed or accepted from users * Static – content that doesn’t change for different.
© Paradigm Publishing Inc Chapter 12 Programming Concepts and Languages.
JavaScript CMPT 281. Outline Introduction to JavaScript Resources What is JavaScript? JavaScript in web pages.
INTRODUCTION TO WEB DATABASE PROGRAMMING
Chapter 1 Coding Introduction.
1 CS 3870/CS 5870 Static and Dynamic Web Pages ASP.NET and IIS.
FALL 2005CSI 4118 – UNIVERSITY OF OTTAWA1 Part 4 Web technologies: HTTP, CGI, PHP,Java applets)
Programming Languages
HTML Forms and Scripts. Session overview What are forms? Static vs dynamic Client-side scripts –JavaScript.
1 CS 3870/CS 5870 Static and Dynamic Web Pages ASP.NET and IIS.
JavaScript, Fifth Edition Chapter 1 Introduction to JavaScript.
COMPUTER SOFTWARE Section 2 “System Software: Computer System Management ” CHAPTER 4 Lecture-6/ T. Nouf Almujally 1.
Chapter 16 The World Wide Web Chapter Goals Compare and contrast the Internet and the World Wide Web Describe general Web processing Describe several.
COMPUTER PROGRAMMING Source: Computing Concepts (the I-series) by Haag, Cummings, and Rhea, McGraw-Hill/Irwin, 2002.
Programming. What is a Program ? Sets of instructions that get the computer to do something Instructions are translated, eventually, to machine language.
Client Scripting1 Internet Systems Design. Client Scripting2 n “A scripting language is a programming language that is used to manipulate, customize,
20-753: Fundamentals of Web Programming 1 Lecture 1: Introduction Fundamentals of Web Programming Lecture 1: Introduction.
XP Tutorial 10New Perspectives on Creating Web Pages with HTML, XHTML, and XML 1 Working with JavaScript Creating a Programmable Web Page for North Pole.
JavaScript – Quiz #9 Lecture Code:
JavaScript Tutorial 1 - Introduction to JavaScript WDMD 170 – UW Stevens Point 1 WDMD 170 Internet Languages eLesson: Introduction to JavaScript (NON.
Extending HTML CPSC 120 Principles of Computer Science April 9, 2012.
Web Pages with Features. Features on Web Pages Interactive Pages –Shows current date, get server’s IP, interactive quizzes Processing Forms –Serach a.
JavaScript Tutorial 1 - Introduction to JavaScript1 Tutorial 1 Introduction to JavaScript Section A – Programming, HTML, and JavaScript.
RUBRIC IP1 Ruben Botero Web Design III. The different approaches to accessing data in a database through client-side scripting languages. – On the client.
J ava P rogramming: From Problem Analysis to Program Design, From Problem Analysis to Program Design, Second Edition Second Edition D.S. Malik D.S. Malik.
JavaScript Defined JavaScript Basics Definitions JavaScript is an object-oriented programming language designed for the world wide web. JavaScript code.
Web Pages with Features. Features on Web Pages Interactive Pages –Shows current date, get server’s IP, interactive quizzes Processing Forms –Serach a.
Client-side & Server-side Scripting ©Richard L. Goldman August 5, 2003 Requires PowerPoint 2002 or later for full functionality.
By Tharith Sriv. To write a web page you use: HHTML (HyperText Markup Language), AASP (Active Server Page), PPHP (HyperText Preprocessor), JJavaScript,
CSC1200 INTRODUCTION TO PROGRAMMING Dr. Maureen Markel
Scripting Languages Client Side and Server Side. Examples of client side/server side Examples of client-side side include: JavaScript Jquery (uses a JavaScript.
Introduction to JavaScript Fort Collins, CO Copyright © XTR Systems, LLC Introduction to JavaScript Programming Instructor: Joseph DiVerdi, Ph.D., MBA.
JavaScript 101 Introduction to Programming. Topics What is programming? The common elements found in most programming languages Introduction to JavaScript.
The single most important skill for a computer programmer is problem solving Problem solving means the ability to formulate problems, think creatively.
Java Script. What is JavaScript ? It is an scripting language, developed by Netscape Navigator. It can be used to replace CGI scripts for client-side.
Content Management Systems. Agenda Week overview Web-page basics The why and what of CMS Typo3.
1 CSC160 Chapter 1: Introduction to JavaScript Chapter 2: Placing JavaScript in an HTML File.
IN THIS LESSON WE WILL REVIEW THE STRUCTURE OF THE INTERNET AND HOW BROWSERS ASSEMBLE WEBSITES BASED ON INSTRUCTIONS THEY RECEIVE FROM SERVERS. Internet.
XP Tutorial 10New Perspectives on HTML, XHTML, and DHTML, Comprehensive 1 Working with JavaScript Creating a Programmable Web Page for North Pole Novelties.
JavaScript Invented 1995 Steve, Tony & Sharon. A Scripting Language (A scripting language is a lightweight programming language that supports the writing.
1 Chapter 1 INTRODUCTION TO WEB. 2 Objectives In this chapter, you will: Become familiar with the architecture of the World Wide Web Learn about communication.
Web Development. Agenda Web History Network Architecture Types of Server The languages of the web Protocols API 2.
Chapter 1 Coding Introduction.
Topic 2: Hardware and Software
JavaScripts.
CIS 388 Internet Programming
CSCI-235 Micro-Computer Applications
W3C Web standards and Recommendations
JavaScript Introduction
Chapter 1 Coding Introduction.
and Program Development
An Introduction to Programming with C++ Fifth Edition
An Introduction to JavaScript
CS105 Introduction to Computer Concepts Intro to programming
Presentation transcript:

Announcements Due dates extended: Project 1B—Wednesday by 10pm rule Thursday by 10pm Lab 5—Friday by 10pm Next week Labs 6/7—Tuesday by 10pm 11/19/2015D.A. Clements, MLIS, UW iSchool 1

Announcements Vocabulary for the week has been posted in GoPost Reading Ch 18 for today and Wednesday Ch 21 for Friday 11/19/2015D.A. Clements, MLIS, UW iSchool 2

Programs Defined A program is an algorithm written for a specific programming language and specific circumstances D.A. Clements, MLIS, UW iSchool 3 11/19/2015

TYPES OF PROGRAMMING LANGUAGES D.A. Clements, MLIS, UW iSchool 4 11/19/2015

High- vs. Low-Level Languages 11/19/2015D.A. Clements, MLIS, UW iSchool 5 HIGH-LEVEL Humans Understand FortranC, C++, C#JavaScript High-Level Language Assembly Language Machine Language LOW-LEVEL Computers Understand Translated

Human-Understandable Code Today’s programs are written in “high-level” language (HLL) that we can understand (and debug) HLL use “real” words—if, while, when, until, push, pop, print, set, etc. Words look like English Have a precisely defined meaning for the computer Make it easier for us to understand (and troubleshoot) For example: if (today==‘Wednesday’) print “I have lecture today!” else print “Tonight is time to study!” D.A. Clements, MLIS, UW iSchool 6 11/19/2015

Videos High- and low-level programming languages 11/19/2015D.A. Clements, MLIS, UW iSchool 7

Assembly language The lowest level language humans can understand Example LOOP: MOV.B r0, #80 ;initialize counter 11/19/2015D.A. Clements, MLIS, UW iSchool 8

What computers understand Machine code Assembly code is translated to binary: Binary is how computer stores information all zeroes and ones Magnetized or not Off or on Bumpy surface on the CD or not 11/19/2015D.A. Clements, MLIS, UW iSchool 9

Machine code 11/19/2015D.A. Clements, MLIS, UW iSchool 10

Translating human to machine 11/19/2015D.A. Clements, MLIS, UW iSchool 11 HIGH-LEVEL Humans Understand FortranC, C++, C#JavaScript High-Level Language Assembly Language Machine Language LOW-LEVEL Computers Understand Translated

Compiled Languages Compiled languages are translated to machine code (assembly language) before they are run. Whenever you make changes to your program, you have to recompile the program again. Because they already speak the computer’s language, they run faster. Sometimes, they run by themselves—.exe files (NotePad2.exe)—or run with an engine (the Java virtual engine). D.A. Clements, MLIS, UW iSchool 12 11/19/2015

Compiled Languages Examples: Java C family Visual Basic COBOL ForTRAN many others D.A. Clements, MLIS, UW iSchool 13 11/19/2015

INTERPRETED LANGUAGES Also called scripting languages D.A. Clements, MLIS, UW iSchool 14 11/19/2015

Interpreted Languages An interpreter translates from JavaScript to machine language while the Web browser renders the page The interpreter is part of the Web browser. The JavaScript interpreter is available in all major Web browsers D.A. Clements, MLIS, UW iSchool 15 11/19/2015

How the Interpreter Works The interpreter translates the script to machine language while the program runs! Two tasks at once—translating and running the program! Scripts run slower than compiled programs D.A. Clements, MLIS, UW iSchool 16 11/19/2015

The Advantages… Scripted languages are interpreted on the fly—while they are running Make changes while the program is running! Provides a dynamic, responsive, and interactive experience for the user Scripts respond to user input D.A. Clements, MLIS, UW iSchool 17 11/19/2015

JAVASCRIPT All about D.A. Clements, MLIS, UW iSchool 18 11/19/2015

JavaScript Java was developed by Sun Microsystems and is seen on the Web mostly in Java Applets. D.A. Clements, MLIS, UW iSchool 19 11/19/2015 JavaScript is not Java!

Brief History of JavaScript Released with Netscape Navigator in Ratified by the European Equipment Manufacturer’s Association (ECMA) Result: ECMAScript is the core spec for the JavaScript language Netscape, MS, and the others try to conform to the spec D.A. Clements, MLIS, UW iSchool 20 11/19/2015

Divergence from standards…. Programmers call both JavaScript. Both comply differently with the standards D.A. Clements, MLIS, UW iSchool 21 11/19/2015 DeveloperName Netscape (now Mozilla)JavaScript MicrosoftJScript

Javascript & the Web Adding interaction to a static HTML page D.A. Clements D.A. Clements, MLIS, UW iSchool 22 11/19/2015

Objectives Understand how JavaScript and HTML interact Understand where to place JavaScripts on the HTML page 11/19/2015D.A. Clements, MLIS, UW iSchool 23

Programming Concepts Programming: Act of formulating an algorithm or program Basic concepts have been developed over last 50 years to simplify common programming tasks Concepts will be expressed in JavaScript

The Web page Without JavaScript the Web page is like a brick; it just sits there! 11/19/2015D.A. Clements, MLIS, UW iSchool 25

Scripts Client-side scripts Your Web browser on your computer is the client Server-side scripts Web server Database server File server 11/19/2015D.A. Clements, MLIS, UW iSchool 26 Client Server

Web browser and JavaScript The major Web browsers have a built-in interpreter that parses JavaScript Parses: breaks into smaller pieces that can be translated into machine code 11/19/2015D.A. Clements, MLIS, UW iSchool 27

Placing JavaScripts on a Web page Types of scripts: Body scripts Header scripts External scripts D.A. Clements, MLIS, UW iSchool 28 11/19/2015

Body Script Name of Page //JavaScript goes here D.A. Clements, MLIS, UW iSchool 29 11/19/2015

Header Script Name of Page <script type=“text/javascript” //JavaScript goes here Body content goes here D.A. Clements, MLIS, UW iSchool 30 11/19/2015

Linking to External JavaScripts Linked in the src gives path to file and its name Name of Page Body content goes here D.A. Clements, MLIS, UW iSchool 31 11/19/2015

External JavaScripts Make changes to scripts in one place Reusable Link to any page, every page, or many sites D.A. Clements, MLIS, UW iSchool 32 11/19/2015

Best Practice Best practice to separate Content from Action from Appearance Put styles in external CSS Put scripts in external JavaScript files Leave only the HTML markup and content on the page Accomplishing that goal takes more experience…. 11/19/ D.A. Clements, MLIS, UW iSchool

Summary Understand how JavaScript and HTML interact Understand where to place JavaScripts on the HTML page 11/19/2015D.A. Clements, MLIS, UW iSchool 34