| @@ -2,10 +2,10 @@ | |||
| <html lang="en"> | |||
| <head> | |||
| <meta charset="utf-8"> | |||
| <title>Hello!</title> | |||
| <title>Index!</title> | |||
| </head> | |||
| <body> | |||
| <h1>Hello!</h1> | |||
| <p>Hi from Rust</p> | |||
| <p>This is the index page. It's different from the hello page.</p> | |||
| </body> | |||
| </html> | |||
| @@ -40,7 +40,7 @@ fn handle_connection(mut stream: TcpStream) { | |||
| match caps { | |||
| Some(cap) => { | |||
| let c = cap.get(1).unwrap().as_str(); | |||
| println!("Asked to fetch {}", c); | |||
| // println!("Asked to fetch {}", c); | |||
| //assert!(Path::new(c).exists()); | |||
| if c == "" { | |||
| ("HTTP/1.1 200 OK\r\n\r\n", "index.html") | |||