<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: Sava&#8217;s Single File Upload Script</title>
	<atom:link href="http://savasplace.com/2009/01/savas-single-file-upload-script/feed/" rel="self" type="application/rss+xml" />
	<link>http://savasplace.com/2009/01/savas-single-file-upload-script/</link>
	<description>Free PHP scripts, CSS templates, Making Money Online and Miscellaneous Ramblings</description>
	<lastBuildDate>Tue, 31 Jan 2012 10:40:36 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
	<item>
		<title>By: Fabio</title>
		<link>http://savasplace.com/2009/01/savas-single-file-upload-script/comment-page-1/#comment-1005</link>
		<dc:creator>Fabio</dc:creator>
		<pubDate>Wed, 02 Feb 2011 16:31:09 +0000</pubDate>
		<guid isPermaLink="false">http://savasplace.com/?p=1248#comment-1005</guid>
		<description>Hi,  2 questions: 

a) $upload_url = $url_dir.&quot;/uploads/&quot;; should be a  ## User edited variables ## ? 

b) i can&#039;t remove files</description>
		<content:encoded><![CDATA[<p>Hi,  2 questions: </p>
<p>a) $upload_url = $url_dir.&#8221;/uploads/&#8221;; should be a  ## User edited variables ## ? </p>
<p>b) i can&#8217;t remove files</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Sava</title>
		<link>http://savasplace.com/2009/01/savas-single-file-upload-script/comment-page-1/#comment-629</link>
		<dc:creator>Sava</dc:creator>
		<pubDate>Fri, 04 Jun 2010 11:41:32 +0000</pubDate>
		<guid isPermaLink="false">http://savasplace.com/?p=1248#comment-629</guid>
		<description>Not sure. If you made any modifications download the script again. 

This is the code that generated that link:

&lt;code&gt;
		$url_dir = &quot;http://&quot;.$_SERVER[&#039;HTTP_HOST&#039;].dirname($_SERVER[&#039;PHP_SELF&#039;]);
		$upload_url = $url_dir.&quot;/files/&quot;;
&lt;/code&gt;

