create your own webpage. today’s class internet safety & privacy tables embedding music and...

33
Create Your Own Webpage

Upload: arnold-charles

Post on 03-Jan-2016

216 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Create Your Own Webpage. Today’s Class Internet Safety & Privacy Tables Embedding music and video Frames

Create Your Own Webpage

Page 2: Create Your Own Webpage. Today’s Class Internet Safety & Privacy Tables Embedding music and video Frames

Today’s Class

• Internet Safety & Privacy

• Tables

• Embedding music and video

• Frames

Page 3: Create Your Own Webpage. Today’s Class Internet Safety & Privacy Tables Embedding music and video Frames

Group Activity

• Google and find 5 tips for Internet Safety & Privacy

• 1 typist, 1-2 googlers who dictate their tip to the typist

• Share your tips with the rest of the class

Page 4: Create Your Own Webpage. Today’s Class Internet Safety & Privacy Tables Embedding music and video Frames

Reminders

• Next week we shift to learning Wordpress, a content management system– You can copy and paste your actual content to

Wordpress if you decide you like it better– Wordpress is a more accurate reflection of what you

might find in your future workplace.

• Thursday & Friday of next week – present your site (either your HTML site or Wordpress site) to the class!

Page 5: Create Your Own Webpage. Today’s Class Internet Safety & Privacy Tables Embedding music and video Frames

Make a simple table to help background readability

Start a new Notepad file and paste in text Ctrl-V or Edit Paste

<body background=background.gif>

<table border=1 align=center width=80% height=100% bgcolor=white>

<tr valign=middle><td>

Content goes here.

</table>

Page 6: Create Your Own Webpage. Today’s Class Internet Safety & Privacy Tables Embedding music and video Frames

Make a simple table to help background readability

• Save your work in Notepad, check it in a browser

• Experiment with changing numbers and other familiar variables in the code, etc.

Page 7: Create Your Own Webpage. Today’s Class Internet Safety & Privacy Tables Embedding music and video Frames

More tables – copy & paste code

• Go to www.snotrocketscience.com/cfk

• Highlight the text in the #2 gray box.

• Edit Copy or Ctrl C

Page 8: Create Your Own Webpage. Today’s Class Internet Safety & Privacy Tables Embedding music and video Frames

More tables – copy & paste code

• Open a new Notepad file – Start Programs Accessories Notepad to

open Notepad for the first time today– File New or Ctrl-N if you already have it open

• Paste in what you copied by Edit Paste or Ctrl-V

Page 9: Create Your Own Webpage. Today’s Class Internet Safety & Privacy Tables Embedding music and video Frames

Let’s look at the code

<table border=1>

<tr>

<td>This is cell 1</td>

<td>This is cell 2</td>

<tr>

<td>Row 2, cell 1</td>

<td>Row 2, cell 2</td>

</table>

• Starts your table• Starts a row• Creates a cell• Creates another cell• Starts a new row• Creates another cell• Creates another cell• Ends table

Page 10: Create Your Own Webpage. Today’s Class Internet Safety & Privacy Tables Embedding music and video Frames

More properties for your tables

• Change table border size: <table border=5>, <table border=0>, etc. – With table border=0 you can use a table to position

text

• Change table background:– <table bgcolor=white>– <td bgcolor=green> etc to change individual cells

• Change relative size of cells:– <td width=80%>wide cell</td>– <td width=20%>narrow cell</td>

Page 11: Create Your Own Webpage. Today’s Class Internet Safety & Privacy Tables Embedding music and video Frames

Cellspacing & Cellpadding

• <table border=1> (default)

Page 12: Create Your Own Webpage. Today’s Class Internet Safety & Privacy Tables Embedding music and video Frames

Cellspacing & Cellpadding

<table border=1 cellspacing=10>

• <table border=1 cellpadding=10>

Page 13: Create Your Own Webpage. Today’s Class Internet Safety & Privacy Tables Embedding music and video Frames

Uses of tables

• Position blocks of text exactly where you want

• Keeping pictures & text lined up right

• Grids – i.e. make a schedule or a calendar

• I design tables with border=1 so I don’t get confused about my table’s layout then change to border=0 because I think it looks better.

Page 14: Create Your Own Webpage. Today’s Class Internet Safety & Privacy Tables Embedding music and video Frames

Frames

• Frames are a handy navigation tool.

• Class web site utilizes frames.

Page 15: Create Your Own Webpage. Today’s Class Internet Safety & Privacy Tables Embedding music and video Frames

Frames

• We’ll create a page using frames that has this general look to it:

This “index.htm” page you have been working

on will be here.

You will create a new page that goes

here.

You’ll also create a third page that gives the

instructions for arranging the 2 HTML files.

Page 16: Create Your Own Webpage. Today’s Class Internet Safety & Privacy Tables Embedding music and video Frames

Using Frames

1. Open your directory in file manager.

2. Rename index.htm to main.htm- Right click on file and select “Rename”

This step moves your old main page into this box.

Page 17: Create Your Own Webpage. Today’s Class Internet Safety & Privacy Tables Embedding music and video Frames

Using Frames

1. In notepad, create new file (File New)

2. Type in a few things you’d like to have as links in the future, separated by <br>

- About Me <br>- Pictures <br>- Location <br>

3. Save as side.htm This creates a sidebar

with text in it. You can make them links later.

Page 18: Create Your Own Webpage. Today’s Class Internet Safety & Privacy Tables Embedding music and video Frames

Using Frames

• Go to class web site www.snotrockscience.com/cfk

• Click on HTML Shortcuts

• Copy & paste #3 into new Notepad file

