5

Not my first time to install Magento 2, but something strange this time. I have checked file permission, cleaned cache, deployed again. Files are created in pub/static in expected directories but checking browser console I see there is "version###" subdirectory in path. How this is happening?

enter image description here

  • Stores>Configuration>Advanced>Developer>Sign Static Files – Khoa TruongDinh Feb 28 '17 at 13:13
  • @KhoaTruongDinh, I can't do that, as theme is not loading properly, save config button does not work – Zinat Feb 28 '17 at 13:18
  • @KhoaTruongDinh, can it be done directly in db? if yes do you know what table? – Zinat Feb 28 '17 at 13:21
  • insert into core_config_data (config_id, scope, scope_id, path, value) values (null, 'default', 0, 'dev/static/sign', 0); – Khoa TruongDinh Feb 28 '17 at 13:23
  • @KhoaTruongDinh, tnx, it worked, pls create solution – Zinat Feb 28 '17 at 13:26
14

We can disable it in Admin:

Stores > Configuration > Advanced > Developer > Sign Static Files

Or we can change directly the value in core_config_data:

insert into core_config_data (config_id, scope, scope_id, path, value) values (null, 'default', 0, 'dev/static/sign', 0); 
| improve this answer | |
  • Very Helpful! Thank you! – MazeStricks May 30 '19 at 15:48
1

Run the following commands and you will see static version number in the static URLs (CSS, JS etc.)

bin/magento config:set dev/static/sign 1

bin/magento cache:clean

bin/magento cache:flush

Hope it helps :)

| improve this answer | |
0

1)Run SQL query on DB (to disable Sign Static Files)

insert into core_config_data (config_id, scope, scope_id, path, value) values (null, 'default', 0, 'dev/static/sign', 0); 

2)After That clean and Flush Magento Cache

bin/magento cache:clean
bin/magento cache:flush

And Refresh the page

| improve this answer | |
  • 1
    UPDATE core_config_data SET value = '0' WHERE core_config_data.path = 'dev/static/sign'; – Pradeep Thakur Sep 16 '19 at 11:33

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.