I guess you&#39;re the first to try that. As for your next OPTION, you&#39;ll have to do a bit of experimenting. Sorry :)<br><br><div class="gmail_quote">On 28 December 2012 19:23, Rik Brown <span dir="ltr">&lt;<a href="mailto:rik@rikbrown.co.uk" target="_blank">rik@rikbrown.co.uk</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
                <div>Thanks for the swift response.</div><div><br></div><div>
                    Wonder why they don&#39;t allow that.  Simply (quickly hacking) the HTTP::Server::Simple code to add |OPTIONS to the regex deciding if the request would be accepted fixed the problem.</div><div>Can I override the default web server used by Dancer in development (i.e. to a subclass of it)?  It&#39;s a bit annoying that the default web server for Dancer doesn&#39;t support one of its route types! </div>

                <div><div><br></div><div>-- </div><div>Rik Brown</div><div><a href="http://www.rikbrown.co.uk" target="_blank">http://www.rikbrown.co.uk</a></div><div><br></div></div>
                 
                <p style="color:#a0a0a8">On Friday, 28 December 2012 at 19:08, Alex C wrote:</p>
                <blockquote type="cite" style="border-left-style:solid;border-width:1px;margin-left:0px;padding-left:10px">
                    <span><div><div>That response is coming from HTTP::Server::Simple, Dancer&#39;s built-in development web server, which does not appear to support the OPTIONS request method.<div><br></div><div><a href="http://search.cpan.org/~jesse/HTTP-Server-Simple-0.44/lib/HTTP/Server/Simple.pm#valid_http_method%28$method%29" target="_blank">http://search.cpan.org/~jesse/HTTP-Server-Simple-0.44/lib/HTTP/Server/Simple.pm#valid_http_method%28$method%29</a><br>

<div><br><div>On 28 December 2012 18:56, Rik Brown <span dir="ltr">&lt;<a href="mailto:rik@rikbrown.co.uk" target="_blank">rik@rikbrown.co.uk</a>&gt;</span> wrote:<br><blockquote type="cite"><div>

                <div>
                    Hi all,
                </div><div><br></div><div>I&#39;m playing with implementing an OPTIONS route.  </div><div><br></div><div>The following code:</div><div><br></div><div>options &#39;/&#39; =&gt; sub {</div><div>  return { something =&gt; 1 }</div>

<div>}</div><div><br></div><div>returns this:</div><div><div>&lt;html&gt;</div><div>    &lt;head&gt;</div><div>        &lt;title&gt;Bad Request&lt;/title&gt;</div><div>    &lt;/head&gt;</div><div>    &lt;body&gt;</div><div>

        &lt;h1&gt;Bad Request&lt;/h1&gt;</div><div>        &lt;p&gt;Your browser sent a request which this web server could not</div><div>      grok.&lt;/p&gt;</div><div>    &lt;/body&gt;</div><div>&lt;/html&gt;</div><div>

<br></div><div>- whereas if the Dancer code is switched to &#39;get&#39; and a GET is used, it works fine.  </div><div><br></div><div>This request doesn&#39;t even seem to be hitting my Dancer app (just running through <a href="http://myapp.pl" target="_blank">myapp.pl</a> right now) - no entries in the log, even on &#39;core&#39; level.</div>

<div><br></div><div>Does anyone have any thoughts before I dig further?</div><div><br></div><div>Cheers,</div><div>Rik</div></div><span><font color="#888888">
                <div><div><br></div><div>-- </div><div>Rik Brown</div><div><a href="http://www.rikbrown.co.uk" target="_blank">http://www.rikbrown.co.uk</a></div><div><br></div></div>
            </font></span><br>_______________________________________________<br>
dancer-users mailing list<br>
<a href="mailto:dancer-users@dancer.pm" target="_blank">dancer-users@dancer.pm</a><br>
<a href="http://lists.preshweb.co.uk/mailman/listinfo/dancer-users" target="_blank">http://lists.preshweb.co.uk/mailman/listinfo/dancer-users</a><br>
<br></div></blockquote></div><br></div></div>
</div><div><div>_______________________________________________</div><div>dancer-users mailing list</div><div><a href="mailto:dancer-users@dancer.pm" target="_blank">dancer-users@dancer.pm</a></div><div><a href="http://lists.preshweb.co.uk/mailman/listinfo/dancer-users" target="_blank">http://lists.preshweb.co.uk/mailman/listinfo/dancer-users</a></div>
</div></div></span>
                 
                 
                 
                 
                </blockquote>
                 
                <div>
                    <br>
                </div>
            <br>_______________________________________________<br>
dancer-users mailing list<br>
<a href="mailto:dancer-users@dancer.pm">dancer-users@dancer.pm</a><br>
<a href="http://lists.preshweb.co.uk/mailman/listinfo/dancer-users" target="_blank">http://lists.preshweb.co.uk/mailman/listinfo/dancer-users</a><br>
<br></blockquote></div><br>