I have a date in string "20150617" that means 17 June 2015
How I can convert the String into "17-JUN-2015" using PHP Code.
Use below code
<?php echo date('d-M-Y', strtotime('20150617')); ?>
date strtotime
Use like this :
<?php echo date('d-M-Y',strtotime(20150617)) ?>