Interactive Web Application

Size: px
Start display at page:

Download "Interactive Web Application"

Transcription

1 Interactive Web Application

2 This lesson builds on previous lessons With this lesson we will be picking up right where we left off from our Node.js Hosting lesson. The presentation can be found at You can also use this direct link. For a quick catch up (not recommended) the full example code can be downloaded here, and you can do the AppFog setup and deployment detailed on slides 34 through 46 of the presentation. We'll also be using code we wrote in Intro to Node.js lesson, however it is reproduced here as well.

3 Interactive websites have output that changes depending on user input So far we've created and deployed a website with multiple routes that serves up HTML, CSS, and images This website will be the same for every person that visits it, so it can be called static. These websites are ok. True web applications accept and respond to user input. These are called interactive web sites. Its time to make our website interactive!

4 Information can be sent in the route as parameters Instead of saying Hello, World! Lets optionally have it be able to say hello to somebody's name. One way we can do this, is with a route parameter. Route parameters are part of a route that we are defining as being a parameter. Parameters are like variables, and hold values. We will make it so if a user goes to the route /hello/name we will say hello to whatever is in the name place. Express uses colons to indicate a part of a route is actually a parameter, whose name follows the colon. So we have a route /hello/:name, then whatever comes after /hello/ in the URL will be stored in the "name" parameter. Let's add this route now to our server.js file right after our default empty route. app.get('/', function(req, res) { res.render('hello'); }); app.get('/hello/:name', function(req, res) { //TODO: handle this route });

5 Now that we have this route parameter, we need to use it! We can do use using the param() function. The first argument can be the name of the route parameter we want, and it will return its value! For now, we will use it to set a variable and output it to the console. app.get('/hello/:name', function(req, res) { var name = req.param('name'); console.log('name sent to server: '+name); }); Restart the server $ node server.js And in a browser navigate to that route and put in your name, such as /hello/Aaron. While nothing will happen in the browser (we are not sending back a response or rendering anything yet) you should see the name output in the console! $ Name sent to server: Aaron Instead of just the console, lets also send this variable to the view!

6 EJS templates can use variables when rendering view files Let's reuse some code we've written and have our server render hello.ejs for the new hello route. But we'll add another parameter in our call to render which is an object of the variables we will send to the view. To keep things simple we'll keep the name of variable the same in the view as it is in our server. app.get('/hello/:name', function(req, res) { var name = req.param('name'); console.log('name sent to server: '+name); res.render('hello', {name: name}); }); We also need to modify our view to use this variable. In EJS you can output the value of a variable by putting its name between "<%=" and "%>", for example "<%= name %>" will become the value of the name variable when rendered. Let's modify hello.ejs to use this instead of always showing "World". <h1> Hello, World! Hello, <%= name %>! </h1>

7 EJS templates can use variables when rendering view files Now once again we made a change to our server file, so we need to restart our server. $ node server.js And lets try out our route again--this time we should also see results in the browser! Let's see what happens when I go to now. Look at that! My name was passed from the route to the view, and displayed!

8 While this new route works great, we modified the same view used by the default empty route. Let's see if it still works by navigating to Woah looks like something went wrong! An error message was sent back instead of our view. You will also notice the error message in the console as well. Usually error messages give hints as to what the problem is. Here it points at the "Hello, <%= name %>!" line of code in our view, and also includes the message "name is not defined". Basically our view was expecting a variable called name, but since our empty route doesn't pass it a value for that variable, it gets very upset.

9 Let's modify our empty route to simply redirect to the new hello route, which provides the view the variables. We'll use this by calling the redirect() function. Go ahead and make the following change to the empty route in server.js. app.get('/', function(req, res) { res.render('hello'); res.redirect('/hello/world'); }); Save and restart the server $ node server.js Navigate to and see how it now redirects to

10

11 URL query parameters are another way to send information to the server Another way to send information to the server can be including what are known as query parameters after the route. Basically in the URL, once the route is over, you can put a question mark and then any number of parameter name and value pairs. Each pair separates the name and value with an equals sign, and the pairs themselves are separated with an ampersand. Domain Route Query Parameters In the above example URL for mydomain.com, they are going to the route /this/is/myroute. Then there are two query parameters. firstparam with a value of "1", and secondparam with a value of "two".

12 Query parameters can be retrieved and treated just like route parameters These parameters can be retrieved and then treated just like route parameters. Just like we used the param() function for the route parameter, it can get the query parameter. One thing we didn't mention about the param() function is that it has an optional second argument, which is the value to use if the parameter doesn't exist. This can be very handy. Let's modify our empty route to look for the firstname and lastname parameters, and use these in the redirect. app.get('/', function(req, res) { var firstname = req.param('firstname', 'Mystery'); var lastname = req.param('lastname', 'Person'); res.redirect('/hello/world'); res.redirect('/hello/'+firstname+' '+lastname); }); Here we are saying look for the query parameter firstname, but if it doesn't exist use "Mystery". Then look for the query parameter lastname, but if that doesn't exist use Person. Then combine them and redirect using the result as the name route parameter for the hello route.

13 Let's try using the parameters. First we need to save and restart the server. $ node server.js Now go ahead and use your name for the appropriate parameter values. For example, in the web browser navigate to Here we say the values of the query parameters being used. Let's see what happens if we leave some of them off.

14 Now lets test out our default parameters. Go ahead and use a URL that is missing a parameter. For example, we could remove the firstname parameter and try LastName=Silverman There we see one of our defaults being used. Lets try with no query parameters and we should see both defaults used.

15

16 Forms are a way to structure and send parameters While query parameters get the job done, it sure is a pain for users to type them up there in the address bar. One way to make things easier for people who use your website is to leverage an HTML form. HTML forms have different fields, such as a text box. These fields can be given names and the form can be setup to submit the names and values as query parameters. Remember our silly sentence generator from the second lesson? It took as input a name and a place, and then combined that with some random words to generate a silly sentence. Let's make this a web application instead of a command line program! First we'll need a new page for our form, so lets make a new file in our views folder called sentenceinput.ejs.

17 We'll cheat a bit here and use very simple HTML without the doctype, html, head, and body tags. This is so we can learn about forms faster--don't actually write forms this way. I highly recommend using twitter bootstrap and its forms. Let's write code in sentenceinput.ejs with a simple HTML form that takes the name and place: <form> Name: <input name="name" type="text" /> <br /> Place: <input name="place" type="text" /> <br /> <button type="submit">submit</button> </form> In our server.js we'll want to add a new route for this form view. We can add it after the /bye route: app.get('/bye', function(req, res) { res.render('bye'); }); app.get('/sentenceinput', function(req, res) { res.render('sentenceinput'); });

18 Now make sure both files are saved and restart your server. $ node server.js We can then navigate to our new route and see our form at What a great little form! Lets quickly dive into what we did there.

19 <form> </form> The HTML form tag groups all of its content into one form. This is useful as when the form is submitted, it automatically knows all of the relevant inputs to submit. We'll come back to this one. Name: <input name="name" type="text" /> <br /> One type of input forms use are text boxes. These are created using an input tag with a type attribute whose value is "text". We also set a name attribute, this will be the name of the parameter associated with the input. In this case, coincidentally, name. Lastly we use a br (break) tag so the next input is on the next line. Place: <input name="place" type="text" /> <br /> This is just like the name input, except here we will associate this input with a parameter named "place" instead. <button type="submit">submit</button> The HTML button tag creates a button whose text is the contents of the tag. By setting the type attribute to be "submit", we are telling HTML that this button should submit the form its in.

20 Go ahead and fill in some values Then click the Submit button and see what happens Not a whole lot. But check out the address bar! The browser actually navigated back to the page you were on, but with the values you entered now as query parameters.

21 We can change where the form sends its values using the action attribute. Lets add that into our form. <form action="/sentenceoutput"> Since we modified a view, and left our server code alone, we don't have to restart the server. Refresh so our new changes take effect. Then fill in some values And submit the form!

22 A form's action attribute tells it what route to submit the input values If you look at the URL, submitting the form sent the browser to the /sentenceoutput route--which is what we entered as the value for the action attribute for the form. Following the route, we can see the query parameters whose values are what we entered. Since the /sentenceoutput route isn't defined, our server processed it using the catch-all route. Let's make an actual route for it in our server.js file. We'll add our /sentenceoutput route right after the /sentenceinput route, and leave ourselves TODO comments for what we want that route to do. app.get('/sentenceinput', function(req, res) { res.render('sentenceinput'); }); app.get('/sentenceoutput', function(req, res) { // TODO: process query params // TODO: generate random sentence parts // TODO: send random sentence to view });

23 First, lets go ahead and pate in some of our sentence generator code we wrote in the earlier lesson. You could also copy it from here. app.get('/sentenceoutput', function(req, res) { var name = process.argv[2]; var place = process.argv[3]; function randomword(wordarray) { var randomdecimal = Math.random(); var numwords = wordarray.length; var randomindex = Math.floor(randomDecimal * numwords); return wordarray[randomindex]; } var randomverb = randomword(verbs); var randomadjective = randomword(adjectives); var randompluralnoun = randomword(pluralnouns); });

24 Unlike earlier, we don't want to get the name and place from the command line, but rather from the values sent from the forms as query parameters. So lets change them to use the param() function. app.get('/sentenceoutput', function(req, res) { var name = process.argv[2]; var name = req.param('name'); var place = process.argv[3]; var place = req.param('place'); Now at the end lets start by just outputting our variables to the console: var randomverb = randomword(verbs); var randomadjective = randomword(adjectives); var randompluralnoun = randomword(pluralnouns); console.log('name: '+name); console.log('place: '+place); console.log('verb: '+randomverb); console.log('adjective: '+randomadjective); console.log('noun: '+randompluralnoun); });

25 Since we modified our server, we need to restart it. $ node server.js Go back and reload and enter some values and submit the form Since we don't have our server render any views yet, you won't see anything happen in the browser. But we do have our console log things so go check the console and see! Name: Curious George Place: Zoo Verb: toss Adjective: heavy Noun: trees There are our values!

26 Since our users cannot see the console, its time to make a view! We'll make one that builds a silly sentence using those five variables: name, place, verb, adjective, and noun. Let's start by adding to the views folder a new file called sentenceoutput.ejs. We'll be lazy again with the HTML for now and skip the doctype, html, head, and body elements. But once again that is only because this is a simple example! Go ahead and write a sentence putting the EJS view variables where they should be. We can make bold, or strong, the words provided from the form and emphasize the words that were randomly generated using <strong> and <em> tags respectively. <strong><%= name %></strong> likes to <em><%= verb %></em> <em><%=adjective %></em> <em/><%= noun %> </em> at the <strong><%= place %></strong> Here we did some funny things with the spacing to make this easier to read. But remember HTML ignores spaces and new lines so this sentence will all be on one line.

27 Now that we have our view expecting these variables, lets have our route render the view with these variables. So back in server.js we'll add more after our log statements. First, to make the code easier to read, we'll create an object to hold all the view variable name and values. Then we will call render and pass that object as the view variable argument. console.log('name: '+name); console.log('place: '+place); console.log('verb: '+randomverb); console.log('adjective: '+randomadjective); console.log('noun: '+randompluralnoun); var viewvars = { name: name, place: place, verb: randomverb, adjective: randomadjective, noun: randompluralnoun }; res.render('sentenceoutput', viewvars); });

28 Be sure both the view file and the server file is saved. Once again, since we made a change to our server, lets restart it. $ node server.js Go back and reload and enter some values and submit the form This time you should see your sentence generated!

29

30 I think our sentence generator is so cool that we should link to it from our hello page. Lets modify hello.ejs and add a link. <p> <img class="cool" src="/images/icecream.jpg" /> <br /> <a href="/bye">say Goodbye</a> </p> <p> Would you like to <a href="/sentenceinput">generate a silly sentence?</a> </p> </body> Since we only modified a view, no need to restart the server. Now lets check out our site again. Navigate to And now we have the link on the bottom of our page!

31 Time to share our sentence generator with the world! Quit the server to get back to a command prompt, and lets use the AppFog command line tool to deploy our latest code. $ af update myawesomewebsite Uploading Application: Checking for available resources: OK Processing resources: OK Packing application: OK Uploading (18K): OK Push Status: OK Stopping Application 'myawesomewebsite': OK Staging Application 'myawesomewebsite': OK Starting Application 'myawesomewebsite': OK Now navigate to your domain and try things out! This example uses

32 And since we left our log statements in, we can see what has been output on the server as well. This is useful for debugging if people start having problems, and cool to see just what is going on. $ af logs myawesomewebsite ====> /logs/stdout.log <==== Running server Access locally at To stop server and return to command line, press ctrl+c Name: Clifford the Big Red Dog Place: Supermarket Verb: kill Adjective: giant Noun: socks Now you can process user input and change the output of your views! You are equipped to build and deploy basic interactive web applications! Go ahead and play around and try to make this sentence generator look nicer using twitter bootstrap, and then more interesting by adding in more text fields and having it do extra stuff!

Client Side JavaScript and AJAX

Client Side JavaScript and AJAX Client Side JavaScript and AJAX Client side javascript is JavaScript that runs in the browsers of people using your site. So far all the JavaScript code we've written runs on our node.js server. This is

More information

We are assuming you have node installed!

We are assuming you have node installed! Node.js Hosting We are assuming you have node installed! This lesson assumes you've installed and are a bit familiar with JavaScript and node.js. If you do not have node, you can download and install it

More information

Django urls Django Girls Tutorial

Django urls Django Girls Tutorial Django urls Django Girls Tutorial about:reader?url=https://tutorial.djangogirls.org/en/django_urls/ 1 di 6 13/11/2017, 20:01 tutorial.djangogirls.org Django urls Django Girls Tutorial DjangoGirls 6-8 minuti

More information

BEGINNER PHP Table of Contents

BEGINNER PHP Table of Contents Table of Contents 4 5 6 7 8 9 0 Introduction Getting Setup Your first PHP webpage Working with text Talking to the user Comparison & If statements If & Else Cleaning up the game Remembering values Finishing

More information

c122jan2714.notebook January 27, 2014

c122jan2714.notebook January 27, 2014 Internet Developer 1 Start here! 2 3 Right click on screen and select View page source if you are in Firefox tells the browser you are using html. Next we have the tag and at the

More information

Human-Computer Interaction Design

Human-Computer Interaction Design Human-Computer Interaction Design COGS120/CSE170 - Intro. HCI Instructor: Philip Guo Lab 6 - Connecting frontend and backend without page reloads (2016-11-03) by Michael Bernstein, Scott Klemmer, and Philip

More information

Mobile App:IT. Methods & Classes

Mobile App:IT. Methods & Classes Mobile App:IT Methods & Classes WHAT IS A METHOD? - A method is a set of code which is referred to by name and can be called (invoked) at any point in a program simply by utilizing the method's name. -

More information

Programming Lab 1 (JS Hwk 3) Due Thursday, April 28

Programming Lab 1 (JS Hwk 3) Due Thursday, April 28 Programming Lab 1 (JS Hwk 3) Due Thursday, April 28 Lab You may work with partners for these problems. Make sure you put BOTH names on the problems. Create a folder named JSLab3, and place all of the web

More information

CSCU9B2 Practical 1: Introduction to HTML 5

CSCU9B2 Practical 1: Introduction to HTML 5 CSCU9B2 Practical 1: Introduction to HTML 5 Aim: To learn the basics of creating web pages with HTML5. Please register your practical attendance: Go to the GROUPS\CSCU9B2 folder in your Computer folder

More information

An attribute used in HTML that is used for web browsers screen reading devices to indicate the presence and description of an image Module 4

An attribute used in HTML that is used for web browsers screen reading devices to indicate the presence and description of an image Module 4 HTML Basics Key Terms Term Definition Introduced In A tag used in HTML that stands for Anchor and is used for all types of hyperlinks Module 3 A tag used in HTML to indicate a single line break

More information

Using X-Particles with Team Render

Using X-Particles with Team Render Using X-Particles with Team Render Some users have experienced difficulty in using X-Particles with Team Render, so we have prepared this guide to using them together. Caching Using Team Render to Picture

More information

Clearing Your Browser Cache in: Internet Explorer 7 or 8

Clearing Your Browser Cache in: Internet Explorer 7 or 8 Clearing Your Browser Cache in: Internet Explorer 7 or 8 In this short lesson, you will learn the steps necessary to empty your browser cache in Internet Explorer 7 or 8. Users of version 6 or earlier

More information

Backend Development. SWE 432, Fall 2017 Design and Implementation of Software for the Web

Backend Development. SWE 432, Fall 2017 Design and Implementation of Software for the Web Backend Development SWE 432, Fall 2017 Design and Implementation of Software for the Web Real World Example https://qz.com/1073221/the-hackers-who-broke-into-equifax-exploited-a-nine-year-old-security-flaw/

More information

Hello World! Computer Programming for Kids and Other Beginners. Chapter 1. by Warren Sande and Carter Sande. Copyright 2009 Manning Publications

Hello World! Computer Programming for Kids and Other Beginners. Chapter 1. by Warren Sande and Carter Sande. Copyright 2009 Manning Publications Hello World! Computer Programming for Kids and Other Beginners by Warren Sande and Carter Sande Chapter 1 Copyright 2009 Manning Publications brief contents Preface xiii Acknowledgments xix About this

More information

Backend Development. SWE 432, Fall Web Application Development

Backend Development. SWE 432, Fall Web Application Development Backend Development SWE 432, Fall 2018 Web Application Development Review: Async Programming Example 1 second each Go get a candy bar Go get a candy bar Go get a candy bar Go get a candy bar Go get a candy

More information

By Ryan Stevenson. Guidebook #2 HTML

By Ryan Stevenson. Guidebook #2 HTML By Ryan Stevenson Guidebook #2 HTML Table of Contents 1. HTML Terminology & Links 2. HTML Image Tags 3. HTML Lists 4. Text Styling 5. Inline & Block Elements 6. HTML Tables 7. HTML Forms HTML Terminology

More information

JS Lab 1: (Due Thurs, April 27)

JS Lab 1: (Due Thurs, April 27) JS Lab 1: (Due Thurs, April 27) For this lab, you may work with a partner, or you may work alone. If you choose a partner, this will be your partner for the final project. If you choose to do it with a

More information

PROFESSOR: Last time, we took a look at an explicit control evaluator for Lisp, and that bridged the gap between

PROFESSOR: Last time, we took a look at an explicit control evaluator for Lisp, and that bridged the gap between MITOCW Lecture 10A [MUSIC PLAYING] PROFESSOR: Last time, we took a look at an explicit control evaluator for Lisp, and that bridged the gap between all these high-level languages like Lisp and the query

More information

Lesson 1: Writing Your First JavaScript

Lesson 1: Writing Your First JavaScript JavaScript 101 1-1 Lesson 1: Writing Your First JavaScript OBJECTIVES: In this lesson you will be taught how to Use the tag Insert JavaScript code in a Web page Hide your JavaScript

More information

<script> function yourfirstfunc() { alert("hello World!") } </script>

<script> function yourfirstfunc() { alert(hello World!) } </script> JavaScript: Lesson 1 Terms: HTML: a mark-up language used for web pages (no power) CSS: a system for adding style to web pages css allows developers to choose how to style the html elements in a web page

More information

Controlled Assessment Task. Question 1 - Describe how this HTML code produces the form displayed in the browser.

Controlled Assessment Task. Question 1 - Describe how this HTML code produces the form displayed in the browser. Controlled Assessment Task Question 1 - Describe how this HTML code produces the form displayed in the browser. The form s code is displayed in the tags; this creates the object which is the visible

More information

JavaScript Introduction

JavaScript Introduction JavaScript Introduction What is JavaScript? JavaScript was designed to add interactivity to HTML pages JavaScript is usually embedded directly into HTML pages JavaScript is an interpreted language (means

More information

Linked Lists. What is a Linked List?

Linked Lists. What is a Linked List? Linked Lists Along with arrays, linked lists form the basis for pretty much every other data stucture out there. This makes learning and understand linked lists very important. They are also usually the

More information

CS3 Midterm 1 Fall 2006

CS3 Midterm 1 Fall 2006 Overall, you did good job on this exam. CS3 Midterm 1 Fall 2006 Standards and Solutions 20 10 0 8.0 30.0 28.0 26.0 24.0 22.0 20.0 18.0 16.0 14.0 12.0 10.0 Std. Dev = 5.34 Mean = 21.6 N = 133.00 MT1_SCL

More information

Attributes & Images 1 Create a new webpage

Attributes & Images 1 Create a new webpage Attributes & Images 1 Create a new webpage Open your test page. Use the Save as instructions from the last activity to save your test page as 4Attributes.html and make the following changes:

More information

Lesson 5C MyClass Methods. By John B. Owen All rights reserved 2011, revised 2014

Lesson 5C MyClass Methods. By John B. Owen All rights reserved 2011, revised 2014 Lesson 5C MyClass Methods By John B. Owen All rights reserved 2011, revised 2014 Table of Contents Objectives Defining your own class Defining and calling a static method Method structure String return

More information

Control, Quick Overview. Selection. Selection 7/6/2017. Chapter 2. Control

Control, Quick Overview. Selection. Selection 7/6/2017. Chapter 2. Control Chapter 2 Control, Quick Overview Control Selection Selection Selection is how programs make choices, and it is the process of making choices that provides a lot of the power of computing 1 Python if statement

More information

BlueMix Hands-On Workshop Lab A - Building and Deploying BlueMix Applications

BlueMix Hands-On Workshop Lab A - Building and Deploying BlueMix Applications BlueMix Hands-On Workshop Lab A - Building and Deploying BlueMix Applications Version : 4.00 Last modification date : 13 June 2014 Owner : IBM Ecosystem Development Table of Contents Part 1: Building

More information

EVENT-DRIVEN PROGRAMMING

EVENT-DRIVEN PROGRAMMING LESSON 13 EVENT-DRIVEN PROGRAMMING This lesson shows how to package JavaScript code into self-defined functions. The code in a function is not executed until the function is called upon by name. This is

More information

& ( ); INSERT INTO ( ) SELECT

& ( ); INSERT INTO ( ) SELECT Oracle apex array Craig is a Development Consultant at Explorer. Craig has an MSc in Computing Science and is an experienced software engineer, utilising development tools such as PL/SQL and APEX to provide

More information

USING DRUPAL. Hampshire College Website Editors Guide https://drupal.hampshire.edu

USING DRUPAL. Hampshire College Website Editors Guide https://drupal.hampshire.edu USING DRUPAL Hampshire College Website Editors Guide 2014 https://drupal.hampshire.edu Asha Kinney Hampshire College Information Technology - 2014 HOW TO GET HELP Your best bet is ALWAYS going to be to

More information

HOW TO FLASK. And a very short intro to web development and databases

HOW TO FLASK. And a very short intro to web development and databases HOW TO FLASK And a very short intro to web development and databases FLASK Flask is a web application framework written in Python. Created by an international Python community called Pocco. Based on 2

More information

Introduction, Notepad++, File Structure, 9 Tags, Hyperlinks 1

Introduction, Notepad++, File Structure, 9 Tags, Hyperlinks 1 Introduction, Notepad++, File Structure, 9 Tags, Hyperlinks 1 Introduction to HTML HTML, which stands for Hypertext Markup Language, is the standard markup language used to create web pages. HTML consists

More information

Javelin Workbench Tutorial. Version 3.0 September, 2009

Javelin Workbench Tutorial. Version 3.0 September, 2009 Javelin Workbench Tutorial Version 3.0 September, 2009 OVERVIEW The Javelin Workbench Beginner Tutorial walks you through the steps of building online feedback forms for the purposes of data collection.

More information

Most of the class will focus on if/else statements and the logical statements ("conditionals") that are used to build them. Then I'll go over a few

Most of the class will focus on if/else statements and the logical statements (conditionals) that are used to build them. Then I'll go over a few With notes! 1 Most of the class will focus on if/else statements and the logical statements ("conditionals") that are used to build them. Then I'll go over a few useful functions (some built into standard

More information

WebQuest. Question-File Quick-Start Instructions

WebQuest. Question-File Quick-Start Instructions Contents WebQuest Question-File Quick-Start Instructions 1 Introduction 1 2 Where to Start 2 2.1 Questionnaire on Paper............................. 2 2.2 Questionnaire in Electronic Format (Word, PDF,

More information

MITOCW watch?v=ytpjdnlu9ug

MITOCW watch?v=ytpjdnlu9ug MITOCW watch?v=ytpjdnlu9ug The following content is provided under a Creative Commons license. Your support will help MIT OpenCourseWare continue to offer high-quality, educational resources for free.

More information

CSCI 1100L: Topics in Computing Spring 2018 Web Page Project 50 points

CSCI 1100L: Topics in Computing Spring 2018 Web Page Project 50 points CSCI 1100L: Topics in Computing Spring 2018 Web Page Project 50 points Project Due (All lab sections): Check on elc Assignment Objectives: Lookup and correctly use HTML tags. Lookup and correctly use CSS

More information

JQuery and Javascript

JQuery and Javascript JQuery and Javascript Javascript - a programming language to perform calculations/ manipulate HTML and CSS/ make a web page interactive JQuery - a javascript framework to help manipulate HTML and CSS JQuery

More information

Chapter Two Bonus Lesson: JavaDoc

Chapter Two Bonus Lesson: JavaDoc We ve already talked about adding simple comments to your source code. The JDK actually supports more meaningful comments as well. If you add specially-formatted comments, you can then use a tool called

More information

CSS BASICS. selector { property: value; }

CSS BASICS. selector { property: value; } GETTING STARTED 1. Download the Juice-o-Rama 11-01 zip file from our course dropbox. 2. Move the file to the desktop. You have learned two ways to do this. 3. Unzip the file by double clicking it. You

More information

Java Programming Constructs Java Programming 2 Lesson 1

Java Programming Constructs Java Programming 2 Lesson 1 Java Programming Constructs Java Programming 2 Lesson 1 Course Objectives Welcome to OST's Java 2 course! In this course, you'll learn more in-depth concepts and syntax of the Java Programming language.

More information

CIS 505: Software Systems

CIS 505: Software Systems CIS 505: Software Systems Fall 2017 Assignment 3: Chat server Due on November 3rd, 2017, at 10:00pm EDT 1 Overview For this assignment, you will implement a simple replicated chat server that uses multicast

More information

2. Write style rules for how you d like certain elements to look.

2. Write style rules for how you d like certain elements to look. CSS for presentation Cascading Style Sheet Orientation CSS Cascading Style Sheet is a language that allows the user to change the appearance or presentation of elements on the page: the size, style, and

More information

Azon Master Class. By Ryan Stevenson Guidebook #5 WordPress Usage

Azon Master Class. By Ryan Stevenson   Guidebook #5 WordPress Usage Azon Master Class By Ryan Stevenson https://ryanstevensonplugins.com/ Guidebook #5 WordPress Usage Table of Contents 1. Widget Setup & Usage 2. WordPress Menu System 3. Categories, Posts & Tags 4. WordPress

More information

DbSchema Forms and Reports Tutorial

DbSchema Forms and Reports Tutorial DbSchema Forms and Reports Tutorial Contents Introduction... 1 What you will learn in this tutorial... 2 Lesson 1: Create First Form Using Wizard... 3 Lesson 2: Design the Second Form... 9 Add Components

More information

Lab 7 Macros, Modules, Data Access Pages and Internet Summary Macros: How to Create and Run Modules vs. Macros 1. Jumping to Internet

Lab 7 Macros, Modules, Data Access Pages and Internet Summary Macros: How to Create and Run Modules vs. Macros 1. Jumping to Internet Lab 7 Macros, Modules, Data Access Pages and Internet Summary Macros: How to Create and Run Modules vs. Macros 1. Jumping to Internet 1. Macros 1.1 What is a macro? A macro is a set of one or more actions

More information

Database management system Prof. D. Janakiram Department of Computer Science and Engineering Indian Institute of Technology, Madras

Database management system Prof. D. Janakiram Department of Computer Science and Engineering Indian Institute of Technology, Madras Database management system Prof. D. Janakiram Department of Computer Science and Engineering Indian Institute of Technology, Madras Lecture 25 Basic 2-phase & 3-phase Commit protocol In the last lecture,

More information

CSCI 1100L: Topics in Computing Lab Lab 11: Programming with Scratch

CSCI 1100L: Topics in Computing Lab Lab 11: Programming with Scratch CSCI 1100L: Topics in Computing Lab Lab 11: Programming with Scratch Purpose: We will take a look at programming this week using a language called Scratch. Scratch is a programming language that was developed

More information

XP: Backup Your Important Files for Safety

XP: Backup Your Important Files for Safety XP: Backup Your Important Files for Safety X 380 / 1 Protect Your Personal Files Against Accidental Loss with XP s Backup Wizard Your computer contains a great many important files, but when it comes to

More information

Introduction to Git and GitHub for Writers Workbook February 23, 2019 Peter Gruenbaum

Introduction to Git and GitHub for Writers Workbook February 23, 2019 Peter Gruenbaum Introduction to Git and GitHub for Writers Workbook February 23, 2019 Peter Gruenbaum Table of Contents Preparation... 3 Exercise 1: Create a repository. Use the command line.... 4 Create a repository...

More information

CSE 115. Introduction to Computer Science I

CSE 115. Introduction to Computer Science I CSE 115 Introduction to Computer Science I Road map Review Limitations of front-end sites Web servers Examples Review

More information

Module 1: Information Extraction

Module 1: Information Extraction Module 1: Information Extraction Introduction to GATE Developer The University of Sheffield, 1995-2014 This work is licenced under the Creative Commons Attribution-NonCommercial-ShareAlike Licence About

More information

Set-up Server Features and Roles Once the users are created we will move on to setting up the Internet Information Services (IIS) role on the server.

Set-up Server Features and Roles Once the users are created we will move on to setting up the Internet Information Services (IIS) role on the server. HOW TO: Install and Setup System Center Configuration Manager (SCCM) 2012 SP1 on a Windows Server 2012 Part 1 - Prerequisites In the following three part guide we will be going over how to install and

More information

Slide 1 CS 170 Java Programming 1

Slide 1 CS 170 Java Programming 1 CS 170 Java Programming 1 Objects and Methods Performing Actions and Using Object Methods Slide 1 CS 170 Java Programming 1 Objects and Methods Duration: 00:01:14 Hi Folks. This is the CS 170, Java Programming

More information

CSS worksheet. JMC 105 Drake University

CSS worksheet. JMC 105 Drake University CSS worksheet JMC 105 Drake University 1. Download the css-site.zip file from the class blog and expand the files. You ll notice that you have an images folder with three images inside and an index.html

More information

To Kill a Monolith: Slaying the Demons of a Monolith with Node.js Microservices on CloudFoundry. Tony Erwin,

To Kill a Monolith: Slaying the Demons of a Monolith with Node.js Microservices on CloudFoundry. Tony Erwin, To Kill a Monolith: Slaying the Demons of a Monolith with Node.js Microservices on CloudFoundry Tony Erwin, aerwin@us.ibm.com Agenda Origins of the Bluemix UI Demons of the Monolith Slaying Demons with

More information

WA2031 WebSphere Application Server 8.0 Administration on Windows. Student Labs. Web Age Solutions Inc. Copyright 2012 Web Age Solutions Inc.

WA2031 WebSphere Application Server 8.0 Administration on Windows. Student Labs. Web Age Solutions Inc. Copyright 2012 Web Age Solutions Inc. WA2031 WebSphere Application Server 8.0 Administration on Windows Student Labs Web Age Solutions Inc. Copyright 2012 Web Age Solutions Inc. 1 Table of Contents Directory Paths Used in Labs...3 Lab Notes...4

More information

Intro. Scheme Basics. scm> 5 5. scm>

Intro. Scheme Basics. scm> 5 5. scm> Intro Let s take some time to talk about LISP. It stands for LISt Processing a way of coding using only lists! It sounds pretty radical, and it is. There are lots of cool things to know about LISP; if

More information

CS 1100: Web Development: Client Side Coding / Fall 2016 Lab 2: More HTML and CSS

CS 1100: Web Development: Client Side Coding / Fall 2016 Lab 2: More HTML and CSS Goals CS 1100: Web Development: Client Side Coding / Fall 2016 Lab 2: More HTML and CSS Practice writing HTML Add links and images to your web pages Apply basic styles to your HTML This lab is based on

More information

I will link the following rough sketch of my mom to our class homepage: Code Used

I will link the following rough sketch of my mom to our class homepage: Code Used Assignment Eight: Fabulous Forms INTRODUCTION Let's start off this assignment with some work, shall we? (rubbing hands together as a mob boss would). Go to your page #3 (the one listing likes and dislikes)

More information

TUTORIAL MADCAP FLARE Top Navigation

TUTORIAL MADCAP FLARE Top Navigation TUTORIAL MADCAP FLARE 2018 Top Navigation Copyright 2018 MadCap Software. All rights reserved. Information in this document is subject to change without notice. The software described in this document

More information

The Structure of the Web. Jim and Matthew

The Structure of the Web. Jim and Matthew The Structure of the Web Jim and Matthew Workshop Structure 1. 2. 3. 4. 5. 6. 7. What is a browser? HTML CSS Javascript LUNCH Clients and Servers (creating a live website) Build your Own Website Workshop

More information

CMPT 100 : INTRODUCTION TO

CMPT 100 : INTRODUCTION TO CMPT 100 : INTRODUCTION TO COMPUTING TUTORIAL #5 : JAVASCRIPT 2 GUESSING GAME 1 By Wendy Sharpe BEFORE WE GET STARTED... If you have not been to the first tutorial introduction JavaScript then you must

More information

c122sep814.notebook September 08, 2014 All assignments should be sent to Backup please send a cc to this address

c122sep814.notebook September 08, 2014 All assignments should be sent to Backup please send a cc to this address All assignments should be sent to p.grocer@rcn.com Backup please send a cc to this address Note that I record classes and capture Smartboard notes. They are posted under audio and Smartboard under XHTML

More information

STAT 113: R/RStudio Intro

STAT 113: R/RStudio Intro STAT 113: R/RStudio Intro Colin Reimer Dawson Last Revised September 1, 2017 1 Starting R/RStudio There are two ways you can run the software we will be using for labs, R and RStudio. Option 1 is to log

More information

1 Lecture 5: Advanced Data Structures

1 Lecture 5: Advanced Data Structures L5 June 14, 2017 1 Lecture 5: Advanced Data Structures CSCI 1360E: Foundations for Informatics and Analytics 1.1 Overview and Objectives We ve covered list, tuples, sets, and dictionaries. These are the

More information

CaseComplete Roadmap

CaseComplete Roadmap CaseComplete Roadmap Copyright 2004-2014 Serlio Software Development Corporation Contents Get started... 1 Create a project... 1 Set the vision and scope... 1 Brainstorm for primary actors and their goals...

More information

COM1004 Web and Internet Technology

COM1004 Web and Internet Technology COM1004 Web and Internet Technology When a user submits a web form, how do we save the information to a database? How do we retrieve that data later? ID NAME EMAIL MESSAGE TIMESTAMP 1 Mike mike@dcs Hi

More information

9.0 Help for End Users Release Notes Using Jive for Outlook...5

9.0 Help for End Users Release Notes Using Jive for Outlook...5 Contents 2 Contents 9.0 Help for End Users... 3 Release Notes... 4 Using Jive for Outlook...5 Client System Requirements...5 Getting Started with Jive for Outlook...5 Jview and View as email... 7 Viewing

More information

Dreamweaver CS6. Table of Contents. Setting up a site in Dreamweaver! 2. Templates! 3. Using a Template! 3. Save the template! 4. Views!

Dreamweaver CS6. Table of Contents. Setting up a site in Dreamweaver! 2. Templates! 3. Using a Template! 3. Save the template! 4. Views! Dreamweaver CS6 Table of Contents Setting up a site in Dreamweaver! 2 Templates! 3 Using a Template! 3 Save the template! 4 Views! 5 Properties! 5 Editable Regions! 6 Creating an Editable Region! 6 Modifying

More information

Title: Sep 12 10:58 AM (1 of 38)

Title: Sep 12 10:58 AM (1 of 38) Title: Sep 12 10:58 AM (1 of 38) Title: Sep 12 11:04 AM (2 of 38) Title: Sep 12 5:37 PM (3 of 38) Click here and then you can put in the resources. Title: Sep 12 5:38 PM (4 of 38) Title: Sep 12 5:42 PM

More information

Appendix 8 Universal Powerline Bus (UPB)

Appendix 8 Universal Powerline Bus (UPB) Appendix 8 Universal Powerline Bus (UPB) This appendix describes the features in HCA in support of the UPB technology and products available from Powerline Control Systems (PCS), Simply Automated Inc,

More information

Using Parameter Queries

Using Parameter Queries [Revised and Updated 21 August 2018] A useful feature of the query is that it can be saved and used again and again, whenever we want to ask the same question. The result we see (the recordset) always

More information

This guide is intended to help the un-experienced in PHP in particularly Phpvms to easily install and use this freeware software.

This guide is intended to help the un-experienced in PHP in particularly Phpvms to easily install and use this freeware software. This guide is intended to help the un-experienced in PHP in particularly Phpvms to easily install and use this freeware software. This is a proven product and any issues will go un-noticed by the beginner.

More information

Getting Started. Excerpted from Hello World! Computer Programming for Kids and Other Beginners

Getting Started. Excerpted from Hello World! Computer Programming for Kids and Other Beginners Getting Started Excerpted from Hello World! Computer Programming for Kids and Other Beginners EARLY ACCESS EDITION Warren D. Sande and Carter Sande MEAP Release: May 2008 Softbound print: November 2008

More information

Lab 1 - Introduction to Angular

Lab 1 - Introduction to Angular Lab 1 - Introduction to Angular In this lab we will build a Hello World style Angular component. The key focus is to learn how to install all the required code and use them from the browser. We wont get

More information

6.001 Notes: Section 15.1

6.001 Notes: Section 15.1 6.001 Notes: Section 15.1 Slide 15.1.1 Our goal over the next few lectures is to build an interpreter, which in a very basic sense is the ultimate in programming, since doing so will allow us to define

More information

Using Jive for Outlook

Using Jive for Outlook Using Jive for Outlook TOC 2 Contents Using Jive for Outlook...3 Client System Requirements... 3 Getting Started with Jive for Outlook... 3 Jview and View as email...4 Viewing Social Information... 4 Finding

More information

Persistence & State. SWE 432, Fall 2016 Design and Implementation of Software for the Web

Persistence & State. SWE 432, Fall 2016 Design and Implementation of Software for the Web Persistence & State SWE 432, Fall 2016 Design and Implementation of Software for the Web Today What s state for our web apps? How do we store it, where do we store it, and why there? For further reading:

More information

Why Use A JavaScript Library?

Why Use A JavaScript Library? Using JQuery 4 Why Use A JavaScript Library? Okay, first things first. Writing JavaScript applications from scratch can be difficult, time-consuming, frustrating, and a real pain in the, ahem, britches.

More information

CAL 9-2: Café Soylent Green Chapter 12

CAL 9-2: Café Soylent Green Chapter 12 CAL 9-2: Café Soylent Green Chapter 12 This version is for those students who are using Dreamweaver CC. You will be completing the Forms Tutorial from your textbook, Chapter 12 however, you will be skipping

More information

Café Soylent Green Chapters 4

Café Soylent Green Chapters 4 Café Soylent Green Chapters 4 You will be completing the Links Tutorial from your textbook, Chapter 4, pgs. 223-227 AND the Images Tutorial, Chapter 5, pgs. 278-287. You will need to be at a computer that

More information

Exercise 1 Using Boolean variables, incorporating JavaScript code into your HTML webpage and using the document object

Exercise 1 Using Boolean variables, incorporating JavaScript code into your HTML webpage and using the document object CS1046 Lab 5 Timing: This lab should take you approximately 2 hours. Objectives: By the end of this lab you should be able to: Recognize a Boolean variable and identify the two values it can take Calculate

More information

Azon Master Class. By Ryan Stevenson Guidebook #7 Site Construction 2/3

Azon Master Class. By Ryan Stevenson   Guidebook #7 Site Construction 2/3 Azon Master Class By Ryan Stevenson https://ryanstevensonplugins.com/ Guidebook #7 Site Construction 2/3 Table of Contents 1. Creation of Site Pages 2. Category Pages Creation 3. Home Page Creation Creation

More information

CGI Programming. What is "CGI"?

CGI Programming. What is CGI? CGI Programming What is "CGI"? Common Gateway Interface A means of running an executable program via the Web. CGI is not a Perl-specific concept. Almost any language can produce CGI programs even C++ (gasp!!)

More information

CS193X: Web Programming Fundamentals

CS193X: Web Programming Fundamentals CS193X: Web Programming Fundamentals Spring 2017 Victoria Kirst (vrk@stanford.edu) CS193X schedule Today - Middleware and Routes - Single-page web app - More MongoDB examples - Authentication - Victoria

More information

Q&A Session for Connect with Remedy - CMDB Best Practices Coffee Break

Q&A Session for Connect with Remedy - CMDB Best Practices Coffee Break Q&A Session for Connect with Remedy - CMDB Best Practices Coffee Break Date: Thursday, March 05, 2015 Q: When going to Asset Management Console and making an update on there, does that go to a sandbox

More information

Week - 01 Lecture - 04 Downloading and installing Python

Week - 01 Lecture - 04 Downloading and installing Python Programming, Data Structures and Algorithms in Python Prof. Madhavan Mukund Department of Computer Science and Engineering Indian Institute of Technology, Madras Week - 01 Lecture - 04 Downloading and

More information

Helping the Compiler Help You. Thomas Dy

Helping the Compiler Help You. Thomas Dy Helping the Compiler Help You Thomas Dy Programming do { programmer.write_code(); if(lazy) { sleep(); } compile_code(); } while(compiler.has_errors()); Compiler: Me no speaky English Programmer: Compiler,

More information

Arduino IDE Friday, 26 October 2018

Arduino IDE Friday, 26 October 2018 Arduino IDE Friday, 26 October 2018 12:38 PM Looking Under The Hood Of The Arduino IDE FIND THE ARDUINO IDE DOWNLOAD First, jump on the internet with your favorite browser, and navigate to www.arduino.cc.

More information

Hello, and welcome to the Alexicomtech tutorial. I will show you step by step how to set up your interactive pages. Please feel free to ask questions

Hello, and welcome to the Alexicomtech tutorial. I will show you step by step how to set up your interactive pages. Please feel free to ask questions Hello, and welcome to the Alexicomtech tutorial. I will show you step by step how to set up your interactive pages. Please feel free to ask questions at any time. The first step is to open your internet

More information

The Stack, Free Store, and Global Namespace

The Stack, Free Store, and Global Namespace Pointers This tutorial is my attempt at clarifying pointers for anyone still confused about them. Pointers are notoriously hard to grasp, so I thought I'd take a shot at explaining them. The more information

More information

Survey Creation Workflow These are the high level steps that are followed to successfully create and deploy a new survey:

Survey Creation Workflow These are the high level steps that are followed to successfully create and deploy a new survey: Overview of Survey Administration The first thing you see when you open up your browser to the Ultimate Survey Software is the Login Page. You will find that you see three icons at the top of the page,

More information

How the Internet Works

How the Internet Works How the Internet Works The Internet is a network of millions of computers. Every computer on the Internet is connected to every other computer on the Internet through Internet Service Providers (ISPs).

More information

GEO 425: SPRING 2012 LAB 9: Introduction to Postgresql and SQL

GEO 425: SPRING 2012 LAB 9: Introduction to Postgresql and SQL GEO 425: SPRING 2012 LAB 9: Introduction to Postgresql and SQL Objectives: This lab is designed to introduce you to Postgresql, a powerful database management system. This exercise covers: 1. Starting

More information

DbSchema Forms and Reports Tutorial

DbSchema Forms and Reports Tutorial DbSchema Forms and Reports Tutorial Introduction One of the DbSchema modules is the Forms and Reports designer. The designer allows building of master-details reports as well as small applications for

More information

the NXT-G programming environment

the NXT-G programming environment 2 the NXT-G programming environment This chapter takes a close look at the NXT-G programming environment and presents a few simple programs. The NXT-G programming environment is fairly complex, with lots

More information

What's the Slope of a Line?

What's the Slope of a Line? What's the Slope of a Line? These lines look pretty different, don't they? Lines are used to keep track of lots of info -- like how much money a company makes. Just off the top of your head, which of the

More information

CS Multimedia and Communications REMEMBER TO BRING YOUR MEMORY STICK TO EVERY LAB!

CS Multimedia and Communications REMEMBER TO BRING YOUR MEMORY STICK TO EVERY LAB! CS 1033 Multimedia and Communications REMEMBER TO BRING YOUR MEMORY STICK TO EVERY LAB! Lab 06: Introduction to KompoZer (Website Design - Part 3 of 3) Lab 6 Tutorial 1 In this lab we are going to learn

More information