Skip to content

Commit e61f4d8

Browse files
committed
上传后自动跳转
1 parent 3856b59 commit e61f4d8

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

app.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ app.post('/upload', multer().single('pic_file'), function (req, res) {
7676
if (err) {
7777
return res.send(err)
7878
}
79-
res.send(response.body)
79+
res.redirect('/showlist')
8080
})
8181
})
8282
})

view/header.ejs

+1-1
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
<span class="icon-bar"></span>
2020
<span class="icon-bar"></span>
2121
</button>
22-
<a class="navbar-brand" href="#">Project 9</a>
22+
<a class="navbar-brand" href="/">Project 9</a>
2323
</div>
2424
<div id="navbar" class="navbar-collapse collapse">
2525
<ul class="nav navbar-nav">

0 commit comments

Comments
 (0)