Skip to content

Commit 310598f

Browse files
committed
base path fixed
1 parent 22a998d commit 310598f

File tree

4 files changed

+21
-6
lines changed

4 files changed

+21
-6
lines changed

.env.example

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ APP_NAME=Laravel
22
APP_ENV=local
33
APP_KEY=
44
APP_DEBUG=true
5-
APP_URL=http://localhost
5+
APP_URL=http://localhost/try/laravel-vue-starter/
66

77
LOG_CHANNEL=stack
88
LOG_LEVEL=debug

.htaccess

+18
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
<IfModule mod_rewrite.c>
2+
<IfModule mod_negotiation.c>
3+
Options -MultiViews
4+
</IfModule>
5+
6+
RewriteEngine On
7+
8+
RewriteCond %{REQUEST_FILENAME} -d [OR]
9+
RewriteCond %{REQUEST_FILENAME} -f
10+
RewriteRule ^ ^$1 [N]
11+
12+
RewriteCond %{REQUEST_URI} (\.\w+$) [NC]
13+
RewriteRule ^(.*)$ public/$1
14+
15+
RewriteCond %{REQUEST_FILENAME} !-d
16+
RewriteCond %{REQUEST_FILENAME} !-f
17+
RewriteRule ^ server.php
18+
</IfModule>

package-lock.json

-4
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

resources/views/default.blade.php

+2-1
Original file line numberDiff line numberDiff line change
@@ -7,11 +7,12 @@
77
<title>Laravel Vue SPA Starter Boilerplate</title>
88
<link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/css/bootstrap.min.css"
99
integrity="sha384-ggOyR0iXCbMQv3Xipma34MD+dH/1fQ784/j6cY/iJTQUOhcWr7x9JvoRxT2MZw1T" crossorigin="anonymous">
10+
<base href="{{ env('APP_URL') }}">
1011
</head>
1112

1213
<body>
1314
<div id="app"></div>
14-
<script src="{{ mix('js/app.js') }}"></script>
15+
<script src="{{ env('APP_URL') }}{{ mix('js/app.js') }}"></script>
1516

1617
<script src="https://code.jquery.com/jquery-3.3.1.slim.min.js"
1718
integrity="sha384-q8i/X+965DzO0rT7abK41JStQIAqVgRVzpbzo5smXKp4YfRvH+8abtTE1Pi6jizo" crossorigin="anonymous">

0 commit comments

Comments
 (0)