Just installed Magento 2 on a shared server, everything seemed successful, no errors, but the shop looks like this (css files not found, they return 403 Forbidden, but the files are actually missing):
It seems like the static content/css is not generated.
The only file in pub/static/frontend/Magento/luma/locale is requirejs-config.js, but there were supposed to also be other files, such as those CSS files:
I tried reinstalling it, changing folder permissions, different PHP version, nothing worked. It’s strange that some folders are generated (also the requirejs file), but not the CSS.
How can I make sure the CSS is generated (without shell access) ?
Why would Magento clearly say installation was successful if it couldn’t generate the static files? Can I somehow manually copy those static files?
Specs:
- PHP Version 7.1
- Magento CE 2.3.0
- Installed on a shared server, only have cPanel access, no shell
2
Answers
Try the following command and cache:flush.
php bin/magento setup:static-content:deploy -f
it’s a very strange issue appears only in 2.3 version.
You should insert this SQL code in your project database ( or in PHPMyAdmin ui):
insert core_config_data (config_id, scope, scope_id, path, value) values (null, ‘default’, 0, ‘dev/static/sign’, 0);