Problems displaying date in appropriate format [duplicate]

0

I have this date:

<?php echo date("d/M/Y", strtotime($registro['DATA_VENCIMENTO'])); ?>

is displaying like this: 15/Oct/2019

How do I display in Portuguese, without losing the formatting that I put (d / M / Y)?

I want to display this way: 15/10/2019

    
asked by anonymous 26.06.2018 / 20:12

1 answer

1

According to the documentation , the M formatting is a textual representation > short of the name of the month (three letters); the m format is the numeric representation of the month, with zero the left.

Then just change M to m :

echo date("d/m/Y", strtotime($registro['DATA_VENCIMENTO']));
    
26.06.2018 / 20:30