Thanks! 在 2014年8月27日星期三UTC+8上午11时16分54秒,Jesse Gumm写道: > > The easy way is to put your uploaded files into a directory in > /priv/static then any requests to > http://yoursite.com/static/some/path/your_new_file.bin > > Otherwise, if your files are small, you could just have a controller > return {output, FileContents, Headers}, where FileContents could be > the result of file:read_file/1 > ( > http://erldocs.com/17.0/kernel/file.html?i=0&search=file:read_file#read_file/1) > > > > Ooootherwise, if your files are large, you can write a generator > function and return a streaming with with {stream, GeneratorFun, Acc} > (see http://chicagoboss.org/api-controller.html) > > Hope that helps, > > -Jesse > > On Tue, Aug 26, 2014 at 9:56 PM, Caiyun Deng <[email protected] > <javascript:>> wrote: > > Hi! > > I know how to upload file in ChicagoBoss. > > But how to download file in ChicagoBoss? I want to show the file button > in > > the page, and click the file then it will download the file. > > Thanks! > > > > -- > > You received this message because you are subscribed to the Google > Groups > > "ChicagoBoss" group. > > To unsubscribe from this group and stop receiving emails from it, send > an > > email to [email protected] <javascript:>. > > Visit this group at http://groups.google.com/group/chicagoboss. > > To view this discussion on the web visit > > > https://groups.google.com/d/msgid/chicagoboss/658e5727-2a37-4e1a-8e31-e05e6c13b5b3%40googlegroups.com. > > > > For more options, visit https://groups.google.com/d/optout. > > > > -- > Jesse Gumm > Owner, Sigma Star Systems > 414.940.4866 || sigma-star.com || @jessegumm >
-- You received this message because you are subscribed to the Google Groups "ChicagoBoss" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. Visit this group at http://groups.google.com/group/chicagoboss. To view this discussion on the web visit https://groups.google.com/d/msgid/chicagoboss/d62139f0-4e43-4b7b-a144-3aebe93719ad%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
