2

I'm facing the same problem as MagentoProblem this link. It is about messy frontend and backend of Magento 2. This happened after i set https://(My_Domain_Name).com into Configuration > Web > Base URLs & Base URLs (Secure) > Base URL for Static View Files & Secure Base URL for Static View Files.

I think the solution in the link will work for me but I don't have enough understanding on how to run the command CLI in Magento 2.3.1. I saw something about 'SSH', 'Terminal', 'Putty', but still not quite understand how to use them. Do i need to install any software or need to download anything else in order for me to run command CLI in Magento? I'm using GoDaddy Hosting > C-Panel > Magento 2.3.1 on Window 10.

Shoaib Munir
  • 9,404
  • 10
  • 49
  • 106

1 Answers1

1

First you need to enable SSH, then you could be able to connect with putty

  1. Log in to your GoDaddy account.
  2. Click Web Hosting.
  3. Next to the cPanel account you want to use, click Manage.
  4. In the Settings section, next to SSH Access, click manage.
  5. Click Enable.

Reference: https://pk.godaddy.com/help/enable-ssh-16102

After enable SSH you now follow these

  1. Download, install and launch the SSH client.
  2. Enter the following information:
    Host, Port, Username, Password
  3. After entering the necessary information in the SSH client, you will be able to establish a connection to your hosting account.

Reference: https://pk.godaddy.com/help/connect-to-my-cpanel-hosting-account-with-ssh-secure-shell-31865

After you have access to shell, execute following commands

php -dmemory_limit=1G bin/magento setup:upgrade
php -dmemory_limit=1G bin/magento setup:di:compile
php -dmemory_limit=1G bin/magento setup:static-content:deploy -f
php bin/magento cache:clean

Note: It is better to give this task to a developer first, after first successful execution of commands by developer, you can learn how to run commands on Magento, then you can follow him and do it by yourself.

Shoaib Munir
  • 9,404
  • 10
  • 49
  • 106
  • Thank you for your guidance. I will try it on my own first and see how it goes. If i encounter any problems, can i further clarify it with you? – Nicholas Chow May 07 '19 at 06:06
  • Yes sure, will try my best – Shoaib Munir May 07 '19 at 06:06
  • Mr. Shoaib, I'm able to execute command after following your steps. However after I execute 1) bin/magento setup:upgrade, 2) bin/magento setup:static-content:deploy, 3) bin/magento indexer:reindex, my problem with messy frontend and backend still exist. I think my problem is caused after i set https://(My_Domain_Name).com into Configuration > Web > Base URLs & Base URLs (Secure) > Base URL for Static View Files & Secure Base URL for Static View Files. But now I can't change it back because in the admin page, the safe config button does not work. Any help is much appreciated. – Nicholas Chow May 08 '19 at 02:22
  • I have edited my answer, please execute commands that I have shared and let me know if you still facing issue – Shoaib Munir May 08 '19 at 04:06
  • First Command output: cache cleared successfully, file system cleanup, ..., Nothing to import. Second Command output: Generated code and dependency injection configuration successfully. Third Command Output: Execution time: 209.123. Fourth Command Output: Cleaned cache types. After I refresh my website, the messy frontend and backend still exist. – Nicholas Chow May 08 '19 at 04:38
  • can you share your domain? – Shoaib Munir May 08 '19 at 04:44
  • www.aevuswebs.com. I'm not sure why it took longer than usual to load – Nicholas Chow May 08 '19 at 04:44
  • There is no problem with commands, I have checked in console. css/js is not loading and showing error in console https://www.screencast.com/t/vgJsKeUk – Shoaib Munir May 08 '19 at 04:53
  • This is going off the topic, you need to add another question, add screenshot there, may be I would be able to help you out. you can share your question link here – Shoaib Munir May 08 '19 at 04:53
  • I have added another question regarding my problem in the link provided, please take a look at it. https://magento.stackexchange.com/questions/273763/magento-2-css-js-error-in-frontend-and-backend. Thank you so much for your time – Nicholas Chow May 08 '19 at 06:24