New filtering in MouseHole
Kevin Ballard
kevin at sb.org
Sun Sep 4 15:41:32 EDT 2005
That won't work if you have a fairly generic script. What if I mutate
all sites to throw a link in the upper-right that, say, pops open a
box with input fields to let me post a note to my Backpack pages from
any site? That would require handling // for domain and %r{/
backpack_ping/} for path. That can't be done as a single string
register, and doing it as a regex register_url is no "better" than my
approach. Although I would like to make req.request_uri be proper and
drop the uri arg to the block - I didn't in my patch because
request_uri is read-only and I didn't really feel like extending the
class to get access to it, but it's probably appropriate here.
On Sep 4, 2005, at 2:59 PM, why the lucky stiff wrote:
> Great, thankyou for the patch. This is lovely. Do you mind if I
> mix this with the register_url idea?
>
> For a foreign URL:
>
> register_url( "http://google.com/test.js" ) do |req, res| # no
> `uri' arg needed, we'll do magic to make the req.request_uri work
> fine.
> end
>
> For accessing MouseHole directly:
>
> register_url( "/wiki" ) do |req, res| end
>
> We could normalize the ports and subdomains from inside MouseHole.
--
Kevin Ballard
kevin at sb.org
http://www.tildesoft.com
http://kevin.sb.org
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 2378 bytes
Desc: not available
Url : http://rubyforge.org/pipermail/mousehole-scripters/attachments/20050904/c640e045/smime.bin
More information about the Mousehole-scripters
mailing list