cancel
Showing results for 
Search instead for 
Did you mean: 

Pass a file for download from Share dashlet

zladuric
Champ on-the-rise
Champ on-the-rise
Hello,
I am trying to make a new share dashlet and I'm kind of stuck here.
What I have is a php script (not within alfresco) on the local server generating a txt or html file. The script is only accessible through localhost.
Now, I have the dashlet with two buttons: html and txt. What I want those buttons to do is:
1. to call this php script and fetch the appropriate file and
2. have that file offered as a new window (for html) or download (for txt).

Can you guys give me some pointers? The dashlets are ready and the php thing is ready - I am just kind of stuck with how to actually do a call.
I can do sometihng javascriptish onClick, but this would call the php from the client (and php is localhost-restricted).
I could also try something like call a share/proxy/alfresco/somewebscript, but this would add more complexity to the situation. In that case I'd have to make the "somewebscript" fetch the localhost php script output, pass it through back to /share and then to client, right?

Can you guys give me few hints/pointers?

Thanks a lot in advance!
2 REPLIES 2

flefoll
Champ in-the-making
Champ in-the-making
Hi,

I advise you to handle upload using webdav or ftp interface,

you can not play aspects within such type of import,
but it's great incredibly easier than webservices or whatever to implement in few minutes…

Regards,

Francois

zladuric
Champ on-the-rise
Champ on-the-rise
It is not an upload or anything.

The new dashlet has only the button "Get report". It gets a report xml file from outside alfresco. Now, I handled it with webscript, but I'd still like a better way to do this.