Jump to content

jarv

Members
  • Posts

    325
  • Joined

  • Last visited

Everything posted by jarv

  1. hmm Magic_Quotes? the data in the database is: <div class="social"> <span class='st_sharethis_hcount' displayText='ShareThis'></span> <span class='st_facebook_hcount' displayText='Facebook'></span> <span class='st_twitter_hcount' displayText='Tweet'></span> <span class='st_linkedin_hcount' displayText='LinkedIn'></span> <span class='st_fblike_hcount' displayText='Facebook Like'></span> <span class='st_email_hcount' displayText='Email'></span> </div>
  2. hi, I have some HTML to edit in my database, in my back end administration I have it in a textarea but when I go to edit it, it all messes up and lots of '/' area added, see below: Site Design by: <a href=\\\\\\\"http://www.jbiddulph.com\\\\\\\" target=\\\\\\\"_blank\\\\\\\" title=\\\\\\\"John Biddulph - Web Development\\\\\\\">jbiddulph.com</a> php code <p> <label>Site Design by</label> <textarea class="text-input small-input" name="SiteDesignby"><?php echo $row1['SiteDesignby'] ?></textarea> </p> someone suggested adding this to my page: SiteDesignby.value = SiteDesignby.value.replace(/\\*."/g,'"'); I added the code and nothing changed! Can anyone help please?
  3. I get the following error when trying to send an email: Internal Server Error The server encountered an internal error or misconfiguration and was unable to complete your request. Please contact the server administrator, [email protected] and inform them of the time the error occurred, and anything you might have done that may have caused the error. More information about this error may be available in the server error log. Apache/2 Server at www.affordableappliancerepairs.co.uk Port 80
  4. here are my pages below: the text isn't going onto the next line even if I put text on a new line in my email form?! Email form: <form action="send-massemail-script.php" method="post" name="form" onsubmit="return validate()"> <fieldset> <!-- Set class to "column-left" or "column-right" on fieldsets to divide the form into columns --> <p> <label>Customer Name</label> <select name="name" id="name"> <option value="Please select name">Please select name</option> <?php while($row1 = mysql_fetch_array($result3)) { echo '<option value="'.$row1['id'].'">'.$row1['customer_name'].'</option>'; } ?> </select> </p> <p> <label>Email Title</label> <input class="text-input small-input" type="text" id="small-input" name="EmailTitle" /> </p> <p> <label>Email Body</label> <textarea rows="15" cols="79" name="EmailBody" id="textarea" class="text-input textarea wysiwyg" style="width: 930px; height: 247px;"></textarea> </p> <p> <input class="button" type="submit" value="Send Email" /> </p> </fieldset> <div class="clear"></div><!-- End .clear --> </form> send_mail page: <html> <head> <script> function validate(){ var temp if (document.form.name.value=="Please select name") { alert("Please select a customer.") return false } return true } </script> </head> <body> <?php error_reporting(E_ALL); print_r($_POST); include_once("config.php"); $EmailTitle = mysql_real_escape_string($_POST['EmailTitle']); $EmailBody = mysql_real_escape_string($_POST['EmailBody']); $id = mysql_real_escape_string($_POST['id']); echo $id; $query5 = mysql_query("SELECT * FROM aarbookts_booking_bookings WHERE id = '$id'"); $row5 = mysql_fetch_array($query5); $customer_name = $row5['customer_name']; $EmailBody = filter_input(INPUT_POST, 'EmailBody', FILTER_SANITIZE_STRING); $to = $row5['customer_email']; $from_header = "From: [email protected]\r\n"; $from_header .= "Reply-To: ". strip_tags($to) . "\r\n"; $from_header .= "MIME-Version: 1.0\r\n"; $from_header .= "Content-Type: text/html; charset=ISO-8859-1\r\n"; $EmailBody1 = '<html><body>'; $EmailBody1 .= '<p><strong>Dear '.$customer_name.'</strong></p>'; $EmailBody1 .= '<p>'.$EmailBody.'</p>'; $EmailBody1 .= '</body></html>'; $EmailTitle = 'Subject'; if($EmailBody != "") { //send mail - $subject & $contents come from surfer input mail($to, $EmailTitle, $EmailBody1, $from_header); // redirect back to url visitor came from $msg = "Mass email sent"; header("Location: send-mass-email.php?msg=$msg"); } else { print("<HTML><BODY>Error, no comments were submitted!"); print("</BODY></HTML>"); } mysql_close($link); ?> </body> </html>
  5. yeah, I suppose I could do it with 301 redirect although, not sure what the next page would be named if a new page was added?!
  6. hi, on my site when I click on a different page link that has been built in my database it links to that page ID and shows it in the address bar as index.php?pageid=2 as PageID is Services, is it possible to have website.co.uk/services instead? the link name / page name is also in the database under that ID
  7. sorry, I think it's working, emails were going to JUNK
  8. sorry, there are no errors, i think it just posts to ID 1 all the time?!
  9. hi, I wrote an email script but it doesn't work properly?! the intention is, in the dropdown ID has a value of either '999999', '1' or '2' at the moment as there are 2 IDs in the database if the ID = 999999 then send email to ALL - ie; 1 and 2 else get ID and post to that ID form: <form action="send-massemail-script.php" method="post"> <fieldset> <!-- Set class to "column-left" or "column-right" on fieldsets to divide the form into columns --> <p> <label>Selected Bookings</label> <select name="id"> <option value="999999">Send to all customers</option> <?php while($row1 = mysql_fetch_array($result3)) { echo '<option value="'.$row1['id'].'">'.$row1['customer_name'].'</option>'; } ?> </select> </p> <p> <label>Email Title</label> <input class="text-input small-input" type="text" id="small-input" name="EmailTitle" /> </p> <p> <label>Email Body</label> <textarea rows="15" cols="79" name="EmailBody" id="textarea" class="text-input textarea wysiwyg" style="width: 930px; height: 247px;"></textarea> </p> <p> <input class="button" type="submit" value="Send Email" /> </p> </fieldset> <div class="clear"></div><!-- End .clear --> </form> script: <?php error_reporting(E_ALL); print_r($_POST); include_once("config.php"); $EmailTitle = mysql_real_escape_string($_POST['EmailTitle']); $EmailBody = mysql_real_escape_string($_POST['EmailBody']); $id = mysql_real_escape_string($_POST['id']); echo $id; if($id == '999999'){ $query5 = "SELECT * FROM aarbookts_booking_bookings"; $result5 = mysql_query($query5); while($row5 = mysql_fetch_array($result5)) { $customer_name = $row5['customer_name']; $EmailBody = filter_input(INPUT_POST, 'EmailBody', FILTER_SANITIZE_STRING); $to = $row5['customer_email']; $from_header = "From: [email protected]\r\n"; $from_header .= "Reply-To: ". strip_tags($to) . "\r\n"; $from_header .= "MIME-Version: 1.0\r\n"; $from_header .= "Content-Type: text/html; charset=ISO-8859-1\r\n"; $EmailBody1 = '<html><body>'; $EmailBody1 .= '<p><strong>Dear '.$customer_name.'</strong></p>'; $EmailBody1 .= '<p>'.$EmailBody.'</p>'; $EmailBody1 .= '</body></html>'; $EmailTitle = 'Subject'; if($EmailBody != "") { //send mail - $subject & $contents come from surfer input mail($to, $EmailTitle, $EmailBody1, $from_header); // redirect back to url visitor came from $msg = "Mass email sent"; // header("Location: send-mass-email.php?msg=$msg"); } else { print("<HTML><BODY>Error, no comments were submitted!"); print("</BODY></HTML>"); } } $msg = "Mass email sent"; header("Location: send-mass-email.php?msg=$msg"); } else { $query5 = mysql_query("SELECT * FROM aarbookts_booking_bookings WHERE id = '$id'"); $row5 = mysql_fetch_array($query5); $customer_name = $row5['customer_name']; $EmailBody = filter_input(INPUT_POST, 'EmailBody', FILTER_SANITIZE_STRING); $to = $row5['customer_email']; $from_header = "From: [email protected]\r\n"; $from_header .= "Reply-To: ". strip_tags($to) . "\r\n"; $from_header .= "MIME-Version: 1.0\r\n"; $from_header .= "Content-Type: text/html; charset=ISO-8859-1\r\n"; $EmailBody1 = '<html><body>'; $EmailBody1 .= '<p><strong>Dear '.$customer_name.'</strong></p>'; $EmailBody1 .= '<p>'.$EmailBody.'</p>'; $EmailBody1 .= '</body></html>'; $EmailTitle = 'Subject'; if($EmailBody != "") { //send mail - $subject & $contents come from surfer input mail($to, $EmailTitle, $EmailBody1, $from_header); // redirect back to url visitor came from $msg = "Mass email sent"; header("Location: send-mass-email.php?msg=$msg"); } else { print("<HTML><BODY>Error, no comments were submitted!"); print("</BODY></HTML>"); } } mysql_close($link); ?> Please help?
  10. WOW that's brilliant! how such small piece of code can do so much?!
  11. the numbers are the values of the checkboxes
  12. Database column is ServiceDue values can be: 0|4 2|3|5 0|2|3 or whatever?! everything would be 0|1|2|3|4|5
  13. Please help, I have 6 checkboxes in an array 0|1|2|3|4|5 I need to be able to UPDATE my database based on which checkboxes are checked, if it's the last one then I don't want to add a leading '|' here is my code so far: if(sizeof($_POST['hear'])) { foreach($_POST['hear'] AS $heard){ $heard = $heard.'|'; if($heard == '5'){ $heard = $heard; } } //end foreach } //end IF $sql1 = "UPDATE aarbookts_booking_bookings SET how='$heard' WHERE id = '$id'"; $result1 = mysql_query($sql1,$link) or die('Error: ' . mysql_error() . '<br>SQL: ' . $sql1); Please help?!
  14. hi, on my site I have 6 checkboxes: Box1 = Internet Box2 = Yellow pages Box3 = Van Box4 = Letting agent Box5 = Repeat customer Box6 = Recommendation which ever is checked they go into the database as a number, for example, if all were checked I get 0|1|2|3|4|5 in my database. This all works fine but, I need to show which are checked, if my database had: 0|2|4 I need it to say: Internet, Van, Repeat Customer please help?
  15. hi, the following SQL: UPDATE `customer` SET `ServiceDate` = DATE_ADD('1900-01-01', INTERVAL 40812 DAY) updates all records in my table at the column ServiceDate with a date 40812 days after 1900-01-01 My problem is is that each of the values in the ServiceDate column are not 40812, they are all different. 40812, 40965, 40723 and so on... Please help
  16. $qry = "SELECT calendar_id, booking_total, booking_deposit, booking_tax, booking_status, payment_method, payment_option, customer_name, customer_email, customer_phone, customer_country, customer_city, customer_address, customer_zip, customer_notes, cc_type, cc_num, cc_exp, cc_code, txn_id, processed_on, created, appliance_make, appliance_model, appliance_serial, appliance_fault FROM aarbookts_booking_bookings WHERE id='$booking_id'"; $cur=mysql_query($qry); while($i=mysql_fetch_row($cur)) { $calendar_id=$i[0]; $booking_total=$i[1]; $booking_deposit=$i[2]; $booking_tax=$i[3]; $booking_status=$i[4]; $payment_method=$i[5]; $payment_option=$i[6]; $customer_name=$i[7]; $customer_email=$i[8]; $customer_phone=$i[9]; $customer_country=$i[10]; $customer_city=$i[11]; $customer_address=$i[12]; $customer_zip=substr($i[13], 0, strpos($i[13],' ')); $customer_notes=$i[14]; $cc_type=$i[15]; $cc_num=$i[16]; $cc_exp=$i[17]; $cc_code=$i[18]; $txn_id=$i[19]; $processed_on=$i[20]; $created=$i[21]; $appliance_make=$i[22]; $appliance_model=$i[23]; $appliance_serial=$i[24]; $appliance_fault=$i[25]; } echo '<h3>Booking made on: '.$created.'</h3>'; echo '<p><strong>Customer Notes:</strong> '.$customer_notes.'<br /><br /> <strong>Booking Status:</strong> '.$booking_status.'<br /><br /></p>'; output is: Booking made on: 2222207-26 23:50:54 Customer Notes: no Booking Status: pppppng and should be: Booking made on: 2011-07-26 23:50:54 Customer Notes: no Booking Status: pending
  17. Thanks for your help so far Teynon! I'm a little stuck on my action page: $booking_id = $_REQUEST['booking_id']; $booking_date = $_REQUEST['booking_date']; if(sizeof($_POST['Times'])) { //means if at least one check box is selected foreach($_POST['Times'] AS $start_time){ if($start_time == "07:00:00"){ $end_time = "10:00:00"; } else if($start_time == "10:00:00"){ $end_time = "13:00:00"; } else if($start_time == "13:00:00"){ $end_time = "16:00:00"; } else if($start_time == "16:00:00"){ $end_time = "19:00:00"; } $sql = "DELETE * FROM aarbookts_booking_bookings_slots WHERE booking_id=$booking_id"; $sql1 = "INSERT INTO aarbookts_booking_bookings_slots SET start_time='$start_time',end_time='$end_time',booking_date='$booking_date' WHERE booking_id=$booking_id"; } //end foreach } //end IF echo $sql; echo $sql1; this only shows one SQL DELETE and one SQL INSERT INTO I thought surely these should be in the for each loop and INSERT EACH checkbox?!
  18. Excellent! that's great, thanks! hmm now I have to work out how to do the next bit?! if CHECKED - INSERT INTO WHERE start_time = value of checkbox - if UNCHECKED DELETE (but there might not be a record in there anyway?!)
  19. Please help, I get the following error: <b>Notice</b>: Array to string conversion in <b>/home/sites/affordableappliancerepairs.co.uk/public_html/admin/edit-bookingdate.php</b> on line <b>14</b><br /> here is my code: $query1 = mysql_query("SELECT GROUP_CONCAT(start_time) FROM aarbookts_booking_bookings_slots WHERE booking_id = '$booking_id'"); $row1 = mysql_fetch_array($query1); $times=explode(',', $row1);
  20. ok Teynon, using the code you used previously, .. and now getting error messages as it's now turned on on the server I currently get: <b>Notice</b>: Array to string conversion in <b>/home/sites/affordableappliancerepairs.co.uk/public_html/admin/edit-bookingdate.php</b> on line <b>14</b><br /> here is my code: $query1 = mysql_query("SELECT GROUP_CONCAT(start_time) FROM aarbookts_booking_bookings_slots WHERE booking_id = '$booking_id'"); $row1 = mysql_fetch_array($query1); $times=explode(",", $row1); <input type="checkbox" name="Times" value="07:00:00" <?php if(in_array("07:00:00",$times)){ echo 'checked';} ?>> 07:00 - 10:00<br /> <input type="checkbox" name="Times" value="10:00:00" <?php if(in_array("10:00:00",$times)){ echo 'checked';} ?>> 10:00 - 13:00<br /> <input type="checkbox" name="Times" value="13:00:00" <?php if(in_array("13:00:00",$times)){ echo 'checked';} ?>> 13:00 - 16:00<br /> <input type="checkbox" name="Times" value="16:00:00" <?php if(in_array("16:00:00",$times)){ echo 'checked';} ?>> 16:00 - 19:00<br />
  21. I got back short_tags=1
  22. Just a plain blank white screen not sure what you mean by short tags enabled I have now removed the part that reads: header("Location: index.php?msg=$msg";
  23. <?php session_start(); ini_set('display_errors', 1); ini_set('log_errors', 1); ini_set('error_log', dirname(__FILE__) . '/error_log.txt'); error_reporting(E_ALL); include_once("config.php"); if (!isset($_SESSION['rsUser'])) { $msg = "Username and/or Password incorrect!"; header('Location: index.php?msg='.$msg.''); } if (!isset($_REQUEST['msg'])) { $_REQUEST['msg'] = "nothing"; } $booking_id = $_REQUEST['booking_id']; $query1="SELECT * FROM aarbookts_booking_bookings_slots WHERE booking_id = '$booking_id'"; $result = mysql_query($query1); ?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /> <title>Affordable Appliance Repairs Admin - Edit Booking Date/Time</title> <!-- CSS --> <!-- Reset Stylesheet --> <link rel="stylesheet" href="resources/css/reset.css" type="text/css" media="screen" /> <!-- Main Stylesheet --> <link rel="stylesheet" href="resources/css/style.css" type="text/css" media="screen" /> <link rel="stylesheet" href="resources/css/blue.css" type="text/css" media="screen" /> <!-- Invalid Stylesheet. This makes stuff look pretty. Remove it if you want the CSS completely valid --> <!--<link rel="stylesheet" href="resources/css/invalid.css" type="text/css" media="screen" />--> <!-- Colour Schemes Default colour scheme is green. Uncomment prefered stylesheet to use it. <link rel="stylesheet" href="resources/css/blue.css" type="text/css" media="screen" /> <link rel="stylesheet" href="resources/css/red.css" type="text/css" media="screen" /> --> <!-- Internet Explorer Fixes Stylesheet --> <!--[if lte IE 7]> <link rel="stylesheet" href="resources/css/ie.css" type="text/css" media="screen" /> <![endif]--> <!-- Javascripts --> <!-- jQuery --> <script type="text/javascript" src="http://code.jquery.com/jquery-1.5.2.min.js"></script> <!-- jQuery Configuration --> <script type="text/javascript" src="resources/scripts/simpla.jquery.configuration.js"></script> <!-- Facebox jQuery Plugin --> <script type="text/javascript" src="resources/scripts/facebox.js"></script> <!-- jQuery WYSIWYG Plugin --> <script type="text/javascript" src="resources/scripts/jquery.wysiwyg.js"></script> <!-- Internet Explorer .png-fix --> <link type="text/css" rel="stylesheet" href="http://79.170.40.235/affordableappliancerepairs.co.uk/bookings/core/libs/jquery/ui/css/smoothness/jquery.ui.core.css" /> <link type="text/css" rel="stylesheet" href="http://79.170.40.235/affordableappliancerepairs.co.uk/bookings/core/libs/jquery/ui/css/smoothness/jquery.ui.theme.css" /> <link type="text/css" rel="stylesheet" href="http://79.170.40.235/affordableappliancerepairs.co.uk/bookings/core/libs/jquery/ui/css/smoothness/jquery.ui.tabs.css" /> <link type="text/css" rel="stylesheet" href="http://79.170.40.235/affordableappliancerepairs.co.uk/bookings/index.php?controller=AdminCalendars&action=css&cid=1" /> <link type="text/css" rel="stylesheet" href="http://79.170.40.235/affordableappliancerepairs.co.uk/bookings/core/libs/jquery/ui/css/smoothness/jquery.ui.button.css" /> <link type="text/css" rel="stylesheet" href="http://79.170.40.235/affordableappliancerepairs.co.uk/bookings/core/libs/jquery/ui/css/smoothness/jquery.ui.dialog.css" /> <link type="text/css" rel="stylesheet" href="http://79.170.40.235/affordableappliancerepairs.co.uk/bookings/core/libs/jquery/ui/css/smoothness/jquery.ui.datepicker.css" /> <script type="text/javascript" src="http://79.170.40.235/affordableappliancerepairs.co.uk/bookings/core/libs/jquery/jquery-1.5.2.min.js"></script> <script type="text/javascript" src="http://79.170.40.235/affordableappliancerepairs.co.uk/bookings/app/web/js/admin-core.js"></script> <script type="text/javascript" src="http://79.170.40.235/affordableappliancerepairs.co.uk/bookings/core/libs/jquery/ui/js/jquery.ui.core.min.js"></script> <script type="text/javascript" src="http://79.170.40.235/affordableappliancerepairs.co.uk/bookings/core/libs/jquery/ui/js/jquery.ui.widget.min.js"></script> <script type="text/javascript" src="http://79.170.40.235/affordableappliancerepairs.co.uk/bookings/core/libs/jquery/ui/js/jquery.ui.tabs.min.js"></script> <script type="text/javascript" src="http://79.170.40.235/affordableappliancerepairs.co.uk/bookings/core/libs/jquery/ui/js/jquery.ui.button.min.js"></script> <script type="text/javascript" src="http://79.170.40.235/affordableappliancerepairs.co.uk/bookings/core/libs/jquery/ui/js/jquery.ui.position.min.js"></script> <script type="text/javascript" src="http://79.170.40.235/affordableappliancerepairs.co.uk/bookings/core/libs/jquery/ui/js/jquery.ui.dialog.min.js"></script> <script type="text/javascript" src="http://79.170.40.235/affordableappliancerepairs.co.uk/bookings/core/libs/jquery/ui/js/jquery.effects.core.min.js"></script> <script type="text/javascript" src="http://79.170.40.235/affordableappliancerepairs.co.uk/bookings/core/libs/jquery/ui/js/jquery.ui.datepicker.min.js"></script> <script type="text/javascript" src="http://79.170.40.235/affordableappliancerepairs.co.uk/bookings/core/libs/jquery/plugins/validate/js/jquery.validate.min.js"></script> <!--[if IE 6]> <script type="text/javascript" src="resources/scripts/DD_belatedPNG_0.0.7a.js"></script> <script type="text/javascript"> DD_belatedPNG.fix('.png_bg, img, li'); </script> <![endif]--> <script type="text/javascript"> $(document).ready(function(){ $("fieldset input[type=text]").focus(function(){ $(this).parent().find(".input-notification").css("visibility", "visible"); }).blur(function(){ $(this).parent().find(".input-notification").css("visibility", "hidden"); }); }); </script> <script> $(function() { $( "#datepicker" ).datepicker(); }); </script> </head> <body><div id="body-wrapper"> <!-- Wrapper for the radial gradient background --> <? $menuitem=4; $submenuitem=1; include("menu.php"); ?> <div id="main-content"> <!-- Main Content Section with everything --> <noscript> <!-- Show a notification if the user has disabled javascript --> <div class="notification error png_bg"> <div> Javascript is disabled or is not supported by your browser. Please <a href="http://browsehappy.com/" title="Upgrade to a better browser">upgrade</a> your browser or <a href="http://www.google.com/support/bin/answer.py?answer=23852" title="Enable Javascript in your browser">enable</a> Javascript to navigate the interface properly. </div> </div> </noscript> <!-- Page Head --> <?php include_once("welcome.php");?> <div class="clear"></div> <!-- End .clear --> <div class="content-box"><!-- Start Content Box --> <div class="content-box-header"> <h3>Bookings</h3> <ul class="content-box-tabs"> <li><a href="#tab1" class="default-tab">Edit Booking Date/Time</a></li> </ul> <div class="clear"></div> </div> <!-- End .content-box-header --> <div class="content-box-content"> <div class="tab-content default-tab" id="tab1"> <form action="edit-bookingdate-script.php?booking_id=<?php echo $row1['booking_id']; ?>" method="post"> <fieldset> <!-- Set class to "column-left" or "column-right" on fieldsets to divide the form into columns --> <p> <label>Date</label> <input class="text-input small-input" type="text" id="datepicker" name="booking_date" value="<?php echo $row5['booking_date']; ?>" /> </p> <p> <label>Booking Status</label> <?php $row1 = mysql_fetch_array($result); foreach($row1 as $row){ $chk1=""; if($row['start_time']=="07:00:00") $chk1="checked='yes'"; } $chk2=""; if($row['start_time']=="10:00:00") $chk2="checked='yes'"; } $chk3=""; if($row['start_time']=="13:00:00") $chk3="checked='yes'"; } $chk4=""; if($row['start_time']=="16:00:00") $chk4="checked='yes'"; } echo " <input type='checkbox' name='cbox[]' value='07:00:00' $chk1> 07:00 - 10:00<br /> <input type='checkbox' name='cbox[]' value='10:00:00' $chk2> 10:00 - 13:00<br /> <input type='checkbox' name='cbox[]' value='13:00:00' $chk3> 13:00 - 16:00<br /> <input type='checkbox' name='cbox[]' value='16:00:00' $chk4> 16:00 - 19:00<br /> <br /> "; } ?> </p> <p> <input class="button" type="submit" value="Edit Date/Time" /> </p> </fieldset> <div class="clear"></div><!-- End .clear --> </form> </div> <!-- End #tab2 --> </div> <!-- End .content-box-content --> </div> <!-- End .content-box --> <?php include_once("footer.php");?><!-- End #footer --> </div> <!-- End #main-content --> </div> </body> </html>
  24. Thankyou Thomas but I added ini_set('display_errors', 1); ini_set('log_errors', 1); ini_set('error_log', dirname(__FILE__) . '/error_log.txt'); error_reporting(E_ALL); to try and debug your code and my page is still blank?!
  25. I have just put my checkboxes into a loop: <?php while($row1 = mysql_fetch_array($result)) { echo '<input type="checkbox" name="cbox[]" value="07:00:00"'.if($row1['start_time']=="07:00:00"){ echo "checked";}.'> 07:00 - 10:00<br />'; echo '<input type="checkbox" name="cbox[]" value="10:00:00"'.if($row1['start_time']=="10:00:00"){ echo "checked";}.'> 10:00 - 13:00<br />'; echo '<input type="checkbox" name="cbox[]" value="13:00:00"'.if($row1['start_time']=="13:00:00"){ echo "checked";}.'> 13:00 - 16:00<br />'; echo '<input type="checkbox" name="cbox[]" value="16:00:00"'.if($row1['start_time']=="16:00:00"){ echo "checked";}.'> 16:00 - 19:00<br />'; }?> my page is now blank?!
×
×
  • 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.