Problem creating Insert Record Page
I have successfully built and run a mySQLi Insert Record page using WebAssist MySQLI Server Behaviors on a Test Page. So I know that it works!
Am now struggling to repeat it (different page and different databases).
Have built Recordsets and created a Form with all its text fields and menus.
Using MySQLi Insert Record have created dynamic links between each column value and the appropriate form element (listed under Bindings).
On OK - php is added to the top of the page ...
<?php
if ($_SERVER["REQUEST_METHOD"] == "POST") {
$InsertQuery = new WA_MySQLi_Query($connsheffieldarchives);
$InsertQuery->Action = "insert";
$InsertQuery->Table = "items";
$InsertQuery->bindColumn("itemNo", "i", "".((isset($_POST["itemNo"]))?$_POST["itemNo"]:"") ."", "WA_DEFAULT");
$InsertQuery->bindColumn("itemTitle", "s", "".((isset($_POST["itemName"]))?$_POST["itemName"]:"") ."", "WA_DEFAULT");
....................
$InsertQuery->saveInSession("andrew_test");
$InsertQuery->execute();
$InsertGoTo = "../lists/full_listing.php";
if (function_exists("rel2abs")) $InsertGoTo = $InsertGoTo?rel2abs($InsertGoTo,dirname(__FILE__)):"";
$InsertQuery->redirect($InsertGoTo);
}
?>
Within the code for the Form, nothing is added.
With nothing in the form - nothing happens to the form menus.
The successful Test Page Form had code inserted into it and the menus worked.
Non working page - "Server Behaviors" lists Insert Record and Recordsets.
The "Server Behaviors" for the successful Page also shows MySQLi Dynamic List/Menu for the two tables that are providing data which is being inserted into the third. There are no values entered.
I am now going round in circles recreating the page.
Where am I going wrong? Help would be much appreciated.
Thanks in anticipation.