download helper and directory helper question NOW with an additional URI question!

I am building a file management system using code igniter and I was wondering if I could use the download and directory helper that CI so thoughtfully provides..

My problem is that the files the system uploads are going to be stored outside of the root folder (www aka public_html) -

Since the download helper path/to/file is relative to the big of a problem is this? Can I just use a few "../../" to go that far back "behind" the www/public_html folders?

Also, can directory helper be used the same way?

My alternative is to use the apache mod_xsendfile to send the correct headers.

Well I answered one of my questions:

download helper works with files outside of the www/public_html root.

this is good!

now to test the directory helper...

looks like directory helper works also. sweet.

Now for my next challenge:

I want to be able to have users follow a link in an email that goes to a function that will let them download a file that outside of the root.

This means using headers (force download - the download helping class).

However, I cannot pass GET parameters to CI, so how could I accomplish this? The URL in the email needs to be able to specific which folder and which user it belongs to (basically, it needs to transfer two pieces of information).

Can I still use the URI in some way??

edit: reading the manual ftw. yay.

Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  

  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2020 MyBB Group.