Bring a job entry into editable forms. Coded Jan. 18th, 2002. (c) 2002 Adam Drake adam@brainrub.com */ // require_once __DIR__."/lib/KLogger.php"; // Include KLogger first so config sets log dir // Database connection object (Which auto-loads all the site configuration.) require_once __DIR__ . "/data/DBConnector.php"; $css = "bio.css"; $p_jobid = ""; if (isset($_REQUEST["p_jobid"]) && $_REQUEST["p_jobid"] != "") { $p_jobid = $_REQUEST["p_jobid"]; } $job_query = "SELECT ALL a.job_id,a.from_date,a.to_date,a.jobtitle,a.company,\n a.comp_type,a.street,a.city,a.stprv,a.country,\n a.postcode,a.notes,a.co_workers,\n DATE_FORMAT(a.from_date, '%b. %Y') AS fmtfromdt,\n DATE_FORMAT(a.to_date, '%b. %Y') AS fmttodt\n FROM my_jobs a\n WHERE (a.job_id = {$p_jobid})\n LIMIT 1;"; // connect to the database $db = dbconnector::connect(); // print($job_query); // Prepare $stmt = $db->prepare($job_query); // Execute $retVal = $stmt->execute(); // Row count... $rows = $stmt->fetchAll(PDO::FETCH_ASSOC); $rs1 = $db->query('SELECT FOUND_ROWS()'); $row_count = (int) $rs1->fetchColumn(); // If row count > 0, do stuff... $stmt = null; $ctr = 0; $pagetitle = "My Job: Edit"; // default html header with comments include "elements/header.php";