composer-php

PHP Startup: Unable to load dynamic library 'php_mongodb.dll'

旧巷老猫 提交于 2021-02-05 12:21:09
问题 I'm trying to get Laravel MongoDB working in my local machine (Windows 10 home, x64) by following this tutorial I have installed XAMPP 7.3.11 on D:\xampp succesfully and tested that the server can be reached (enter localhost:80 on browser) I proceeded on extracting php_mongodb.dll I got from pecl(mongodb 1.6.0 for Windows, 7.3 Non Thread Safe, x64 ) on D:\xampp\php\ext and add the line extension=php_mongodb.dll on the file D:\xampp\php\php.ini After selecting 'the command-line PHP you want to

How to add case insensitive autoloading using composer generated classmap?

99封情书 提交于 2021-02-04 17:55:28
问题 I have legacy project which has declartions and class usings in different cases. I want upgrade source to modern state. First I want to replace legacy autoloading by composer autoloading. But composer does not provide case insensitive autoloading. How to use composer classmap and insensitive autoload? 回答1: Add classmap to composer.json . "autoload": { "classmap": ["folder1/", "folder2/"] }, Then run composer.phar dumpautoload to create composer/autoload_classmap.php . Change your code. After

Require shopware 6 plugin via composer

痞子三分冷 提交于 2021-01-29 07:08:38
问题 I am developing a custom plugin for Shopware 6. It will not be sitting in Shopware Store but our own company repo on github. How can I make it get installed into custom/plugins instead of vendor when I run composer require plugin/name ? I tried setting up in plugin's composer "type": "shopware-plugin" and "type": "shopware-platform-plugin" but it still puts it into vendor . There is this: https://getcomposer.org/doc/faqs/how-do-i-install-a-package-to-a-custom-path-for-my-framework.md - I

Laravel: how to access a file in the local disk? - File does not exist

被刻印的时光 ゝ 提交于 2021-01-29 04:32:59
问题 I'm trying to edit an excel file after uploading it in laravel. the file is uploaded to local disk, so no one can access it from the public. Filesystems.php 'local' => [ 'driver' => 'local', 'root' => storage_path('app') Routes.php Route::get('test',function() { // Create new PHPExcel object $objPHPExcel = new PHPExcel(); $objPHPExcel = PHPExcel_IOFactory::load(Storage::disk('local')->url('margin/analyser/0IGkQQgmGXkHrV9ISnBTrGyZFUPfjz3cWJbLGbDN.xlsx')); $objPHPExcel->setActiveSheetIndex(0);

What's the recommended approach for updating the core lib of a Cakephp3 app

戏子无情 提交于 2021-01-28 04:42:43
问题 I've used composer to install CakePHP 3 while it still was in development, so the composer.json file contains dev-versions. The composer.json file looks like this right now: { "name": "cakephp/app", "description": "CakePHP skeleton app", "homepage": "http://cakephp.org", "type": "project", "license": "MIT", "require": { "php": ">=5.4.16", "cakephp/cakephp": "3.0.*-dev", "mobiledetect/mobiledetectlib": "2.*", "cakephp/migrations": "dev-master", "cakephp/plugin-installer": "*" }, "require-dev":

Problems when The composer downloading mpdf

别说谁变了你拦得住时间么 提交于 2021-01-28 04:23:33
问题 C:\xampp\htdocs\presensi\vendor>composer require mpdf/mpdf Using version ^8.0 for mpdf/mpdf ./composer.json has been updated Running composer update mpdf/mpdf Loading composer repositories with package information Updating dependencies Nothing to modify in lock file Installing dependencies from lock file (including require-dev) Package operations: 1 install, 0 updates, 0 removals - Downloading mpdf/mpdf (v8.0.10) - Downloading mpdf/mpdf (v8.0.10) - Downloading mpdf/mpdf (v8.0.10) -

How to create a PSR-4 autoloader for my project?

假如想象 提交于 2021-01-28 03:06:17
问题 I am creating a PHP project and want to implement PSR-4 autoloading. I don't know which files I need to create in the vendor directory to implement autoloading for class files. 回答1: If you are using composer , you do not create the autoloader but let composer do its job and create it for you. The only thing you need to do is create the appropriate configuration on composer.json and execute composer dump-autoload . E.g.: { "autoload": { "psr-4": {"App\\": "src/"} } } By doing the above, if you

Composer install with dockerfile

拈花ヽ惹草 提交于 2021-01-27 17:07:44
问题 I'm pretty new with docker, I try to automatically execute composer install within my Dockerfile but it seems that I can't cd into my application while installing, what's wrong? Or maybe there is another better way to do that? my docker-compose.yml version: "3.1" services: app: image: nginx:alpine container_name: app working_dir: /application volumes: - ./Projects/app:/application/app - ./Docker/nginx/app.conf:/etc/nginx/conf.d/app.conf ports: - "8080:8080" php-fpm-app: build: Docker/php-fpm

Composer - The requested package issue on vcs

戏子无情 提交于 2021-01-27 14:55:50
问题 I forked https://github.com/calebporzio/onboard to https://github.com/mpjraaij/onboard/tree/dev-bugfix My composer file up updated to { "name": "laravel/laravel", "description": "The Laravel Framework.", "keywords": ["framework", "laravel"], "license": "MIT", "type": "project", "repositories": [ { ... }, { "type": "vcs", "url": "https://github.com/mpjraaij/onboard" } ], "require": { ... "calebporzio/onboard": "dev-bugfix", ... }, "require-dev": { ... }, "autoload": { "classmap": [ "database

Composer - The requested package issue on vcs

旧街凉风 提交于 2021-01-27 14:34:42
问题 I forked https://github.com/calebporzio/onboard to https://github.com/mpjraaij/onboard/tree/dev-bugfix My composer file up updated to { "name": "laravel/laravel", "description": "The Laravel Framework.", "keywords": ["framework", "laravel"], "license": "MIT", "type": "project", "repositories": [ { ... }, { "type": "vcs", "url": "https://github.com/mpjraaij/onboard" } ], "require": { ... "calebporzio/onboard": "dev-bugfix", ... }, "require-dev": { ... }, "autoload": { "classmap": [ "database