session_start();
// TransEditUpdate.php - updates user info.
$libdir = '/var/www/html/new/lib/';
include($libdir.'settings.php');
require($libdir.'proclib.php');
include($libdir.'head.php');
include($libdir.'datacon.php');
// include("datacon.php");
// require('/var/www/html/new/lib/proclib.php');
// require('/var/www/html/new/lib/head.php');
echo "
Edit User Information\n\n\n";
/*
$org = addslashes($org);
$address = addslashes($address);
$city = addslashes($city);
*/
if (count($_POST) > 0)
{
foreach($_POST as $key => $value)
{
if (! empty($_POST[$key]) and ! is_numeric($_POST[$key])) {
$_POST[$key] = addslashes($_POST[$key]);
}
}
}
// mail("nccs@ui.urban.org","Information Request","Email: $email\nLast name: $lname\nFirst name: $fname\nTitle: $title\nOrganization: $org\nOrganization Type: $OrgType\nAddress: $address\nCity: $city\nState: $state\nZip: $zip\nPhone: $phone\nRequested password: $password\nComments: $comments\nReasons: $reasons\nRequest type: $reqType\nTo update this record: http://communityplatform.us/PubApps/regis/requestIntro.php","From: nccsDataWeb@ui.urban.org\r\n");
// include("registration_reg.php");
$idAuto = mysql_result($idAutoResult,0,"idAuto");
$today = date('Y-m-d');
// Add transaction record;
$details = "RequestType: $reqType\n Email: $email\nLast name: $lname\nFirst name: $fname\nTitle: $title\nOrganization: $org\nOrganization Type: $OrgType\nAddress: $address\nCity: $city\nState: $state\nZip: $zip\nPhone: $phone\nRequested password: $password\nComments: $comments\nReasons: $reasons\nRequest type: $reqType";
$query = "INSERT INTO admin.sp_list
(ticket_createdby_userid, ticket_owner_id, ticket_short_description, ticket_full_description, ticket_status, ticket_severity, groups
ticket_added_date)
VALUES
($idAuto, $idAuto, QUOTE('$details') , QUOTE('$details'), 'Open','Medium','2', '$today')";
$q = "UPDATE admin.sp_list SET
ticket_id = $ticket_id,
ticket_added_date = '$ticket_added_date',
ticket_lastaction_date = '$ticket_lastaction_date',
ticket_finished_date = '$ticket_finished_date',
ticket_status = '$ticket_status',
ticket_severity = '$ticket_severity',
ticket_owner_id = $ticket_owner_id,
ticket_short_description = '$ticket_short_description',
ticket_full_description = '$ticket_full_description',
ticket_createdby_userid = IFNULL($ticket_createdby_userid,0),
ticket_createdbyemail = '$ticket_createdbyemail',
ticket_lastupdate_userid = IFNULL($ticket_lastupdate_userid,0),
ticket_reason_closed = '$ticket_reason_closed',
groups = '$groups',
amt_due = IFNULL($amt_due,0),
am_paid = IFNULL($am_paid,0)
WHERE ticket_id = $ticket_id"
";
$resultupdate = runSql($queryupdate);
$numberupdate = mysql_Numrows($resultupdate);
$result = runSql($query);
return;