Re: Link to download a file

2017-09-07 Thread Andréas Kühne
nt-Disposition'] = 'attachment; filename=dati.csv' > return resp > it works! > > > Il giorno giovedì 31 agosto 2017 17:58:27 UTC+2, giuseppe ricci ha scritto: > >> Hi guys, I need some help to insert a link to download a file. In a view >> I read data from

Re: Link to download a file

2017-09-07 Thread giuseppe ricci
-download') resp['Content-Disposition'] = 'attachment; filename=dati.csv' return resp it works! Il giorno giovedì 31 agosto 2017 17:58:27 UTC+2, giuseppe ricci ha scritto: > > Hi guys, I need some help to insert a link to download a file. In a view I > read data from a csv file and I

Re: Link to download a file

2017-09-06 Thread James Schneider
On Wed, Sep 6, 2017 at 6:03 AM, giuseppe ricci wrote: > Thank you James for your reply.. > So in my urls.py I insert a new entry: > > url(r'^download/$', 'views.download') > > and my view to download a file is: > > def download(request): > file_path = 'static/tmp/'

Re: Link to download a file

2017-09-06 Thread giuseppe ricci
insert a link to download a file. In a view I > read data from a csv file and I show them in a table in a template. Under > the table I need to insert, when there are data, > a link similar as Download data and when user click it, he download the > datafile, previously I wrote the

Re: Link to download a file

2017-09-01 Thread James Schneider
On Aug 31, 2017 8:57 AM, "giuseppe ricci" <peppepega...@gmail.com> wrote: Hi guys, I need some help to insert a link to download a file. In a view I read data from a csv file and I show them in a table in a template. Under the table I need to insert, when there are data

Link to download a file

2017-08-31 Thread giuseppe ricci
Hi guys, I need some help to insert a link to download a file. In a view I read data from a csv file and I show them in a table in a template. Under the table I need to insert, when there are data, a link similar as Download data and when user click it, he download the datafile, previously I