Jump to content

Convert Date Time Issue


phpbeginner

Recommended Posts

Having trouble formatting date and time with this as there are 2 different statements......

 

 if($res['Retailerspecialtype'] == 1)
     {
     $expires = $res['Expires'];
     }
      if($res['Retailerspecialtype'] == 2)
     { 
     $expires = CURRENT_DATE.' '.$res['Retailercycleendtime']; 
                
     }

 

and then;

 

Expires:  '.$expires.'

 

I tried using

$expires = date("F j, Y, g:i a"); 

 

but the output is the actual date rather than '.$res['Retailercycleendtime'];

 

Any help would be greatly appreciated.

 

Link to comment
https://forums.phpfreaks.com/topic/194813-convert-date-time-issue/
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.