#!usr/local/bin/perl; package studentdata; use lib '\\\\140.247.216.106\\inetpub\wwwroot\columbia'; use CGI ("shortcuts"); use CGI::Carp qw(fatalsToBrowser); $query=new CGI; #Use the ODBC module use Win32::ODBC; #our dsn use ISLib; my $DSN='DRIVER={Microsoft Access Driver (*.mdb)};DBQ=\\\\140.247.216.106\\inetpub\wwwroot\columbia\database\colum.mdb';print $query->header(); my $ISobj= new ISLib('Edit Student Profile'); print $ISobj->pagetop(); #open a connection to it my $O = new Win32::ODBC($DSN) || die "Unable to open DSN $DSN\n"; ##The page is called by StudentID or "new" ##Grab any existing data my %sdata; %sdata=(); if ($query->param('StudentID') eq "") { $StudentID = "new"; $sdata{'FirstName'}=$query->param('FirstName'); $sdata{'LastName'}=$query->param('LastName'); } else { $StudentID = $query->param('StudentID'); if (! $O->Sql("SELECT * FROM Students WHERE StudentID = $StudentID ")) { ( $O->FetchRow() ) || print $O->DumpError(), "\n"; %sdata = $O->DataHash(); } } $O->Close(); print qq[

]; # print "Student ID:",$query->param('StudentID'); unless ($StudentID eq "new"){ print qq! \n \n \n !; } else { print qq!
Name: $sdata{'FirstReal'} $sdata{'LastReal'}
\n ! } print qq! \n \n \n \n \n \n \n \n \n
First Name:
Last Name:
Email: \n
Affiliation (year): \n
Telephone number:
Hometown:
Favorite website (URL):
Internet-related research interests:
Favorite book:
Fun facts about you:
Password:
Enter password again:
 

Note: Your profile will not appear in the class list immediately.

   

 

Check this box to specify a nickname to be used in place of your real name:

Public first name:   Public last name:
!; print qq! \n

!; #

Your profile will be displayed on a student list visible to all members of the class. #Class pages may also be made available to the interested public. If you like, you may enter a pseudonym #for your "public name," to be listed with your profile and comments on the website. \n #You must also enter your real name here for administrative and grading purposes.\n #Please consider using your real name publicly, so that you will be able to continue your #classroom conversations online, and vice versa.\n #To ensure continuity of the online discussions, you will not be able to modify your public name, #though you will be able to edit other elements of your profile.

print $ISobj->pagebottom;