-
Notifications
You must be signed in to change notification settings - Fork 8
Open
Labels
Description
func Webserver(){
let server = Server()
server.get("/hello/{id}") { request in
request.headers = ["Server":"aichy","4":"12"]
print(request.queryParams["state"]!)
return .ok(request.routeParams["id"]!)
// return
}
server.get("/"){
request in
request.headers = ["Server":"ios","test":"headers"]
return .ok("hello world! ")
}
do{
try server.run(port:2121)
}
catch{
}
// go to http://localhost:8080/hello/1?state=active in the browser
}request.headers = ["Server":"ios","test":"headers"] Don't work~~thanks