C777 Unit 3: JavaScript copy

0.0(0)
studied byStudied by 0 people
learnLearn
examPractice Test
spaced repetitionSpaced Repetition
heart puzzleMatch
flashcardsFlashcards
Card Sorting

1/69

encourage image

There's no tags or description

Looks like no tags are added yet.

Study Analytics
Name
Mastery
Learn
Test
Matching
Spaced

No study sessions yet.

70 Terms

1
New cards

toUpperCase()

Which method convert a string value to uppercase letters?

2
New cards

abort

Which event occurs when the loading of an image is terminated?

3
New cards

blur

Which event occurs when a user clicks the mouse button outside of a particular input field?

4
New cards

click

Which event occurs when the user clicks on a link or form element?

5
New cards

change

Which event occurs when a user modifies the value of a form field?

6
New cards

error

Which event occurs when there is a problem loading an external image or resource?

7
New cards

focus

Which event occurs when a user clicks into a form field?

8
New cards

load

Which event occurs when a page is opened?

9
New cards

mouseOver

Which event occurs when the user moves the mouse pointer over a link, image or other visible element on a page?

10
New cards

mouseOut

Which event occurs when the mouse pointer leaves a link, image or other visible element on a page?

11
New cards

reset

Which event occurs when a form's Reset button is clicked?

12
New cards

select

Which event occurs when the user highlights the text in a form field?

13
New cards

submit

Which event occurs when a form's Submit button is clicked?

14
New cards

unload

Which event occurs when a page closed?

15
New cards

properties

What are attributes of an object, such as height, color, font size, sentence length and so forth?

16
New cards

methods

What are actions that an object can be made to perform?

17
New cards

alert()

Which method creates a pop-up box with the specified message string, which the user can dismiss by clicking a button in the box?

18
New cards

prompt()

Which method creates a pop-up box with the specified message string and requests user input into a text field in the box?

19
New cards

confirm()

Which method creates a pop-up box with the specified message string and requests user confirmation by clicking the OK or Cancel button in the box?

20
New cards

document.write()

Which method writes the specified message string in the page?

21
New cards

variable

What is a named space of memory?

22
New cards

=

Which operator is used to assign values?

23
New cards

number

Which data type holds any numeric value used for mathematical operations?

24
New cards

string

Which data type holds any string of alphanumeric characters used for words or for numbered phrases that are not mathematically manipulated?

25
New cards

var birthYear = "1956"

Which expression creates a string value?

26
New cards

var birthYear = 1956

Which expression creates an integer value?

27
New cards

Boolean

Which data type holds True or False values only?

28
New cards

null

Which value indicates that a user enters nothing in a text box then submits the form?

29
New cards

undefined

Which value indicates that a variable has no value assigned yet?

30
New cards

expression

What is a part of a statement that is evaluated as a value?

31
New cards

operator

What is a symbol or character used in expressions to store or evaluate a value?

32
New cards

Assignment

Which type of operator assigns a value to a variable using the equal symbol?

Example: myNumber = 25

33
New cards

Arithmetic

Which type of operator evaluates to a number?

Example: 25 + 75

34
New cards

Logical

Which type of operator will evaluate to true or false?

Example: 25 < 75

35
New cards

Comparison

Which type of operator compares two values and returns a true or false value?

Example: z == 10

36
New cards

Conditional

Which type of operator makes decisions in a script?

Example: (a > b) ? a++ : a--

37
New cards

concatenation

What process combines text strings using the plus sign?

Example: "hello" + "world"

38
New cards

function

What is a named set of statements that performs a task or calculates a value?

39
New cards

function myFunction(){}

How do you declare a function?

40
New cards

calling statement

What processes a function's statements?

41
New cards

nothing

What happens if you define a function but do not call it?

42
New cards

myFunction()

How do you call this function?

function myFunction(){

return "success";

}

43
New cards

return

What is used to output values from a function?

44
New cards

local variable

What type of variable is declared within a function and available only from within that function?

45
New cards

global variable

What type of variable is available throughout the entire script?

46
New cards

argument

What is a value or expression containing data or code that is passed on to a function?

47
New cards

pass by reference

What describes when values are passed to a function, and the function's parameters receive a copy of its argument's value?

Example:

function myFunction(x){

return x;

}

var num = 2;

myFunction(num);

48
New cards

pass by value

What describes when values are passed to a function, and the function's parameters receive its argument's actual value?

Example:

function myFunction(x){

return x;

}

myFunction(2);

49
New cards

isNaN()

Which method determines whether an value is a number?

50
New cards

parseInt()

Which method converts a string to its integer equivalent?

51
New cards

parseFloat()

Which method converts a string to its floating-point decimal equivalent?

52
New cards

Load-time errors

Which errors are typically syntax errors and usually cause error alerts?

53
New cards

Run-time errors

Which errors occur after the script has loaded and is running, typically caused by improper use of commands?

54
New cards

Logic errors

Which errors are mathematical , casting errors, errors in proper command usage or errors in the structure of the script, which result in the script running improperly?

55
New cards

literal

What is the actual data values you provide in JavaScript?

56
New cards

object

What is a self-contained programming component that contains properties and methods?

57
New cards

dot notation

What is a reference technique used to access a property or method of an object?

58
New cards

an object-based language

based upon an event-driven model

is platform-independent

enables quick development

is relatively easy to learn

What are key characteristics and features of JavaScript?

59
New cards

client side

Does JavaScript perform its functionality primarily on the client or server-side?

60
New cards

embedded scripting

Which technique adds JavaScript to a single web page within either the <head> or <body>?

61
New cards

inline scripting

Which technique adds JavaScript to a single HTML element?

62
New cards

external scripting

Which technique adds JavaScript by linking web pages to a text file with the .js file name extension?

63
New cards

<a href="#" onMouseOver="helloFunction();">Click Here</a>

How do you apply inline scripting to an element?

64
New cards

a letter,

the underscore ( _ ), or

the dollar sign ( $ )

What must variable names begin with?

65
New cards

unique

Is these variables the same or unique?

var Result

var result

var RESULT

66
New cards

navigator

Which object allows you to determine information about the user's browser?

67
New cards

navigator.appName

Which property returns a string value indicating the name of the client browser?

68
New cards

navigator.appVersion

Which property returns a string value indicating the version number of the client browser, as well as the client's platform?

69
New cards

0

What is the value of myVar after execution?

function counter(x) {

return x + 1;

}

var myVar = 0;

counter(myVar);

alert(myVar);

70
New cards

The total is 1.03

What will the alert box display?

var subTotal = 1;

var tax = 0.03;

alert("The total is " + subTotal * (1 + tax));