Jump to content

Notification


DarkPrince2005

Recommended Posts

  • 2 months later...

how can i retrieve a date from a table and set it to $date1's value and the curdate() to date2's value, cause everything I'm trying isn't working

 

 

<?php
ini_set('display_errors','On');
error_reporting(E_ALL);

mysql_connect("localhost","root","");

  mysql_select_db("database");
$r=mysql_query("select [i]field[/i] from [i]table[/i] where Employee_Firstname like 'KS'");  
$date2 ="$r";
$date1 = "curdate()";

echo (strtotime($date1) - strtotime($date2))/(60*60*24) ." Days";
?>

Link to comment
https://forums.phpfreaks.com/topic/68975-notification/#findComment-389741
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • 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.