You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jetspeed-user@portals.apache.org by Jaron van Golverdinge Schut <J....@kennisnet.nl> on 2008/08/22 13:00:39 UTC
Ajax and filedownloading support in jetspeed-2
Hello,
We are currently looking for a way to enable ajax requests and file
downloads with jetspeed-2 inside the security context of jetspeed. We
have looked at the different pipelines and got some things to work but
it is very hacky. Several things remain unclear to allow us to implement
a clean solution.
First question is how to build an url to a different pipeline?
Standard ways of building an url with <portlet:someURL /> or
RenderResponse.createSomeURL() do not allow one to specify a different
base url. From a portlet page that was requested as
www.host.com/jetspeed/portal/blablabla using standard url utilities
results in a www.host.com/jetspeed/portal/blablabla url while I would
wish to have a www.host.com/jetspeed/fileserver/blablabla url. Is this
possible?
The current hack in use is a manually created url like
www.host.com/jetspeed/fileserver/export?portlet=portletwar::portletname&
blablabla
This will call the correct portlet. The problem is that the
PortletRequest object has no parameters set. Neither is there a way to
specify that the processAction() should be called instead of the
render() method.
Any help is appreciated,
JWA van Golverdinge Schut
DISCLAIMER:
Dit bericht (met bijlagen) is zorgvuldig samengesteld. Voor eventuele onjuistheid en/of onvolledigheid van de hierin verstrekte informatie aanvaardt Kennisnet geen aansprakelijkheid. Aan de inhoud van dit bericht (met bijlagen) kunnen geen rechten worden ontleend. De inhoud van dit bericht (met bijlagen) kan vertrouwelijke informatie bevatten en is uitsluitend bestemd voor de geadresseerde van dit bericht.
Re: Ajax and filedownloading support in jetspeed-2
Posted by David Sean Taylor <da...@bluesunrise.com>.
On Aug 22, 2008, at 4:00 AM, Jaron van Golverdinge Schut wrote:
> We are currently looking for a way to enable ajax requests and file
> downloads with jetspeed-2 inside the security context of jetspeed. We
> have looked at the different pipelines and got some things to work but
> it is very hacky. Several things remain unclear to allow us to
> implement
> a clean solution.
> First question is how to build an url to a different pipeline?
>
Jetspeed has two pipelines that may be of use:
1. Ajax Pipeline
2. File Server Pipeline
see:
http://portals.apache.org/jetspeed-2/guides/guide-ajax-api.html
If you install the demo, you can see an example of the file server
pipeline at:
http://localhost:8080/jetspeed/fileserver/_content/sample_pdf.pdf
>
>
> Standard ways of building an url with <portlet:someURL /> or
> RenderResponse.createSomeURL() do not allow one to specify a different
> base url. From a portlet page that was requested as
> www.host.com/jetspeed/portal/blablabla using standard url utilities
> results in a www.host.com/jetspeed/portal/blablabla url while I would
> wish to have a www.host.com/jetspeed/fileserver/blablabla url. Is this
> possible?
>
Yes, see the Jetspeed Desktop, we do both render and action requests
using two pipelines:
DesktopPipeline
see pipelines.xml for all available valves and pipelines configured by
Spring
DesktopActionPipeline
Granted this will take some javascript code on your part to implement
your own Desktop functionality
>
>
> The current hack in use is a manually created url like
> www.host.com/jetspeed/fileserver/export?portlet=portletwar::portletname&
> blablabla
>
> This will call the correct portlet. The problem is that the
> PortletRequest object has no parameters set. Neither is there a way to
> specify that the processAction() should be called instead of the
> render() method.
>
The file server pipeline is a render pipeline, its not meant for
actions, its meant for "serving files"
To get the portlet request to set parameters from the servlet request,
turn on the non-standard option in your override.properties:
merge.portal.parameters.with.portlet.parameters=true
---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-user-unsubscribe@portals.apache.org
For additional commands, e-mail: jetspeed-user-help@portals.apache.org