</td> <td width="90" align="center" valign="top" class="brdr_1"><input type="button" onclick="delete_product(<?php echo $product_id; ?>,<?php echo $user_id; ?>);" /></td> </tr> <?php $i++; } } else { ?> <tr align="center" bgcolor="#fff6f0"> <td colspan="6" class="brdr_1">No Products Found</td> </tr> <?php } ?> <tr bgcolor="#ffeee1"> <!-- Comment Start --> <?php $comment = OrderCommentShopp($user_id); ?> <td align="left" colspan="2" align="right" valign="top" class="brdr_3 pad_none"> <table width="260" border="5" cellspacing="0" cellpadding="0" class="first"> <tr> <td>Add a comment to your order</td> </tr> <?php $ctn = ($_SESSION['cus_count'] != '') ? $_SESSION['cus_count'] : '140'; ?> <tr> <td> <form name="myform"> <textarea name="cus_commt_txt" id="cus_commt_txt" class="cus_commt_txt" style="width: 96%;padding: 5px;height: 35px;" onKeyDown="limitText(this.form.cus_commt_txt,this.form.countdown,140);" onKeyUp="limitText(this.form.cus_commt_txt,this.form.countdown,140);" onblur="return save_cmmt('<?php echo $user_id; ?>');"><?php echo $comment[0]['comment']; ?></textarea> <input readonly type="text" name="countdown" size="5" id="countdown" value="<?php echo $ctn; ?>" style="width: 35px;" /> </form>
$object = mysql_fetch_assoc($val_account); $help_val = $object['help'] == '1' ? '0' : '1'; $sql = "UPDATE sohorepro_email\n\t\t\tSET help = '" . $help_val . "' WHERE id = '" . $help_notification_id . "' "; $res = mysql_query($sql); if ($res) { echo '1'; } else { echo '0'; } } if (isset($_POST['cus_commt']) && !empty($_POST['cus_commt'])) { $cus_commt = mysql_real_escape_string($_POST['cus_commt']); $cus_commt_id = $_POST['cus_commt_id']; $_SESSION['cus_count'] = $_POST['cus_count']; $ip = md5($_SERVER['HTTP_USER_AGENT'] . $_SERVER['REMOTE_ADDR']); $exist_comment = OrderCommentShopp($cus_commt_id, $ip); if ($exist_comment < 1) { $query = "INSERT INTO sohorepro_cust_commt\n\t\t\tSET cus_id = '" . $cus_commt_id . "',\n ip = '" . $ip . "',\n comment = '" . $cus_commt . "',\n status = '1' "; } else { $query = "UPDATE sohorepro_cust_commt\n\t\t\tSET comment = '" . $cus_commt . "', \n status = '1' WHERE \n cus_id = '" . $cus_commt_id . "' AND ip = '" . $ip . "' "; } $res = mysql_query($query); if ($res) { echo '1'; } else { echo '0'; } } if (isset($_POST['datepicker1']) && $_POST['datepicker1'] != '') { $_SESSION['datepicker1'] = $_POST['datepicker1']; }