source:
binary-improvements/MapRendering/Web/SimpleRedirectHandler.cs@
235
| Last change on this file since 235 was 230, checked in by , 11 years ago | |
|---|---|
| File size: 399 bytes | |
| Rev | Line | |
|---|---|---|
| [230] | 1 | using System; |
| 2 | using System.Net; | |
| 3 | ||
| 4 | namespace AllocsFixes.NetConnections.Servers.Web | |
| 5 | { | |
| 6 | public class SimpleRedirectHandler : PathHandler | |
| 7 | { | |
| 8 | string target; | |
| 9 | ||
| 10 | public SimpleRedirectHandler (string target) | |
| 11 | { | |
| 12 | this.target = target; | |
| 13 | } | |
| 14 | ||
| 15 | public override void HandleRequest (HttpListenerRequest req, HttpListenerResponse resp, HttpListenerBasicIdentity user) | |
| 16 | { | |
| 17 | resp.Redirect (target); | |
| 18 | } | |
| 19 | } | |
| 20 | } | |
| 21 |
Note:
See TracBrowser
for help on using the repository browser.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)