<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
		<id>https://docs-old.ckeditor.com/index.php?action=history&amp;feed=atom&amp;title=CKFinder_2.x%2FServer_Side_Integration%2FThe_Commands%2FDownloadFile</id>
		<title>CKFinder 2.x/Server Side Integration/The Commands/DownloadFile - Revision history</title>
		<link rel="self" type="application/atom+xml" href="https://docs-old.ckeditor.com/index.php?action=history&amp;feed=atom&amp;title=CKFinder_2.x%2FServer_Side_Integration%2FThe_Commands%2FDownloadFile"/>
		<link rel="alternate" type="text/html" href="https://docs-old.ckeditor.com/index.php?title=CKFinder_2.x/Server_Side_Integration/The_Commands/DownloadFile&amp;action=history"/>
		<updated>2026-04-29T05:32:26Z</updated>
		<subtitle>Revision history for this page on the wiki</subtitle>
		<generator>MediaWiki 1.29.1</generator>

	<entry>
		<id>https://docs-old.ckeditor.com/index.php?title=CKFinder_2.x/Server_Side_Integration/The_Commands/DownloadFile&amp;diff=3039&amp;oldid=prev</id>
		<title>Wiktor: Created page with '{{CKFinder_2.x_SSI_Warning}} == DownloadFile ==  Downloads a file from the server.  === Sample Request ===  Download the file named “Test.jpg” from the the root directory of …'</title>
		<link rel="alternate" type="text/html" href="https://docs-old.ckeditor.com/index.php?title=CKFinder_2.x/Server_Side_Integration/The_Commands/DownloadFile&amp;diff=3039&amp;oldid=prev"/>
				<updated>2010-05-14T20:08:35Z</updated>
		
		<summary type="html">&lt;p&gt;Created page with &amp;#039;{{CKFinder_2.x_SSI_Warning}} == DownloadFile ==  Downloads a file from the server.  === Sample Request ===  Download the file named “Test.jpg” from the the root directory of …&amp;#039;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;{{CKFinder_2.x_SSI_Warning}}&lt;br /&gt;
== DownloadFile ==&lt;br /&gt;
&lt;br /&gt;
Downloads a file from the server.&lt;br /&gt;
&lt;br /&gt;
=== Sample Request ===&lt;br /&gt;
&lt;br /&gt;
Download the file named “Test.jpg” from the the root directory of the resource type “Files”.&lt;br /&gt;
&amp;lt;pre&amp;gt;connector.php?command=DownloadFile&amp;amp;amp;type=Files&amp;amp;amp;currentFolder=%2F&amp;amp;amp;FileName=Test.jpg&amp;lt;/pre&amp;gt;&lt;br /&gt;
=== Response ===&lt;br /&gt;
&lt;br /&gt;
This command doesn’t expect the connector to return a text response. Instead, it must stream the file data to the browser.&lt;br /&gt;
&lt;br /&gt;
An important difference between a “download” stream and a normal stream, is that the “Save as” dialog will always show in the browser, instead of opening the file on it (like for .html or .jpg file). To achieve that, the “Content-Disposition” header must be set accordingly. For example, the following is the code to set the header when the “Test.jpg” file is requested (in PHP):&lt;br /&gt;
&amp;lt;pre&amp;gt;header( 'Content-Type: application/octet-stream' )&amp;amp;nbsp;;&lt;br /&gt;
header( 'Content-Disposition: attachment; filename=Test.jpg' )&amp;amp;nbsp;;&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Wiktor</name></author>	</entry>

	</feed>