Hopefully after Wednesday's class, you are feeling empowered. Let's put your knowledge to work. We will recreate the data-driven aspect of the T-TAC home page at http://ttac.gmu.edu/ This particular page uses frames, however apparently same page, without frames, can be viewed at http://ttac.gmu.edu/p4/ (it's an .asp page). Here are the steps to follow:
1. At http://ttac.gmu.edu/p4/ you want to do one of two things:
a) In Internet Explorer, do File, Save As and save the page as source.html to your a: drive. The advantage of this approach is that all the image files are saved as well. The disadvantage is that the image files are put in a standard location, which may be different than the file structure used in the original page.
b) In Internet Explorer, View Source, and save the page as source.html to your a: drive. Then display the source.html page in your browser and see what image files you are missing. Look at the source code in the page to see where you should put them, and then right click on these images in the original TTAC page to put them in the same relative location. Once you do this, you should be able to display the entire page in your browser.
I prefer method b) but a) is quicker.
2. The source file you have is the product of an ASP page. In Notepad, save your html file as source.asp. Locate the resources, events, and online training sections of the source code. Each of these is a separate HTML table with multiple rows.
a) You want to take the content out of the HTML table and put it in an Access database (cut and paste -- don't type). In Access the data type of text is limited to 255 characters, so you will want to use memo which permits over 65,000 characters in a field. You can create three tables in your Access database for this, or do it in 1. (Doing it in three tables most directly tracks what we did in the last class. If you use one table in Access, one of the fields in your Access database will be type - resources, events, or workshops) Assume that all entries will have the new icon so this will be in the first column of the table.
If you use three tables, your code for subsequent assignments will be simpler if you use the same field names for each of the tables. However, if you would like to learn how to accommodate different field names across tables, I will provide code samples to help you do that in these future assignments.
b) In your source.asp file, take out the extra rows in your HTML tables so that you only have one row in the resources table, one row in the events table, and one row in your HTML table for workshops.
3. Add in the ASP code to a) connect your source.asp file to your Access database and b) execute one or more SQL statements. For a), you will probably want to paste in what we did the other day since it's so sensitive to spaces, etc.
4. Create three loops using ASP -- one for resources, one for events, one for workshops. The ASP code will loop through the table in your Access database and to extract the database values out of the database. For the former, you can paste in what we did the other day.
5. To test your ASP code, use Personal Web Server
6. When you are done, create an index.htm or index.html page and put it at the top level of your web space on the ASP server that is being used for this class. On this index page, you will put links to the work you do in this class. FTP the index page and the files linked to it to your web space so that the instructor can view them. For any ASP file, you should also create a .txt version of the file and link to this as well so that the instructor can see your ASP code.
Due: Wednesday, September 25. Each of you should do this on your own, but of course feel free to ask for help from me or others if you get stuck.
Revised: October 25, 2002