Jump to content

ianhaney50

Members
  • Content Count

    261
  • Joined

  • Last visited

  • Days Won

    1

ianhaney50 last won the day on August 17 2016

ianhaney50 had the most liked content!

Community Reputation

1 Neutral

About ianhaney50

  • Rank
    Advanced Member
  1. Hi Thank you for the reply, appreciate it Sorry yeah I realised that shortly after posting my question, so sorry, is perfect now
  2. Hi I just found another little issue, not sure why it is outputting all the records as before it just outputted the id record I click on The code for the specific id record is below <?php ini_set('display_startup_errors',1); ini_set('display_errors',1); error_reporting(-1); ?> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html> <head> <title>IT Done Right Admin View Repair Tracking</title> <link rel="stylesheet"href="http://ajax.googleapis.com/ajax/libs/jqueryui/1.11.2/themes/blitzer/jquery-ui.css"/&g
  3. So sorry, I thought the easier way would be to make the datepicker be in standard format of yy/mm/dd code and tested it and works perfect now and now displays on the page as 28/11/2015 so is perfect now, so sorry for being a pain
  4. Hi Barand I just added that to the INSERT query so now looks like the following if ($stmt = $mysqli->prepare("INSERT repairs (customer_name, customer_email, customer_phone, computer_make, computer_model, technician, status, exrdate, exrtime, (STR_TO_DATE($exstdate, '%d/%m/%y') ), exstime, deltype, comments) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)")) I selected 8/11/2015 within the datepicker but has outputted it as 10/4/2015
  5. I renamed the $date to the name of $exrdate and it worked but it outputted the date as 10/4/2015 instead of 4/10/2015 and also it should be 4/11/2015 not 4/10/2015 also how do I get that to work for a second date as well as I have exrdate and exstdate
  6. I just tried that and didn't work still, I added it directly above the insert query
  7. Thank you so much, works perfect I just found another little issue when testing, the record date is being inserted into the mysql table as 00/00/0000 instead of the actual date, I am using datepicker, the INSERT query is below if ($stmt = $mysqli->prepare("INSERT repairs (customer_name, customer_email, customer_phone, computer_make, computer_model, technician, status, exrdate, exrtime, exstdate, exstime, deltype, comments) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)")) The datepicker coding is below <script> $(function() { $( "#exrdate" ).datepicker({ showButtonPane
  8. Thank you so much, works perfect I just found another little issue when testing, the record date is being inserted into the mysql table as 00/00/0000 instead of the actual date, I am using datepicker, the INSERT query is below // insert the new record into the database if ($stmt = $mysqli->prepare("INSERT repairs (customer_name, customer_email, customer_phone, computer_make, computer_model, technician, status, exrdate, exrtime, exstdate, exstime, deltype, comments) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)"))
  9. Hi I am trying to work out how to display a specific number of characters in a echo row, the line looks like the following echo "<td>" . $row->comments . "</td>"; Thank you in advance Sorry I did look on Google but couldn't see a way to do it with the similar coding I have above
  10. I did notice the form on the edit page has the method post instead of get so am guessing is best to replace $_GET with $_POST
  11. Below is the view page that calls the edit page <?php $host = ''; $user = ''; $password = ''; $dname = ''; $db = new mysqli($host, $user, $password, $dname); if ($db->connect_errno) { echo "Failed to connect to MySQL: (" . $db->connect_errno . ") " . $db->connect_error; } $sql = "SELECT id, customer_name, customer_email, customer_phone, computer_make, computer_model, technician, status, exrdate, exrtime, exstdate, exstime, deltype, comments FROM repairs"; $result_db = $db->query(
  12. Hi I have added in the var dump line and that outputs the following array(1) { ["id"]=> string(2) "20" } So $_POST is better then, that right? If so do I just change $_GET to $_POST
  13. Hi I am trying to populate a form ready to update the data and have managed to get the id number displaying in the input field but for every other input field, it displays the following <br /><b>Notice</b>: Undefined index: customer_name in <b>/home/sites/it-doneright.co.uk/public_html/admin/repairs-tracking/edit-repair-tracking.php</b> on line <b>40</b><br /> I really don't get it or see where I am going wrong with it, below is the whole code on the edit-repair-tracking.php page <form action="update-admin-repair-tracking.php" method="pos
  14. So sorry it is my fault, I am so stupid, there was no data for id 17 but was sure there was, so sorry, let me just slap myself, so sorry
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.