• Save as index.htm (YOU SHOULD NOT BE OVERWRITING YOUR OLD INDEX FILE!)

• Note: Any references to index.htm (for example, on your pictures page) will need to be changed to main.htm

Page 19: Create Your Own Webpage. Today’s Class Internet Safety & Privacy Tables Embedding music and video Frames

Using Frames<FRAMESET cols="20%,

80%"><FRAME name=side

src="side.htm"><FRAME name=main

src="main.htm">

<NOFRAMES>Main page: <a

href="main.htm">Sidebar: <a href="side.htm"></NOFRAMES>

</FRAMESET>

• Defines the relative width of each part of your frame.

• Links to your pages (1st link is 20% wide, second link is 80%)

• Provides coding in case people are using a browser that doesn’t recognize frames. Fairly unlikely.

• Ends your frameset

Page 20: Create Your Own Webpage. Today’s Class Internet Safety & Privacy Tables Embedding music and video Frames

Edit your sidebar

• So far, all links we have created open in the same window.

• For your frames page, you’ll want the links in your sidebar to open in the main part of your webpage.

• Open side.htm and create a link:– <a href=“pictures.htm” target=main>Pictures</a>– Without specifying the target, your pages will open

in the same area from which they are linked.

Page 21: Create Your Own Webpage. Today’s Class Internet Safety & Privacy Tables Embedding music and video Frames

Optional Tweaks to Your Frameset

• Open index.htm in Notepad

• Experiment with layout… change % numbers to change relative window size.

• See if you can figure out how to make a “sidebar” across the bottom or top of a page.

• See if you can figure out how to use more than 2 pages in 1 frameset.

• What happens when you change

<FRAMESET cols="20%, 80%"> to

<FRAMESET cols="20%, 80%“ border=0>

Page 22: Create Your Own Webpage. Today’s Class Internet Safety & Privacy Tables Embedding music and video Frames

More to Do

• Find and include other images

• Expand your sidebar to organize your page by including links to the other pages we’ve created

• Create more pages and link them from your sidebar

• Benefit of using frames: Changes in navigation only have to change in your sidebar!

• Snoop on code: – IE: View Source– Firefox: View PageSource

Page 23: Create Your Own Webpage. Today’s Class Internet Safety & Privacy Tables Embedding music and video Frames

Embedding video

• Youtube makes it easy—www.youtube.com– Others – Vimeo, Google Video, etc.

• Upload your own videos to post on your web site or find something you want on your webpage

• Video owner does have option of not providing the code to embed video

• Let’s add a video to your Pictures page – open it in Notepad to get ready to edit it.

Page 24: Create Your Own Webpage. Today’s Class Internet Safety & Privacy Tables Embedding music and video Frames

• Go to youtube and find a video (i.e. search for funny dog)

Embedding using youtube

Click Share then click Embed

Page 25: Create Your Own Webpage. Today’s Class Internet Safety & Privacy Tables Embedding music and video Frames

Customize video’s appearance

Make changes:

• Related videos? Maybe not on a sale video

• Aesthetics – border, color, size

Page 26: Create Your Own Webpage. Today’s Class Internet Safety & Privacy Tables Embedding music and video Frames

Copy and Paste Custom Code

• (Left) click in the Embed field and it will turn blue

• Right click and select “copy”

• Go to Notepad file and Paste

• Save & check in browser window

Page 27: Create Your Own Webpage. Today’s Class Internet Safety & Privacy Tables Embedding music and video Frames

Embedding Music

• Can be obnoxious.

• Go to http://www.midicenter.com/– (On your own: Google free midi download)

• Browse & find a midi file you want to put on your page

Page 28: Create Your Own Webpage. Today’s Class Internet Safety & Privacy Tables Embedding music and video Frames

Follow instructions here to download. -Consider renaming w/easier filename to retype, i.e. music.mid-Save in your website directory

Page 29: Create Your Own Webpage. Today’s Class Internet Safety & Privacy Tables Embedding music and video Frames

EmbeddingMusic

• Open notepad, and add the following text to the HTML document you want the song to play on:

<embed src=FILENAME.mid width=144 height=60> – Replace FILENAME with your file name

Page 30: Create Your Own Webpage. Today’s Class Internet Safety & Privacy Tables Embedding music and video Frames

Embedding Music

• Caution: starts a plugin which may or may not work automatically on everyone’s computer.

• Try Firefox if you have problems– Adjust height and width

• Differs in Firefox vs. IE. Experiment.

Page 31: Create Your Own Webpage. Today’s Class Internet Safety & Privacy Tables Embedding music and video Frames

More text formatting

• <h1>Big heading</h1>

• <h2>Medium heading</h2>

• <h3>Smaller heading</h3>

• … etc on to <h6>

Lists

• <li>Define items to be bulleted.

• <li>2nd bulleted item.

Page 32: Create Your Own Webpage. Today’s Class Internet Safety & Privacy Tables Embedding music and video Frames

List techniques to try

<ul>

<li>1st bullet

<li>2nd bullet

</ul>

<ol>

<li>1st bullet

<li>2nd bullet

</ol>

• 1st bullet • 2nd bullet

1. 1st bullet

2. 2nd bullet

Also trying nesting lists!

Page 33: Create Your Own Webpage. Today’s Class Internet Safety & Privacy Tables Embedding music and video Frames

More formatting…

<em>This text is emphasized</em>

<strong>This text is strong</strong>

<code>This is some computer code</code>

Special symbols…

— em-dash &#8212;

© copyright &#169; or &copy;

® registered &#174; or &reg;

More: http://www.ascii.cl/htmlcodes.htm