HTML and CSS Reference
If the line break occurs within a quoted text string, you can also break the string into
several distinct text strings placed over several lines by adding a plus symbol (+) at the
end of each line, as follows:
The + symbol used in this command combines several text strings into a single text
string. However, breaking a single statement into several lines is usually not recom-
mended because of the possibility of introducing errors into the code. It should be done
only with very long and complicated statements.
You can also write a long
text string to a Web page
by breaking the text string
into several document.
For browsers that don't support scripts or that have their support for client-side scripts
disabled, you can specify alternative content using the noscript element
where alternativeƒcontent is the content a browser should display in place of
accessing and running the script. For example, the following code displays a text mes-
Browsers that support client-side scripts and have that support enabled ignore the
content of the noscript element. Note that the noscript element is not supported
under XHTML strict.
Working with Variables
Because you used a specific text string with the document.write() , the code did little
more than what you could have accomplished by entering the e-mail link directly into
with variables. A variable is a named item in a program that stores a data value—such as
a number or text string—or an object—such as a part of the Web document or browser.
Variables are useful because they can store information created in one part of a program
and use that information elsewhere. Variable values can also change as a program runs,
enabling the program to display different values under varying conditions.
Declaring a Variable
You introduce variables in your code by declaring them. Declaring a variable tells the
use the var keyword
varƒ variable ;