cancel
Showing results for 
Search instead for 
Did you mean: 

Admin panel missing CSS and JS

Admin panel missing CSS and JS

I've been implementing a new theme in Magento. When I wasn't seeing the changes show up, I followed advice to clear out /pub/static/ and use /bin/magento setup:static-content:deploy to rebuild the static content.

 

After doing so, I've lost the CSS the JS in the admin panel. Checking the path for the CSS and JS files, I'm seeing; /pub/static/adminhtml/Magento/backend/en_GB/ however Magento has only created a folder for en_US. How do I get it to create static content for the correct locale/s?

Tags (1)
2 REPLIES

Re: Admin panel missing CSS and JS

Hello scorpio

I have gone through the same problem. I have done same as you delete pub/static content but after re-deploying I didn't get the solutions. Again I installed fresh Magento. After some time again I face this issue but this time, I used the best approach. Hope this will work for you :

Use the following command from your magento root directory

  1. sudo rm -rf var/di/* var/generation/* var/cache/* var/page_cache/* var/view_preprocessed/* var/composer_home/cache/*

  2. sudo chmod 777 var -R

  3. sudo chmod 777 pub -R

  4. sudo php bin/magento setup:static-content:deploy

  5. Repeat step 2 & 3.

 

Re: Admin panel missing CSS and JS

For your language you have to do:

php bin/magento setup:static-content:deploy en_GB