Activity log for bug #506087

Date Who What changed Old value New value Message
2010-01-11 19:51:38 Fırat Küçük bug added bug
2010-01-11 19:52:22 Fırat Küçük description Hi, response.setHeader() method behaves like put method of Hashtable class. But there can be smart mechanism for some specific HTTP headers. For instance: "Content-Type" makes duplicate record: Test-Case: Controller: --------------------------------------------------------- public static void helloText() { try { response.setHeader("Content-Type", "text/html; charset=utf-8"); response.out.write("<b>hello</b>".getBytes()); } catch (Exception e) { } } Request: --------------------------------------------------------- GET /Application/helloText HTTP/1.1 Host: localhost:9000 Connection: close Response: --------------------------------------------------------- HTTP/1.1 200 OK Cache-Control: no-cache Connection: close Content-Length: 12 Content-Type: text/html; charset=utf-8 Content-Type: text/html Date: Mon, 11 Jan 2010 19:36:39 GMT Server: Play! Framework;dev Set-Cookie: PLAY_ERRORS=; Path=/ Set-Cookie: PLAY_FLASH=; Path=/ Set-Cookie: PLAY_SESSION=067234602de391c9b44852504c609fe78bc5ffbe-%00___ID%3A51dbcbef-cbae-4001-a639-e76f1d6e68df%00; Path=/ known malfunction: Apache mod_proxy deletes the second Content-Type header. So we can see the files as plain text. Hi, response.setHeader() method behaves like put method of Hashtable class. But there can be smart mechanism for some specific HTTP headers. For instance: "Content-Type" makes duplicate record: Test-Case: Controller: ---------------------------------------------------------   public static void helloText() {     try {       response.setHeader("Content-Type", "text/html; charset=utf-8");       response.out.write("<b>hello</b>".getBytes());     } catch (Exception e) {     }   } Request: --------------------------------------------------------- GET /Application/helloText HTTP/1.1 Host: localhost:9000 Connection: close Response: --------------------------------------------------------- HTTP/1.1 200 OK Cache-Control: no-cache Connection: close Content-Length: 12 Content-Type: text/plain; charset=utf-8 Content-Type: text/html; charset=utf-8 Date: Mon, 11 Jan 2010 19:36:39 GMT Server: Play! Framework;dev Set-Cookie: PLAY_ERRORS=; Path=/ Set-Cookie: PLAY_FLASH=; Path=/ Set-Cookie: PLAY_SESSION=067234602de391c9b44852504c609fe78bc5ffbe-%00___ID%3A51dbcbef-cbae-4001-a639-e76f1d6e68df%00; Path=/ known malfunction: Apache mod_proxy deletes the second Content-Type header. So we can see the files as plain text.
2010-01-13 20:38:43 Nicolas Leroux play: assignee Nicolas (nicolas-lunatech)
2010-01-13 20:38:55 Nicolas Leroux play: milestone 1.0.1
2010-01-13 20:39:16 Nicolas Leroux nominated for series play/1.0
2010-01-13 20:39:16 Nicolas Leroux bug task added play/1.0
2010-01-13 20:39:16 Nicolas Leroux nominated for series play/1.1
2010-01-13 20:39:16 Nicolas Leroux bug task added play/1.1
2010-01-13 20:39:29 Nicolas Leroux play/1.1: milestone 1.1
2010-01-13 21:11:26 Nicolas Leroux play/1.0: status New In Progress
2010-01-13 21:11:29 Nicolas Leroux play/1.1: assignee Nicolas (nicolas-lunatech)
2010-01-13 21:11:32 Nicolas Leroux play/1.1: status New In Progress
2010-01-13 21:13:26 Nicolas Leroux play/1.0: status In Progress Fix Committed
2010-01-13 21:15:05 Nicolas Leroux play/1.1: status In Progress Fix Committed
2010-01-21 21:29:19 Guillaume Bort play/1.0: status Fix Committed Fix Released