Using Composer locally then uploading files through FTP

前端 未结 2 515
Happy的楠姐
Happy的楠姐 2021-02-06 09:05

Bit of a strange set up but have come across a project where Composer has been used in a local environment to get a project started. The original developer did not have ssh acce

2条回答
  •  别那么骄傲
    2021-02-06 09:16

    You could copy the composer.json from the server to your local server, add the requirements and run composer update.

    After that you can copy all files (composer.json, composer.lock and vendor folder to your server)...


    Or you can copy local vendor/phpmailer into servers vendor folder, search for the entry of phpmailer in vendor/composer/autoload_psr4.php and add it to your servers vendor/composer/autoload_psr4.php.

    Using this method also add phpmailers dependencies the same way.

    composer depends phpmailer/phpmailer
    

提交回复
热议问题