Directory Version
---------------------------------------------------------------------- -------
/home/clone/public_html 5
Directory Version
---------------------------------------------------------------------- -------
/home/commerce/public_html 5.6
Directory Version
---------------------------------------------------------------------- -------
/home/dev/public_html 5.6
Directory Version
---------------------------------------------------------------------- -------
/home/gogs/public_html 5
Directory Version
---------------------------------------------------------------------- -------
/home/practice/public_html 5.6
Directory Version
---------------------------------------------------------------------- -------
/home/sofresh/public_html 5
You could grep -v the Directory line and the ---- line, if you wanted to be able to script with it (or use the --multiline flag, which doesn’t include the formatting, but does have a more complex output, including the full PHP version and the execution mode) but if you’re just scanning a list to see if an old version is being used, it doesn’t have to be pretty.
That’s great @joe really good example. I also found a crude but fast way to do this, which is just to check which version is currently mapped to handle the plain ‘.php’ extension: