MAGENTO ADMIN BLANK SCREEN & LOGO ISSUE AFTER INSTALLATION
Created by Bhavesh Gohil & Vicky Parekh on Date: 06/11/2020
After Installation of Magento 2 completed, your admin screen doesn't display properly & instead shows blank page.
Below are the steps to resolve this problem.
STEP 1 :
protected function isPathInDirectories($path, $directories)
{
if (!is_array($directories)) {
$directories = (array)$directories;
}
$realPath = $this->fileDriver->getRealPath($path);
foreach ($directories as $directory) {
if (0 === strpos($realPath, $directory)) {
return true;
}
}
return false;
}
Replace the above code with the following code:
protected function isPathInDirectories($path, $directories)
{
$realPath = str_replace('\\', '/', $this->fileDriver->getRealPath($path));
if (!is_array($directories)) {
$directories = (array)$directories;
}
foreach ($directories as $directory) {
if (0 === strpos($realPath, $directory)) {
return true;
}
}
return false;
}
Now reload the admin page in the browser to see if the problem is resolve.
After that you seen that your blank screen issue was resolved, but still the logo on admin & main website pages didn't display as seen in the image.
To resolve his problem follow the below steps:
STEP 2 : Go to xampp/htdocs/magento2/app/etc/di.xml and open di.xml file.
- Search Symlink inside the di.xml file
