Re: django output pdf problem

2014-04-24 Thread Andre Terra
Relevant Stack Overflow question/answer: http://stackoverflow.com/a/9970672/447485 In short, you can't do it over simple Ajax, but you can emulate it. Cheers, AT On Thu, Apr 24, 2014 at 8:56 AM, Tom Evans wrote: > On Thu, Apr 24, 2014 at 4:31 AM, 张永强

Re: django output pdf problem

2014-04-24 Thread Tom Evans
On Thu, Apr 24, 2014 at 4:31 AM, 张永强 wrote: > > In my program, I want to generate a pdf and output to the browser. > > the server end code is: > > response = HttpResponse(content_type='application/pdf') > response['Content-Disposition'] = 'attachment; filename="' +

django output pdf problem

2014-04-24 Thread 张永强
In my program, I want to generate a pdf and output to the browser. the server end code is: response = HttpResponse(content_type='application/pdf') response['Content-Disposition'] = 'attachment; filename="' + orderNumber + '.pdf"' response.write(pdf) return response In the code, the type of pdf