Hi Richard

There are two ways of doing it...

1. after you have applied encodeURIComponent() replace '%' by '$00' (ensure
that the converted number is 4 digit)
2. Use ?name=value instead of '/' and use request.getParameter() or
@RequestParameter

regards
Taha


On Tue, Jan 4, 2011 at 11:26 PM, Richard Hill <r...@su3analytics.com> wrote:

>
> Ah, apologies - I thought the threading was based on the subject line.
>
> R.
>
>
>
> On Tue, 2011-01-04 at 15:52 -0200, Thiago H. de Paula Figueiredo wrote:
> > Hi!
> >
> > Please post new discussions as new messages instead of replying to
> > existing ones. Every threaded visualization of the mailing list will show
> > your message in the wrong place. ;)
> >
> > On Tue, 04 Jan 2011 15:24:28 -0200, Richard Hill <r...@su3analytics.com>
> > wrote:
> >
> >
> > > Happy New Year All,
> > >
> > > I'm attempting to pass an url in an ajax request to an onEvent handler.
> > > So I'm making a request like:
> > >
> > > GET /MyPage.MyComponent:event/http://blah.com/....
> > >
> > > MyComponent.java:
> > >
> > > public StreamResponse onEvent(String url) {
> > >     ....
> > > }
> > >
> > >
> > > The problem is that what's being passed to onEvent() is just "http:"
> > >
> > > Now I realise that "/" is the context delimiter. However I've tried
> > > encoding the url with escape(url), encodeURI(url), and
> > > encodeURIComponent(url) (the latter 2 encode the "/") but to no avail -
> > > same issue.
> > >
> > > I also realise that Tapestry employs it's own encoding scheme - do I
> > > have to encode in this way? If so, does anyone have some code to
> > > implement Tapestry url encoding in javascript?
> > >
> > > Many thanks,
> > >
> > > Richard.
> > >
> > >
> > >
> > >
> > >
> > >
> > > ---------------------------------------------------------------------
> > > To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
> > > For additional commands, e-mail: users-h...@tapestry.apache.org
> > >
> >
> >
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
> For additional commands, e-mail: users-h...@tapestry.apache.org
>
>

Reply via email to