View Single Post
  #14  
Old 05-28-2005, 08:50 PM
General Nuisance is offline General Nuisance
Registered User

Join Date: Oct 2004
Posts: 616

Send a message via ICQ to General Nuisance
my link database..

hey i finnished codeing a link database but it does not seem to work proberly....

please look over my code i have checked and checked it...

PHP Code:
<html><head><title>Add Your Link</title></head>
<body>
<?php

$self 
$_SERVER['PHP_SELF'];
$nn $_POST['nn'];
$url $_POST['url'];
$lname $_POST['lname'];
$sc $_POST['sc'];
?>
<form action="<?php echo( $self ) ; ?>" method= "post">
Your Nick Name: <input type="text" name="nn" size="25">
<BR>
Your Websites Catagory: 
  <select size="1" name="sc">
  <option>Please Select</option>
  <option>Delta Force Xtreme Resource</option>
  <option>Joint Operations Escalation Resource</option>
  <option>Joint Operations Resource</option>
  <option>Delta Force Xtreme Squad</option>
  <option>Joint Operations Escalation Squad</option>
  <option>Joint Operations Squad</option>
  </select>
<BR>
Your Websites Name: <input type="text" name="lname" size="80">
<BR>
Your Websites URL: <input type= "text" name="url" size"80">
<BR>
<input type="submit" value="Submit Your Link"> </form>
<BR>

<?php

if( $nn and $url and $lname and $sc # makeing sure fields are filled in
# connecting to Mysql
$conn=@mysql_connect"localhost""My user name""My Password" ) or die( "err:conn" );

#selecting Database

$rs = @mysql_select_db"linkdb"$conn ) or die( "err:conn" );

#create the query

$sql="insert into links (NN, sc, LName, URL) values ( $NN, \"$sc\", \"$LName\", \"$url\" )";

#execute the query

$rs mysql_query$sql$conn );

#confirm the added link

if($rs){ echo( "The Link $lname was Added To the $sc Database!" ); }
}

?>

</body></html>
see this page

HERE
__________________
The Nova-Zone


http://youraite.yourhost.yourusername.com - long urls
-looks bad
-who can remember it?
- Solution?
- Get a short Nova-Zone subdomain! Yoursite.nova-zone.com
- Now thats smart. just ask for one via pm,email or contact page on site.
Reply With Quote