View Single Post
Old Jun 1st, 2005, 12:44 PM   #3
big_k105
PFO Founder

 
big_k105's Avatar
 
Join Date: Mar 2004
Location: Fargo, ND
Posts: 1,649
Rep Power: 10 big_k105 is on a distinguished road
Send a message via AIM to big_k105 Send a message via MSN to big_k105 Send a message via Yahoo to big_k105
what do you know how to do in perl that you will need for this project? if you know how to access and get info from the db then it is just a matter of taking the info from the db and putting it into the html menu.

   #!/usr/bin/perl -w
   # Created by: Kyle Kjorsvik Date 1-26-04
   use CGI		qw/:standard/;
   use CGI::Carp	qw/fatalsToBrowser/;
   use DBI;
   	$dbh = DBI->connect("dbi:Pg:dbname=".$dbname." host=127.0.0.1", "username","pass")
   		or die "Can't connect to database\n";
   	$sth1 = $dbh->prepare("SELECT * FROM dbtable WHERE something");
   	$sth1->execute;
   	if ($sth1->rows){
   		$i = 0;
   		while ((@tstnwk) = $sth1->fetchrow_array){
 			//move move stuff from db to variables you want them in
   			$i++;
   		}
   	}
   	$sth1->finish;

That code should work for connecting to a db but i dont have anything specific in there
your turn to write some code and if you need help please post it

oh and it normally takes more then 1 min for you to get help so you dont need to create another post to see if we are reading only 1 min after you created the thread. try and wait say like 4 hours
__________________
BIG K aka Kyle
Programming Forums
Kyle K Online

Please do not PM or email me programming questions. Post them in the forums instead.

Last edited by big_k105; Jun 1st, 2005 at 10:01 PM.
big_k105 is online now   Reply With Quote