Jump to content

[SOLVED] help with form


MDanz

Recommended Posts

<?php
$id = $_GET['id'];




$change = "<form enctype='multipart/form-data' action='insert10.php' method='post' name='changer'>
         <font color=#FF6600 font face=Arial font size=2>Change background</font><br>
<input type='text' name='change' value='' size='20'>
<input type='hidden' name='id' value='$id' size='20'>
<input type='submit' name='background' value='Submit' style='font-size:10px'></form>";

echo "$change";
?>

 

the form is working but the below isn't..

 

 

$username1 = $_SESSION['username'];
       $change = mysql_real_escape_string($_POST['change']);
       $id = mysql_real_escape_string($_POST['id']);
       
       $query= mysql_query("UPDATE suscribed SET image='$change' WHERE username='$username1' AND id='$id'") or die (mysql_error());

Link to comment
https://forums.phpfreaks.com/topic/175714-solved-help-with-form/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.