Hi Jean,

Jean-Baptiste BRIAUD -- Novlog wrote:
> 
> I make my backend to answer to an URL like http://blablabla/export.txt  
> but I can't find a way to avoid the most of the time desired AJAX  
> behavior.
> For that time only, I want the request to behave like a simple hyper  
> link and to allow end user to download a txt file.
> 
> Any idea ?
> 

Yes, but I guess you are mixing things up a bit.

This is more a server configuration thing than a client-side implementation
idea. Please take a look at the "Content-Disposition" HTTP header [1] for
more information. You can also find lots of documentation depending on your
server back-end (for example, for PHP [2]). I guess you'll want to do
something as:

  Content-Disposition: attachment; filename="filename.ext";

Regarding using this in qooxdoo, a tightly related thread [3] suggests using
an iFrame for that: this way, you can even trigger the download by using a
button or an event. ;-)

Hope this helps,
 Helder Magalhães


[1] http://www.ietf.org/rfc/rfc2183.txt
[2] http://pt2.php.net/header
[3] http://www.nabble.com/Download-Button-td21977617.html
-- 
View this message in context: 
http://www.nabble.com/How-to-force-a-download-%28like-plain-old-link%29---tp23252241p23252991.html
Sent from the qooxdoo-devel mailing list archive at Nabble.com.


------------------------------------------------------------------------------
Crystal Reports - New Free Runtime and 30 Day Trial
Check out the new simplified licensign option that enables unlimited
royalty-free distribution of the report engine for externally facing 
server and web deployment.
http://p.sf.net/sfu/businessobjects
_______________________________________________
qooxdoo-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel

Reply via email to