The requested URL /Joomla/administrator/{ submitbutton('updateRecord');} was not found on this server.
What am I missing so that it does what i want it to do?
The individual buttons that I have added are to update the record using the following codes both at separate files and as added in functions of admin.chronocontact.php,
Code: Select all
<?php
// DB Connect
define(db_host, "localhost");
define(db_user, "xxxxxx");
define(db_pass, "xxxxxx");
define(db_link, mysql_connect(db_host,db_user,db_pass));
define(db_name, "joomla");
mysql_select_db(db_name);
// Query DB
$select = "SELECT cf_id, stock_number, description, notes, category, model, year, serial_number, purchase, sell, retail, approved, recordtime, salesperson FROM jos_chronoforms_3";
$export = mysql_query($select);
$row_export = mysql_fetch_assoc($export);
$fields = mysql_num_fields($export);
/* Session Variables */
$cf_id = mysql_real_escape_string($_POST['cf_id']);
$approved = mysql_real_escape_string($_POST['approved']);
$approved_by = mysql_real_escape_string($_POST['approved_by']);
$sql = "UPDATE jos_chronoforms_3 SET approved = 'No', approved_by = '$acl' WHERE cf_id = '$cf_id'";
$result = mysql_query($sql); echo mysql_error();
?>
Code: Select all
<?php
// DB Connect
define(db_host, "localhost");
define(db_user, "xxxxxx");
define(db_pass, "xxxxxxx");
define(db_link, mysql_connect(db_host,db_user,db_pass));
define(db_name, "joomla");
mysql_select_db(db_name);
// Query DB
$select = "SELECT cf_id, stock_number, description, notes, category, model, year, serial_number, purchase, sell, retail, approved, recordtime, salesperson FROM jos_chronoforms_3";
$export = mysql_query($select);
$row_export = mysql_fetch_assoc($export);
$fields = mysql_num_fields($export);
/* Session Variables */
$cf_id = mysql_real_escape_string($_POST['cf_id']);
$approved = mysql_real_escape_string($_POST['approved']);
$approved_by = mysql_real_escape_string($_POST['approved_by']);
$sql = "UPDATE jos_chronoforms_3 SET approved = 'Yes', approved_by = '$acl' WHERE cf_id = '$cf_id'";
$result = mysql_query($sql); echo mysql_error();
?>