Ricardo,
I have noticed several things from just a quick look at your code:
1. If your not able to post any data/receive any variables from your form
when the submit button is clicked, you could have register_globals set to
Off. Here is a example form used for that situation:
<form name="form1" method="post" action='<?php $_SERVER['PHP_SELF'] ?>'>
<center><input type="submit" name="register" value="REGISTER">
Please note that I used $_SERVER instead of PHP_SELF alone, and note the use
of the single quotes. This is done when register_globals is turned off,
which I have learned is the best way to write your scripts (thanks to the
other guys & gals on this discussion board).
2. Using
if (isset($submit)) { stuff......}
is another thing i've been taught to do, rather than if($submit).
3. You haven't given a variable name to your submit button:
<input type="submit" value="Enviar"></form>
give the submit button a name="submit" and you will actually have a variable
which your script can pick up. Otherwise nothing will happen.
HTH,
-Kirk
"Ricardo Fitzgerald" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> Hi,
>
> I've been unsuccesfully trying to add a php script to a postnuke menu.
> What I did is a simple form, that connects to a mysql database, and
> inserts data, then some data is retrieved to generate a page with
> "Welcome $name $lastname ... and so on"
> The problem is the script must be in the center and must include the
> header, the footer and the left block, I don't understand many things
> from the way postnuke works, and I couldn't display any variable
> entered in the form, neither insert data into the db ...
> I've tried with action="some.php" and action=<?php PHP_SELF?>;
> so far I only got parsing errors.
>
> Any ideas ?
>
> Regards,
>
> Rick
>
>
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php