|
|
||||||||||||||||||||
Offers Web Services for small to medium sized companies. |
| Websmart uk > Services > Assisted web site DIY > Html7daycourse > HtmlLesson2 |
|
|
|
|
Can I Use Two Flags at Once? Yes. Just make sure to begin and end both. Like so: <B><I>Bold and Italic</I></B> gives you Bold and Italic If you do use multiple flags to alter text, make a point of not getting the end flags out of order. Look at this: <B><I>Text Text</B></I> In terms of format, the example above is not correct. The end flags are out of order in relation to the start tags. Follow this rule: Here, again, is the example above in correct form: <B><I>Text Text</I></B> Notice the Bold flags are on the far ends. Next in line are the Italics. Just keep setting commands at the farthest ends each time you add them and you'll stay in good form. ________________________ Single Flags The open and close flag format dominates the majority of the available HTML flags, but there are flags that stand alone. Here are three I use extensively:
Flag What It Does <HR> This command gives you a line across the page. (HR stands for Horizontal Reference.) The line right above the words "Single Flags" was made using an <HR> flag. <BR> This BReaks the text and starts it again on the next line. Remember you saved your document as TEXT so where you hit ENTER to jump to the next line was not saved. In an HTML document, you need to denote where you want every carriage return with a <BR>. <P> This stands for Paragraph. It does the exact same thing as the <BR> above except this flag skips a line. BR just jumps to the next line, P skips a line before starting the text again. Writing Your First Page So, here we go... you're going to write your first HTML page using what you have learned above plus two other items. And these two items are important to every page you will ever write. Why? Because they will be on every page you ever write. You will start every page with this flag: <HTML> Your next flags will always be these: <TITLE> and </TITLE> Finally, you'll end every page you write with this flag: </HTML> Get it? You started the page with HTML and you will end the page with /HTML. That makes sense again. So, Here We Go! I want you to play around with these commands. Just remember that HTML reads like you do, top to bottom, left to right. It will respond where you place the start flag and stop where you place the end flag. Just make sure your flags are within the < and > items. Here's a sample page to show you what I mean for you to do tonight: <HTML> <TITLE> My first html page </TITLE> <B>This is my first HTML page!</B><P> I can write in <I>Italic</I> or <B>Bold</B><BR> <HR> <B><I>Or I can write in both</I></B><BR> </HTML> Notice I only used the flags I showed you on this page. Yes, it's a simple page, but you're just starting out. Notice the <HTML> and </HTML>. Notice the <TITLE> and </TITLE>. See how there's a beginning and end flag when I alter the text and that the P and BR commands are used to go to new lines? Now, click here to see the page the code above produced. Look at the program above and then what it produced. Look at the source code when you open the page. See how the HTML flags denoted where text was affected? Good! I knew you would. Now go! Go into the world -- or at least to your text editor -- and create. Follow the instructions in HTML Lesson 1 to help you save and then display your first HTML page. You Can Do This! |
|
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||