CSCI 100 - Homework 1My first web page

Due before midnight, Thursday 15 Feb 2007

In this assigment you will be setting up your web space and creating your first few web pages! You will need to have a CS account to do this assignment. Please contact me or Nate the SysAdmin <ned@cs.oberlin.edu> ASAP if there is a problem with your account.

Part 1 - Welcome to Unix

Hopefully, we'll be able to get through this in class on Thursday. If you've managed to miss out, you can follow these instructions.

From the lab

Log into one of the machines in the lab. You should be presented with a desktop. You can open up a terminal window (XXX) and follow the instructions for outside if you want.

  1. Open up your Home directory. You should be able to right-click and tell it to create a folder called www. Right-click on that and make sure the permissions are set for everyone/other to be read and execute.

  2. Now double click on that to open up the folder. Inside there, you'll create another folder called csci100. Set the permissions the same way.

  3. Finally, enter that folder and create another subfolder called hw01 and set the permissions again.

Note: You can also use these instructions if you are using tools like Fugu or WinSCP.

From outside the lab

  1. Log into occs.cs.oberlin.edu using ssh
  2. You should already have a www directory. You can verify that it is exists and has the proper permissions by using the command "ls -ld www". You should see something like
        drwxr-xr-x    7 username students      1024 Feb  4 14:15 www/
    You will know that you don't have the directory if you get a message similar to the following:
        ls: www: No such file or directory
    You can fix it by using the following commands (type exactly or cut and paste):
        mkdir www
        chmod a+rX www
  3. Go into that directory
        cd www
  4. Make a new subdirectory:
        mkdir csci100
        chmod a+rX
    This is where you will put all of your assignment directories.
  5. Now we will create a subdirectory of that by first entering that directory and then repeating the process.
        cd csci100
        mkdir hw01
        chmod a+rX hw01
    This is where you'll put your first assignment.

Part 2 - Your first HTML file

Create a web page called index.html inside the www/csci100/hw01 directory with the following information:

  1. A descriptive <title> including your name
  2. A descriptive top level header (<h1>) including your name
  3. A subsection about yourself (under a <h2> header) that has the following sub-subsections (<h3> or further):
    1. What name you go by
    2. Where you are from
    3. How you would describe yourself
    4. Any hobbies you want to share
    5. Something interesting about yourself that you'd like to share with others
  4. Another subsection about yourself and Oberlin with the following information (appropriately divided and labeled):
    1. Briefly describe Oberlin College in your own words
    2. Say something about the town of Oberlin (what you think of it, favorite place, etc.)
    3. What your major is and why you enjoy studying it
    4. What groups or organizations you participate in
  5. A final subsection containing information of your chosing with appropriate headers, sub-sections, etc.
  6. Update 2/10: Include a final paragraph attesting to your compliance with the honor code. Feel free to put it under a header.

Note: You can also create this file on your own computer and then upload it to the directory specified above.

Part 3 - Sharing it with the world

Now that you've created your first web page, you'll want to share it with everyone in the world. One thing that I'd like you to keep in mind is that anything that is on the web is potentially available to anyone else. For that reason, you should feel free to falsify or be creative with any information I request from you. Any "real" information that I need from you won't be done via your website.

Recall from class that all directories need to be executable and files need to be readable by everyone. If you are interacting from a graphical interface (directly logged in, Fugu, WinSCP) you can set the permissions by right-clicking on the file and setting the permissions.

From the command line, you'll need to use the program chmod to change permissions. You just need to to use this command:

chmod a+r index.html

Notes for later projects

For this course, the easiest thing to do is just remember the following command as it will set the proper permissions of all files and directories in your class website:

chmod -R a+rX ~/www/csci100

What follows is more detail than you need to know: Breaking this down, the "-R" option tells it to recursively change permissions. That means it will fix the permissions for your www/csci100 directory and for every file or directory contained within.

The "a+rX" sets permissons for all users (user, group, and other) to add (specified by "+") read permissions (specified by the "r") and execute permission added only if it is a directory (hence the capital "X").

Verifying it works

You should now be able to see your webpage by going to:

http://www.cs.oberlin.edu/~username/csci100/hw01/

where username is your CS username.

Part 4 - Handing it in

Once you've got your webage working, take a moment and congratulate yourself. You've now created your very own webpage from scratch. The last thing you need to do is submit your page electronically. To do that, you need to log into the CS computers (either occs or one of the lab machines). Start up a terminal and execute the following two commands:

cd www/csci100
handin -c cs100 -a 1 hw01

Congratulations! You're done.


Last Modified: February 11, 2007 - Benjamin A. KupermanVI Powered