【问题标题】:unisharp laravel file manager without php artisan serve没有 php artisan serve 的 unisharp laravel 文件管理器
【发布时间】:2017-06-25 16:09:01
【问题描述】:

没有 php artisan serve 我不会启动我的 laravel 5.2 应用程序

当 index.php 在公用文件夹中时,它可以正常工作 IMAGE From Public Folder

当 index.php 在根文件夹中时,它会停止工作 Image From Root Folder

【问题讨论】:

标签: laravel file-manager


【解决方案1】:

要包含你的 css、js 和资产,你必须使用 laravel 的asset()。

例如,您的文件位于 public/asset/css/custom.css 中

<link href="{!! asset('asset/css/custom.css') !!}" type="text/css" rel="stylesheet" />

在服务器中将公用文件夹从 public 替换为 public_html 时也可以使用。

【讨论】:

  • 我使用资产,但在我看来没有包含脚本这个问题只在文件管理器中。脚本包含在插件源中我不会更改插件脚本s23.postimg.org/t5o3ymrfv/code.jpg
  • 运行应用程序时的端口号是什么。通常要运行 Laravel,你必须进入根文件夹并运行命令“php artisan serve --port=8000”你这样做?
  • 上升是因为 Laravel 框架使用 public/index.php 作为第一个执行文件。然后你从 root 执行它。
猜你喜欢
  • 1970-01-01
  • 2015-04-03
  • 2018-02-22
  • 1970-01-01
  • 2017-01-13
  • 2020-11-26
  • 2021-12-18
  • 1970-01-01
  • 1970-01-01
相关资源
最近更新 更多