<?php $string = "11092018"; $formatada = substr_replace(substr_replace($string,'-',4,0),'-',2,0); echo $formatada;
Standard input is empty
11-09-2018
The brand new service which powers Ideone!
Widget for compiling and running the source code in a web browser!