Welcome, guest! Login / Register - Why register?
Psst.. new poll here.
Psst.. new forums here.
Microsoft is blocking us again (TY IP Reputation!) so dont bother with any of their useless mail servers here and just use oauth login instead. Thank the nice Russians for causing that. :)

Paste

Pasted as HTML by nicnic22 ( 16 years ago )
<?php

$db = mysql_connect("localhost","root","root"); // husk at fjerne pw på pc
if (!$db)
  {
  die('Could not connect: ' . mysql_error());
  }

mysql_select_db("nactown", $db);


$navn   =  $_REQUEST["navn"];
$kommentar  =  $_REQUEST["kommentar"];



$sql="INSERT INTO kommentarer (navn, kommentar) VALUES ('$navn', '$kommentar')";


if (!mysql_query($sql,$db))
  {
  die('Error: ' . mysql_error());
  }

mysql_close($db);
?>
<?php header("Location: yoink.php");

 

Revise this Paste

Your Name: Code Language: