Hi there,
I have a single drupal site on shared hosting. I had been updating the site manually via FTP but was running into php error problems when updating due to non-core modules. I have been advised to use composer to update the site. However the article about installing composer on an existing site states that you should modify the composer.json file that is at the root of your git repository, not core/composer.json. https://www.drupal.org/node/2718229#managing-existing-site
I don't use git because I am on shared hosting and was simply using Filezilla to upload to the server.
What am I best doing here?
Thanks
Comments
There isn't any problem with
There isn't any problem with installing composer directly in the docroot of your one Drupal site.
Once you install composer, then use composer to manage all your core and module installations and updates.
With composer installed add modules by using "composer require drupal/{module}"
Then enable the module on the admin/extend page.
Always run {site}/update.php after running "composer update".
Here is an example composer.json for use in the docroot of your D8 site, along with some essential contrib modules no site should be without:
spritefully yours
Technical assistance provided to the Drupal community on my own time ...
Thank yous appreciated ...
If you have cPanel - you can
If you have cPanel - you can easily repeat your FTP process using File Manager without resorting to composer (file manager seems to be a lot more stable than the FTP process). But it may be smart to jump into Composer and learn it.