{"action":"created","issue":{"url":"https://api.github.com/repos/julienschmidt/httprouter/issues/76","labels_url":"https://api.github.com/repos/julienschmidt/httprouter/issues/76/labels{/name}","comments_url":"https://api.github.com/repos/julienschmidt/httprouter/issues/76/comments","events_url":"https://api.github.com/repos/julienschmidt/httprouter/issues/76/events","html_url":"https://github.com/julienschmidt/httprouter/issues/76","id":66682727,"number":76,"title":" Go CORS handler as a middleware in HttpRouter","user":{"login":"johnidm","id":2614909,"avatar_url":"https://avatars.githubusercontent.com/u/2614909?v=3","gravatar_id":"","url":"https://api.github.com/users/johnidm","html_url":"https://github.com/johnidm","followers_url":"https://api.github.com/users/johnidm/followers","following_url":"https://api.github.com/users/johnidm/following{/other_user}","gists_url":"https://api.github.com/users/johnidm/gists{/gist_id}","starred_url":"https://api.github.com/users/johnidm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/johnidm/subscriptions","organizations_url":"https://api.github.com/users/johnidm/orgs","repos_url":"https://api.github.com/users/johnidm/repos","events_url":"https://api.github.com/users/johnidm/events{/privacy}","received_events_url":"https://api.github.com/users/johnidm/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/julienschmidt/httprouter/labels/question","name":"question","color":"cc317c"}],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":5,"created_at":"2015-04-06T19:15:02Z","updated_at":"2015-12-14T18:45:12Z","closed_at":"2015-04-09T08:20:20Z","body":"Hey \r\n\r\nI need to use [Go CORS handler](https://github.com/rs/cors) with httprouter, but both use the same parameter in the `http.ListenAndServe` function .\r\n\r\nSee:\r\n\r\nGo CORS handler\r\n```\r\nhandler := cors.Default().Handler(h)\r\nhttp.ListenAndServe(\":8080\", handler)\r\n```\r\nHttpRouter\r\n```\r\nrouter := httprouter.New()\r\nrouter.GET(\"/\", Index)\r\nhttp.ListenAndServe(\":8080\", router)\r\n```\r\n\r\nCan be used Go CORS handler as a middleware in HttpRouter?\r\n\r\nThanks"},"comment":{"url":"https://api.github.com/repos/julienschmidt/httprouter/issues/comments/164522552","html_url":"https://github.com/julienschmidt/httprouter/issues/76#issuecomment-164522552","issue_url":"https://api.github.com/repos/julienschmidt/httprouter/issues/76","id":164522552,"user":{"login":"rs","id":68232,"avatar_url":"https://avatars.githubusercontent.com/u/68232?v=3","gravatar_id":"","url":"https://api.github.com/users/rs","html_url":"https://github.com/rs","followers_url":"https://api.github.com/users/rs/followers","following_url":"https://api.github.com/users/rs/following{/other_user}","gists_url":"https://api.github.com/users/rs/gists{/gist_id}","starred_url":"https://api.github.com/users/rs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rs/subscriptions","organizations_url":"https://api.github.com/users/rs/orgs","repos_url":"https://api.github.com/users/rs/repos","events_url":"https://api.github.com/users/rs/events{/privacy}","received_events_url":"https://api.github.com/users/rs/received_events","type":"User","site_admin":false},"created_at":"2015-12-14T18:45:12Z","updated_at":"2015-12-14T18:45:12Z","body":"`cors` lib author here. Please tell us what is not working. If you don't see the CORS headers using curl, make sure you send the `Origin` header within your request."}}