I'm using the following code to display the name of a CSV file before the contents of the CSV file are displayed on a PHP page. It works well and displays the name of the file as it should:
CODE:
#$result .= '<h3>'.$prog.'</h3>'.PHP_EOL; // OLD STYLE
$result .= '<h3>'.$prog. ' '.$_POST['filename'].'</h3>'.PHP_EOL; // NEW STYLE
$result .= '</div>'.PHP_EOL;
$result .= $contents.PHP_EOL;
Problem is, I don't want the file name to display the extension (in my code example, it is .csv)
Can anyone assist in the right code needed to remove the extension (.CSV)...?