Ciao a tutti,
qualcuno mi spiega perche' non riesco ad aggiornare una query
Codice PHP:
<form action="<?php echo $_SERVER['PHP_SELF'] . '?id=' . $actor_id; ?>" method="post">
<table id="biographyTable" border="0" cellspacing="0" cellpadding="0" width="100%">
<tbody>
<tr>
<td class="paramname">
<b>Nome:</b>
</td>
<td class="paramvalue">
<input name="Name" type="text" size="50" id="Name" value="<?php echo $nome;?>">
</td>
</tr>
<tr>
<td class="paramname">
<b>Biografia: </b>
</td>
<td class="paramvalue">
<textarea cols="80" name="Biography_PlainText" id="editor1" rows="10" ><?php echo $biografia;?></textarea>
</td>
</tr>
Codice PHP:
<?php
if (isset($_POST['modifica']))
{
if ($query)
{
$nome=$_POST['Name'];
$birthday=$_POST['birthday'];
$died=$_POST['died'];
$_POST['Biography_PlainText']=addslashes($_POST['Biography_PlainText']);
$query=mysql_query("UPDATE person SET
Name='".$_POST['Name']."',
birthday='".$_POST['birthday']."',
died='".$_POST['died']."',
Biography_PlainText='".$_POST['Biography_PlainText']."'
WHERE actor_id=". $actor_id);
e' un mistero