forward account info (path)

Upload core product.
Post Reply
import
Posts: 169
Joined: Sun Jan 27, 2008 8:10 pm

forward account info (path)

Post by import »

I'm evaluating this product so I can create a service for my users so they can upload a big file to it, and then give them an URL that they can mail to a contact on the internet.
Of course, I do not want people to be able to get each others files. So I upload the file into a directory with a random name (something like /20071030ERZREDYFYDFTDGFCHGF/).
I found an article on how to use a variable directory to upload the file into, but I can't find a method to return the resulting URL to the user, as the forward method only returns the filename.
I also do not want to use the POST method, as afaik this passes data to a server based applet.
If possible, I rather keep it as a client based application, as all the rest already is really client based, isn't it ?
So is there a way to forward also the account (path) info using the forward method ?


import
Posts: 169
Joined: Sun Jan 27, 2008 8:10 pm

Re: forward account info (path)

Post by import »

The URL that I want to return to the user ?
Should be like:
"http://server.com/20071030ERZREDYFYDFTD ... d_file.zip"
Ofcourse the "http://server.com" is a static value, so that can be prefixed later on.

import
Posts: 169
Joined: Sun Jan 27, 2008 8:10 pm

Re: forward account info (path)

Post by import »

Do you know the path before upload ? If so then with you could build the forward parameter dynamically with PHP before displaying the applet such as:
<PARAM NAME="forward" VALUE="http://server.com/<? echo $path ?>/">.
However, "forward" will append ?filename=uploaded_file.zip and not uploaded_file.zip. What about if you upload many files ?

import
Posts: 169
Joined: Sun Jan 27, 2008 8:10 pm

Re: forward account info (path)

Post by import »

doh... don't know how I could have missed that one, since it is the same trick to get this variable into the account parameter

I wonder why you want to use PHP here though... js supports vars by itself...
something like:
VALUE="http://host.intranet.com/result.htm?path=' + mypath + '">
In the result.htm I will get both variables and use them to display the download URL for the user.

I do not want to use it for multiple files... they should only upload one zip file, and then get the URL they have to put in their mail.

Post Reply