我是laravel的新手(刚刚安装了laravel!)。
我搜索了许多网站并测试了我发现的任何解决方案,但它们都不适合我。我在我的localhost中安装了laravel(例如:localhost / laravel);
我有一个laravel网站来源,其中包含文件&下面的文件夹: floders: -admin -资产 -组件 -dist -src 文件: - .htaccess - 404.php - 等等... - package.json - package-lock.json - 和其他php文件
在某些解决方案中,他们说我必须运行两个简单的代码: 作曲家安装 php artisan:迁移
但是当我的源代码中没有任何作曲家文件时,我不知道在哪里以及如何做到这一点。我测试了package.json install,但它显示了我的错误。
我需要有关这个项目的帮助。它不在laravel目录中只是www文件夹中的另一个目录(localhost / test)。 如何将此源导入laravel并运行它?
更新1
在Laravel Docs中搜索后,我找到了这行代码:
composer require laravel/homestead --dev
但是当我在项目目录中运行它时,我看到了这个错误:
[InvalidArgumentException]
Could not find a matching version of package laravel/triplee. Check the package spelling, your version constraint and that the package is available in a stability which matches your minimum-stability (stable).
require [--dev] [--prefer-source] [--prefer-dist] [--no-progress] [--no-suggest] [--no-update] [--no-scripts] [--update-no-dev] [--update-with-dependencies] [--update-with-all-dependencies] [--ignore-platform-reqs] [--prefer-stable] [--prefer-lowest] [--sort-packages] [-o|--optimize-autoloader] [-a|--classmap-authoritative] [--apcu-autoloader] [--] [<packages>]...
答案 0 :(得分:0)
由于您是laravel的新手,我建议您使用vagrant。你可以找到很多关于用流浪汉安装laravel的视频:
https://www.youtube.com/results?search_query=laravel+vagrant
除了使用舒适之外,它还具有很大的优势。