Some of you might already have seen this form however it got it loads up without errors. after deciding to clean it up
However it does not add anything in to the database. infact i got 3 questions.
1: are php functions private by default, since it would reconize the ".$tablename." in the INSERT INTO line.
2: how can i actually have form input being added into the database.
3. how can i make this page return automaticly to the form again.
function process_form()
{
// are all these values going into the field PONGO or is pongo the table name? if it's the table name, instead of the table name put field names like i've done
$query ="INSERT INTO (empresa, codigo, desde, envio, envio, information, comentario, peso_total, peso, valor) VALUES ('".$_POST['Empresa']."','".$_POST['Codigo']."','".$_POST['Desde']."','".$_POST['Envio']."','".$_POST['Information']."','".$_POST['Comentario']."','".$_POST['Peso_Total']."','".$_POST['Peso']."','".$_POST['Valor']."')";
//then do this and see if you get any errors...
$result = mysql_query($query) or die (mysql_error());
}
Oke did it... well i feel i am getting better sinds now there was ecually a error being returned.. :>
Connectando Con Base Datos pongo , avancar! You have an error in your SQL syntax. Check the manual that corresponds to your MySQL server version for the right syntax to use near '(Empresa, Codigo, Desde, Envio, information, comentario, peso_t
it might be me .. or just because you could boil a egg on my head now with the 40 degrees C however i am lost
but as far as the $_POST question, i'm not very sure. so instead i'll just give you some examples and explain every portion of that question to make sure i answer it..
basicallly, you can call $_POST['whatever'] anywhere you want..