During the table echo how would I replace all digits using regex?
I wish to use regex to replace all digits with a span holding the digits so I can change their class.
I can’t add the spans during the echo because the table is pulled from a text file and echo’d on screen, it would have to replace the digits already pulled in from the text file.
PHP:
//set file
$filename='schedule.txt';
//open
$handler=fopen('schedule.txt','r');
//read through file
$file=fread($handler,filesize($filename));
$lines=explode("\r\n",$file);
etc....
You could do something like: