私は新しいlaravelerです。今はlaravelに関する問題を扱っています。私は/
を怒り人index.html
に直接送ります。他はララベルコントローラにルーティングします。しかし、\
が順調です。他の人はviews
ディレクトリに間違って作業します。
\app\Http\route.php
が好きでは次のとおりです。laravelルートが正しく表示されずに表示される
Route::get('/',function(){
return File::get(public_path().('/views/index.html'));
});
Route::get('scan', "[email protected]");
Route::get('check', "[email protected]");
Route::get('login', "[email protected]");
directyのようなもので、次のとおりです。私はhttp://hostname/scanにアクセスするとき
├── app │ ├── Http │ │ ├── route.php //route file │ ├── Library │ ├── Providers │ ├── Services │ ├── User.php │ └── views
│ │ ├── Index.php // php index file , the entry for nginx server │ └── .......... ├── bootstrap │ ├── app.php │ ├── autoload.php │ └── cache ├── config │ ├── app.php │ └── view.php │ └── .......... ├── public │ ├── bower_components │ ├── css │ ├── data │ ├── index.bak │ ├── index.html //angular index file │ └── scripts │ └── ..........
は、今では404が見つからない、来ます。
などのログは、次のとおり、クライアント: `` ` * 2221年オープン() "/サービス/アンギュラlaravel /アプリ/ビュー/スキャンは、"(そのようなファイルやディレクトリはありません2):失敗XXXX、サーバー:ホスト名、要求: "GET /スキャンHTTP/1.1"、ホスト: "banliyun.com:8081"
`` `
私はどのようにルート仕事で少し混乱があったように。誰かが/ laravelのインデックスページを配置する場所/ディレクトリにルーティングする理由を教えてもらえますか?