No \ there</description>
		<content:encoded><![CDATA[<p>Not sure. If you made any modifications download the script again. </p>
<p>This is the code that generated that link:</p>
<p><code><br />
		$url_dir = "http://".$_SERVER['HTTP_HOST'].dirname($_SERVER['PHP_SELF']);<br />
		$upload_url = $url_dir."/files/";<br />
</code></p>
<p>No \ there</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: DuxBellorum</title>
		<link>http://savasplace.com/2009/01/savas-single-file-upload-script/comment-page-1/#comment-628</link>
		<dc:creator>DuxBellorum</dc:creator>
		<pubDate>Fri, 04 Jun 2010 08:54:24 +0000</pubDate>
		<guid isPermaLink="false">http://savasplace.com/?p=1248#comment-628</guid>
		<description>Hi! 

Clicking on View (Action -&gt; View file) gives me the following url:
http://192.168.123.123\/files/testupload.txt 

Why is there a \ in the url?</description>
		<content:encoded><![CDATA[<p>Hi! </p>
<p>Clicking on View (Action -&gt; View file) gives me the following url:<br />
<a href="http://192.168.123.123" rel="nofollow">http://192.168.123.123</a>\/files/testupload.txt </p>
<p>Why is there a \ in the url?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Sava</title>
		<link>http://savasplace.com/2009/01/savas-single-file-upload-script/comment-page-1/#comment-432</link>
		<dc:creator>Sava</dc:creator>
		<pubDate>Mon, 02 Nov 2009 05:48:11 +0000</pubDate>
		<guid isPermaLink="false">http://savasplace.com/?p=1248#comment-432</guid>
		<description>Locate this line in upload.php:
&lt;strong&gt;$file_name = str_replace(&quot;&#039;&quot;,&quot;&quot;,$file_name);&lt;/strong&gt;
and add these 2 lines right after it:

&lt;strong&gt;$new_file_name = explode(&#039;.&#039;, $file_name);
$file_name = $new_file_name[0].date(&#039;YmdHis&#039;).&#039;.&#039;.$new_file_name[1];&lt;/strong&gt;

This way no uploaded file will ever have the same name.</description>
		<content:encoded><![CDATA[<p>Locate this line in upload.php:<br />
<strong>$file_name = str_replace(&#8220;&#8216;&#8221;,&#8221;",$file_name);</strong><br />
and add these 2 lines right after it:</p>
<p><strong>$new_file_name = explode(&#8216;.&#8217;, $file_name);<br />
$file_name = $new_file_name[0].date(&#8216;YmdHis&#8217;).&#8217;.&#8217;.$new_file_name[1];</strong></p>
<p>This way no uploaded file will ever have the same name.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Sava</title>
		<link>http://savasplace.com/2009/01/savas-single-file-upload-script/comment-page-1/#comment-431</link>
		<dc:creator>Sava</dc:creator>
		<pubDate>Mon, 02 Nov 2009 05:36:53 +0000</pubDate>
		<guid isPermaLink="false">http://savasplace.com/?p=1248#comment-431</guid>
		<description>Email sent.</description>
		<content:encoded><![CDATA[<p>Email sent.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Steven</title>
		<link>http://savasplace.com/2009/01/savas-single-file-upload-script/comment-page-1/#comment-427</link>
		<dc:creator>Steven</dc:creator>
		<pubDate>Sat, 31 Oct 2009 16:16:36 +0000</pubDate>
		<guid isPermaLink="false">http://savasplace.com/?p=1248#comment-427</guid>
		<description>I grabbed your script and I get this back:


Warning: opendir(gsmanga.pinochan.net/BOA/files) [function.opendir]: failed to open dir: No such file or directory in /home/.peggy/gsmanga/gsmanga.pinochan.net/BOA/upload/upload.php on line 96

Warning: readdir(): supplied argument is not a valid Directory resource in /home/.peggy/gsmanga/gsmanga.pinochan.net/BOA/upload/upload.php on line 101

Any help? I do have that directory and I did CHmod it to 777 like it said in your instructions. I am trying to allow people to upload music files for an online jukebox for my site...</description>
		<content:encoded><![CDATA[<p>I grabbed your script and I get this back:</p>
<p>Warning: opendir(gsmanga.pinochan.net/BOA/files) [function.opendir]: failed to open dir: No such file or directory in /home/.peggy/gsmanga/gsmanga.pinochan.net/BOA/upload/upload.php on line 96</p>
<p>Warning: readdir(): supplied argument is not a valid Directory resource in /home/.peggy/gsmanga/gsmanga.pinochan.net/BOA/upload/upload.php on line 101</p>
<p>Any help? I do have that directory and I did CHmod it to 777 like it said in your instructions. I am trying to allow people to upload music files for an online jukebox for my site&#8230;</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Kevin</title>
		<link>http://savasplace.com/2009/01/savas-single-file-upload-script/comment-page-1/#comment-426</link>
		<dc:creator>Kevin</dc:creator>
		<pubDate>Fri, 30 Oct 2009 17:29:00 +0000</pubDate>
		<guid isPermaLink="false">http://savasplace.com/?p=1248#comment-426</guid>
		<description>When a user uploads the same file name it overwrites the original file. I need it to rename the new file instead.
Thanks.</description>
		<content:encoded><![CDATA[<p>When a user uploads the same file name it overwrites the original file. I need it to rename the new file instead.<br />
Thanks.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Sava</title>
		<link>http://savasplace.com/2009/01/savas-single-file-upload-script/comment-page-1/#comment-394</link>
		<dc:creator>Sava</dc:creator>
		<pubDate>Tue, 01 Sep 2009 21:32:52 +0000</pubDate>
		<guid isPermaLink="false">http://savasplace.com/?p=1248#comment-394</guid>
		<description>Commander Killbot. I forgot to reply to your comment. The script has been rewritten. The notices will not appear if you download the new archive.</description>
		<content:encoded><![CDATA[<p>Commander Killbot. I forgot to reply to your comment. The script has been rewritten. The notices will not appear if you download the new archive.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Commander Killbot</title>
		<link>http://savasplace.com/2009/01/savas-single-file-upload-script/comment-page-1/#comment-375</link>
		<dc:creator>Commander Killbot</dc:creator>
		<pubDate>Wed, 19 Aug 2009 13:12:22 +0000</pubDate>
		<guid isPermaLink="false">http://savasplace.com/?p=1248#comment-375</guid>
		<description>Hi,
Thanks for the script - I&#039;m using it with XAMPP on a SuSE box and it seems to be working for both uploads and deletes, but I&#039;m getting error notices like this:

Notice: Use of undefined constant del - assumed &#039;del&#039; in /opt/lampp/htdocs/upload/upload.php on line 42

Notice: Undefined index: del in /opt/lampp/htdocs/upload/upload.php on line 42

Notice: Undefined index: userfile in /opt/lampp/htdocs/upload/upload.php on line 54

Notice: Undefined index: userfile in /opt/lampp/htdocs/upload/upload.php on line 76

Notice: Use of undefined constant message - assumed &#039;message&#039; in /opt/lampp/htdocs/upload/upload.php on line 131
deleted successfully 

Since the script is working, this is not of vital importance, but can you help me figure out what&#039;s going on with the notices?

Thanks!</description>
		<content:encoded><![CDATA[<p>Hi,<br />
Thanks for the script &#8211; I&#8217;m using it with XAMPP on a SuSE box and it seems to be working for both uploads and deletes, but I&#8217;m getting error notices like this:</p>
<p>Notice: Use of undefined constant del &#8211; assumed &#8216;del&#8217; in /opt/lampp/htdocs/upload/upload.php on line 42</p>
<p>Notice: Undefined index: del in /opt/lampp/htdocs/upload/upload.php on line 42</p>
<p>Notice: Undefined index: userfile in /opt/lampp/htdocs/upload/upload.php on line 54</p>
<p>Notice: Undefined index: userfile in /opt/lampp/htdocs/upload/upload.php on line 76</p>
<p>Notice: Use of undefined constant message &#8211; assumed &#8216;message&#8217; in /opt/lampp/htdocs/upload/upload.php on line 131<br />
deleted successfully </p>
<p>Since the script is working, this is not of vital importance, but can you help me figure out what&#8217;s going on with the notices?</p>
<p>Thanks!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Sava</title>
		<link>http://savasplace.com/2009/01/savas-single-file-upload-script/comment-page-1/#comment-342</link>
		<dc:creator>Sava</dc:creator>
		<pubDate>Tue, 28 Jul 2009 13:58:51 +0000</pubDate>
		<guid isPermaLink="false">http://savasplace.com/?p=1248#comment-342</guid>
		<description>Fabio, you have to chmod to 777 the directory in which you try to upload.
For example you want to upload into directory &quot;files&quot; then you have to create &quot;/root/files&quot; directory and chmod it to 777.</description>
		<content:encoded><![CDATA[<p>Fabio, you have to chmod to 777 the directory in which you try to upload.<br />
For example you want to upload into directory &#8220;files&#8221; then you have to create &#8220;/root/files&#8221; directory and chmod it to 777.</p>
]]></content:encoded>
	</item>
</channel>
</rss>

