• Member Avatar
    ehpratah

    Replied To a Post in How to get count of two values from a single table

    Hi you can use a condition statement inside your query that check whether your row contain the data that you wanna count.. SELECT COUNT(DISTINCT CASE WHEN approved = '0' THEN …
  • Member Avatar
    ehpratah

    Marked Solved Status for date range and time range

    Hi i have this query that search data between two date range `select RA, Name, Model, Plate, Service, Grand_total, Payment_type from advance WHERE SDate BETWEEN '" . $from . "' …
  • Member Avatar
    ehpratah

    Began Watching how to compare two date after 19-jan-2038

    dear friends m using strtotime () function to compare two dates , but it is not working for the date greater then '19-jan-2038'.my os is win 7 32 bit and …
  • Member Avatar
    ehpratah

    Replied To a Post in how to compare two date after 19-jan-2038

    your script pls?
  • Member Avatar
    ehpratah

    Replied To a Post in Changing Pass in PHP MySQL

    Can you post the connection.php? also change $_POST['password'] to $_POST['n_password'] as password is not define from `if(isset($_POST['old_password']) && isset($_POST['password']) && isset($_POST['new_password']))` to `if(isset($_POST['old_password']) && isset($_POST['n_password']) && isset($_POST['new_password']))`
  • Member Avatar
    ehpratah

    Began Watching Changing Pass in PHP MySQL

    I have my php page, in which i have 3 fields old pass, new pass, confirm new pass. I'm trying to chnge the password of my id from which i …
  • Member Avatar
    ehpratah

    Replied To a Post in Changing Pass in PHP MySQL

    try removing **".** sign on line 97 like this and retry $change_pass = "UPDATE users SET user_pass = '$new_pass' WHERE user_name = '$_SESSION[user_name]'";
  • Member Avatar
    ehpratah

    Began Watching Mysql update not working unless I press F5

    Hi Everyone, get a really strange problem I have been trying to fix for a few days now and I am unable to get it working. I have the following …
  • Member Avatar
    ehpratah

    Replied To a Post in Mysql update not working unless I press F5

    An Ajax reload would be great
  • Member Avatar
    ehpratah

    Began Watching How would I use two actions?

    How would I use two actions? <form id="myForm" action="form.php","form1.php" method="GET"> Does this work? Now I have 2 actions. how to connect 2 pages using php? plz guide me
  • Member Avatar
    ehpratah

    Replied To a Post in How would I use two actions?

    hi a simple solution to that is when the user click submit direct the user to your form.php and after the process in form.php is completed redirect the data from …
  • Member Avatar
    ehpratah

    Began Watching create sql table at register

    I'm wanting to create an sql table, when a user registers at my site. This table will eventually be used to log messages. The code follows: <?php require('../connect/kidsblogsconnect.php'); $name=trim(mysql_real_escape_string($_POST['name'])); mysql_query("CREATE …
  • Member Avatar
    ehpratah

    Replied To a Post in create sql table at register

    Hi Try something like this $mysql_hostname="localhost"; $mysql_database=""; $mysql_user=""; $mysql_password=""; $con = mysqli_connect($mysql_hostname,$mysql_user, $mysql_password, $mysql_database); $name=trim(mysql_real_escape_string($_POST['name'])); $sql=("CREATE TABLE IF NOT EXISTS `$name` ( `sender` varchar(30), `message` varchar(300), `dateposted` date )"); if …
  • Member Avatar
    ehpratah

    Marked Solved Status for Sum and other SQL QUERY concern

    Hi all I need some advice making my query work properly. I already played around it a dozen of times and still can't get it work. So as my last …
  • Member Avatar
    ehpratah

    Replied To a Post in Sum and other SQL QUERY concern

    Got It.. I use IF statement inside the query like this SELECT SDate, SUM(IF(Payment_type = 'Cash', Grand_total, 0)) AS 'Cash', SUM(IF(Payment_type = 'Credit', Grand_total, 0)) AS 'Credit Card', SUM(IF(Payment_type = …
  • Member Avatar
    ehpratah

    Replied To a Post in Sum and other SQL QUERY concern

    Hi Do you mean ("select SDate, Payment_type, SUM( Grand_total ) AS 'total_daily' from info WHERE SDate BETWEEN '2014-05-18' AND '2014-05-19' GROUP BY `SDate`, Payment_type") Still not getting it. How can …
  • Member Avatar
    ehpratah

    Edited Sum and other SQL QUERY concern

    Hi all I need some advice making my query work properly. I already played around it a dozen of times and still can't get it work. So as my last …
  • Member Avatar
    ehpratah

    Created Sum and other SQL QUERY concern

    Hi all I need some advice making my query work properly. I already played around it a dozen of times and still can't get it work. So as my last …
  • Member Avatar
    ehpratah

    Began Watching Sum and other SQL QUERY concern

    Hi all I need some advice making my query work properly. I already played around it a dozen of times and still can't get it work. So as my last …
  • Member Avatar
    ehpratah

    Replied To a Post in Redirect to thankyou page

    On line 46 change `header('Location: http://www.google.com/');` to echo'<script>window.location.href="https://www.google.com.ph"; </script>';
  • Member Avatar
    ehpratah

    Marked Solved Status for Connect to online DB from localhost

    Good day everyone Not sure if this is the right place to ask this but im trying to connect to my database online "Control Panel of my hosting site" from …
  • Member Avatar
    ehpratah

    Replied To a Post in Connect to online DB from localhost

    unfortunately remote mysql is not available on my Cpanel. i just ask my provider to whitelist and allow my ip so i can connect to mysql data.
  • Member Avatar
    ehpratah

    Created Connect to online DB from localhost

    Good day everyone Not sure if this is the right place to ask this but im trying to connect to my database online "Control Panel of my hosting site" from …
  • Member Avatar
    ehpratah

    Began Watching Connect to online DB from localhost

    Good day everyone Not sure if this is the right place to ask this but im trying to connect to my database online "Control Panel of my hosting site" from …
  • Member Avatar
    ehpratah

    Began Watching Redirect to thankyou page

    Hi, I am trying to get a form to redirect to a thank you page but after several attempts I am still no closer to achieving this. Below is the …
  • Member Avatar
    ehpratah

    Replied To a Post in Redirect to thankyou page

    Hi have you tried using js for redirection? just for debugging purpose try window.location.href="thankyou.php"; see if its working
  • Member Avatar
    ehpratah

    Replied To a Post in how to find number of days ago between two date in php

    Hi Sorry about that its just that i am using it here in philippines and have no problem when it comes to leaf year or daylight. anyway base on the …
  • Member Avatar
    ehpratah

    Began Watching how to find number of days ago between two date in php

    how to find number of days(days ago)different between today and database date .. eg: difference between 04/09/2014 and 06/08/2014 =(no of days ago)
  • Member Avatar
    ehpratah

    Replied To a Post in how to find number of days ago between two date in php

    You can try $endDate='2014-04-11'; $startdate='2014-04-01'; $daydiff = floor( ( strtotime( $endDate ) - strtotime( $startdate ) ) / 86400); echo $daydiff; it will count the day difference between the 2 …
  • Member Avatar
    ehpratah

    Began Watching How to load a div on click checkboxs

    i may select one or more category.... <?php include('db.php'); $sql = mysqli_query("select * from brandname where category = 'cloths' "); while($row = mysqli_fetch_array($sql)){ echo $row['brandname']; } ?> <form action="checkbox.php" method="post"> …

The End.