>INSERT INTO employees (first,last,address,position) VALUES
>is because in WML variables are stored as $(first) and not just $first
>$sql = "INSERT INTO employees (first,last,address,position)
> > VALUES ('$(first)','$(last)','$(address)','$(position)')";
> > $result = mysql_db_query ("mydb", $sql);
>it seemes to loose the values of all my variables!!
>I would appreciate any help anyone can be since I have been working in this
>for 2 days solid now and haven't managed to fix it (though i have managed to
>recreate it in many different ways!!)
WML variables are not PHP variables. The way I do this is to have get the
input in a card
like you have it then submit it to another php script that processes it just
like it would process any form data submitted. Doing it this way they all
end up as regular php variables.
For example, gather all your data as you have it, but instead of sending it to
another card where you process it send it to a php script which handles it.
script need not even be wap compliant, it can just process and that's it,
probably want it to be to confirm that it did what it did. In your case,
<card id="card2" title="Registered">
where myurl is the url to a script which contains something like:
echo("<!DOCTYPE wml PUBLIC \"-//WAPFORUM//DTD WML 1.1//EN\"
echo("<!-- The application nmorequoter is (c) 2000 nmore.com -->\n");
<meta forua="true" http-equiv="Cache-Control" content="max-age=0"/>
<card id="add" title="update database">
$sql = "INSERT INTO employees (first,last,address,position) VALUES
$result = mysql_db_query ("mydb", $sql);
echo 'All done: '.$sql.'</br>';
"To dwell within Samsara, however, is to
be subject to the works of those mighty
- Mahasamatman, in Zelazny's "Lord of Light"
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]