magento / magento2

Prior to making any Submission(s), you must sign an Adobe Contributor License Agreement, available here at: https://opensource.adobe.com/cla.html. All Submissions you make to Adobe Inc. and its affiliates, assigns and subsidiaries (collectively “Adobe”) are subject to the terms of the Adobe Contributor License Agreement.
http://www.magento.com
Open Software License 3.0
11.55k stars 9.32k forks source link

Disappeared css from back and frontend #10949

Closed enrybisco closed 7 years ago

enrybisco commented 7 years ago

Preconditions

  1. php 7
  2. Magento 2

Steps to reproduce

  1. In the main folder public_html and in commented out #followsymlink
  2. In the folder pub/media in the htaccess file: deleted "All" from 1st line: " Options All-Indexes"
  3. and commented out the line: # Options +SymLinksIfOwnerMatch 4.From SSH in Putty I have run: php bin/magento clean and indexer:index

Expected result

  1. Images of created products .png format should be visible

Actual result

  1. [Screenshot, logs] No images(no hyperlink working) + no css both in the backend and frontend
orlangur commented 7 years ago

Will images and css work if you restore original .htaccess?

enrybisco commented 7 years ago

No I have tryed to restore the file in the folder pub/media in the htaccess file: readded "All" in1st line: " Options All-Indexes" and taken off the comment from the line: # Options +SymLinksIfOwnerMatch but nope it's not working

orlangur commented 7 years ago

Try to restore original .htaccess files by copying or git reset instead of editing and re-run all relevant command, like static content deploy, reindexing etc after that.

enrybisco commented 7 years ago

I have run the magento setup:static-content:deploy [] because the language of the website (all folders it_IT were gone): the situation now is that the backend is working but not the css in the frontend

enrybisco commented 7 years ago

... deploy it_IT

orlangur commented 7 years ago

Try switching to en_US as it_IT does not belong to this repo anyway.

What did you try to achieve by changing .htaccess by the way?

For the sake of clean bug report, please do a clean Magento 2 installation and perform necessary steps in order to reproduce a bug, then please put an updated version of steps into description.

enrybisco commented 7 years ago

The changes in the .htaccess are needed due to a configuration compatibility with our Apache server: in the previous Magento 1.9x .png files were not visible if this action was not performed.

Thank you Enrico

magento-engcom-team commented 7 years ago

@enrybisco, thank you for your report. We were not able to reproduce this issue by following the steps you provided. If you'd like to update it, please reopen the issue.