When I open any website here on my Ubuntu 17.10 PC, they suddenly just give garbage, as though something has broken but I am not sure what. I thought that perhaps PHP wasn't running but when I open
http://127.0.0.1/ in the browser, it's showing the same thing rather than showing Apache2's Welcome page. This is a relatively fresh installation that was working perfectly until yesterday when sites started timing out, then the current problems. I'm running Apache2 version 2.4.27 and PHP version 7.1.11.
The "garbage" appears to be bits and pieces of code rather than the page's full code:
$CaptionText" : ""; if (ImageExt($ImageName) != "pdf") : $PageImage .= $ImageCaption; $PageImage .= " "; elseif ($Category == 6) : $PageImage .= " $CaptionText "; else: $LinkTitle = explode(".", $CaptionText); $TitleText = $LinkTitle; $CaptionText = str_replace("$TitleText.", "", $CaptionText); $PageImage .= " $TitleText $CaptionText "; endif; endforeach; $PageText .= $PageImage; endif; include $_SERVER ['DOCUMENT_ROOT'] . "/internals/includes/pageheader.php";?>