<?php $string = "11092018"; $formatada = substr($string,0,2).'-'.substr($string,2,2).'-'.substr($string,4,4); 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!