Possible stupid question about http url parsing

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Possible stupid question about http url parsing

Strom
This might be a dumb question, but is req compatible with full url paths?

For example:
val testReq: Request = (:/"http://test.com/validate/test.html")

instead of:
val testReq: Request = (:/"test.com"/"validate"/"test.html")
Reply | Threaded
Open this post in threaded view
|

Re: Possible stupid question about http url parsing

n8han
Administrator
On 10/22/2010 05:21 PM, Strom [via Databinder] wrote:
This might be a dumb question, but is req compatible with full url paths?

There is a constructor on Request for that:
http://sourced.implicit.ly/net.databinder/dispatch-http/0.7.7/dispatch/Http.scala.html#19521

Or:

import Http._ // includes an implicit conversion from String to Request
val testReq: Request = "http://test.com/validate/test.html"

Nathan


For example:
val testReq: Request = (:/"http://test.com/validate/test.html")

instead of:
val testReq: Request = (:/"test.com"/"validate"/"test.html")


View message @ http://databinder.3617998.n2.nabble.com/Possible-stupid-question-about-http-url-parsing-tp5664175p5664175.html
To start a new topic under Databinder, email [hidden email]
To unsubscribe from Databinder, click here.