Lab L-6 Creating a Website

Let’s build a website. You’re going to create a project and put it on your website.

 

Do this

It’ll look like this

  1. Let’s start by creating a simple test page using Fedora’s version of Notepad.
  2. Remember that root is the owner all of these files, so we’re going to have to open the program as su (super user).
  3. Open your terminal
  4. Log in as superuser.
  5. Type gedit to open the text editor. It is now running as root. BE CAREFUL with this. Do NOT run other programs as root unless you know what you’re doing. The root account is used ONLY for system maintenance and in special cases.

 

 

  1. Let’s make a simple website. Type the code shown at the right, exactly as shown.
  2. Save this file as index.html in the folder /var/www/html
  3. Go into Firefox and load up either localhost or your ip address.
  4. What do you see?

<html>

<head>

<title>My happy little website</title>

</head>

<body>

Hello World!

</body>

</html>

  1. If it didn’t work, go back over the instructions very carefully and fix it. Do not move on until you can see your site.
  2. Let’s add a few more pages and test linking.
  3. On the page you have, add the code to the right between the body tags.
  4. Note that the <br> tag sends a line break, so put it wherever you want a hard return.

<a href=”test.html”>Testing a link</a><br>

<a href=”test2.html”>Testing another link</a>

  1. Now create two more pages. One named test.html. Add some stuff to it. Save in the /var/www/html folder. (We’ll do test2 in a minute.)
  2. Put something on them so you know they work when you click the links. Use the coding from step 6, just change it up some.
  3. I know some of you know html, and others don’t, so this is just a taste. It’s REALLY easy, actually. It’s your basic open tag…stuff you want to say…close tag. So if you want something bold you do <b>this is the stuff I want bold</b>. If you want it underlined it’s <u></u> etc.

Have me check off your highly effective and wonderful site before you go onto step 18.

  1. Test out the pages. Do they work? Beautimus!
  2. But who uses a text editor to write webpages? Okay, I do but I’m old skool and I roll like that.
  3. Let’s open Openoffice to create your site. You can delete those other pages if you’d like. You’ll be writing over index.html.

 

  1. Close gedit. You should end up back at the terminal.
  2. Normally when just using OpenOffice you select it from the Applications menu, but we want to open it as su because we’re going to save in the html folder, and as you, you can’t save to that folder. (Test it first and see if you can, I could NOT even with proper permissions applied.)
  3. Go to terminal.
  4. Log in as su
  5. type –c openoffice.org
  6. Go ahead and create a new writer page
  7. Save as test2 in /var/www/html. At the bottom.
  8. Toss a picture or two on it, some text. Go ahead and format it however. I put a picture of a Dachshund in a hot dog bun. Whatever floats your boat! We’re just practicing.

Wor951

 

Uncheck when you save “ask when not saving in ODF format”

  1. One you have a feel for this, you’re going to create a website where you will post your project. Decide which webserver the project will be posted on.
  2. Create a page that looks like this (use your own graphic) and save it as index.html in /var/www/html
  3. It should have the following sections:
    1. Customer Overview
    2. Current Needs
    3. Future Needs
    4. Proposal to Fulfill Future Needs
    5. Projected Cost of Project
    6. Diagram of Project
    7. Resources for More Information
  4. Once you have the homepage set up, you’re going to set up your webserver so your partners can edit on their computers and save to yours using ftp.

index

 

 

Questions

  1. What are two programs you can use to create a website?
  2. Why do you have to log in as a super user to save to the html folder?
  3. What groups are you currently a member of?
  4. What is gedit?
  5. What is openoffice.org?
  6. What is the html code for creating a link that says “Hot Dawg” and links to http://www.hotdawg.com?
  7. Why use OpenOffice over Gedit?
  8. Why learn a little HTML, when you have OpenOffice and other graphical programs available for creating websites?