<?xml version="1.0" encoding="utf-8" ?><rss version="2.0" xml:base="https://www.webmaster-forums.net/crss/node/1013023" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title></title>
    <link>https://www.webmaster-forums.net/crss/node/1013023</link>
    <description></description>
    <language>en</language>
          <item>
    <title>that&#039;s ok</title>
    <link>https://www.webmaster-forums.net/serverside-scripting/delete-file-older-x-days#comment-1075805</link>
    <description> &lt;p&gt;thanks japhy, you told me what i was looking for. and beside, the hard thing (at least for me) is the syntax. for changing the file-selection i only have to change the letter (-A, -C, -M).&lt;/p&gt;
 </description>
     <pubDate>Mon, 18 Dec 2000 09:25:14 +0000</pubDate>
 <dc:creator>merlin</dc:creator>
 <guid isPermaLink="false">comment 1075805 at https://www.webmaster-forums.net</guid>
  </item>
  <item>
    <title>oops...</title>
    <link>https://www.webmaster-forums.net/serverside-scripting/delete-file-older-x-days#comment-1075789</link>
    <description> &lt;p&gt;Well, now I feel kinda silly.  The code I&#039;d posted &lt;strong&gt;was&lt;/strong&gt; for files that have not been updated in X days.  So that answers your question, Edge.&lt;/p&gt;
&lt;p&gt;You can&#039;t get at the creation time of files, alibababa, so the code you&#039;re using is testing for when the file was last modified.  That might be what you wanted, though.&lt;/p&gt;
 </description>
     <pubDate>Sun, 17 Dec 2000 17:38:11 +0000</pubDate>
 <dc:creator>japhy</dc:creator>
 <guid isPermaLink="false">comment 1075789 at https://www.webmaster-forums.net</guid>
  </item>
  <item>
    <title></title>
    <link>https://www.webmaster-forums.net/serverside-scripting/delete-file-older-x-days#comment-1075788</link>
    <description> &lt;p&gt;Just wondering, how would you delete all files that haven&#039;t been modified within x number of days?&lt;/p&gt;
&lt;p&gt;--Edge&lt;/p&gt;
 </description>
     <pubDate>Sun, 17 Dec 2000 17:33:44 +0000</pubDate>
 <dc:creator>Edge</dc:creator>
 <guid isPermaLink="false">comment 1075788 at https://www.webmaster-forums.net</guid>
  </item>
  <item>
    <title>yep!</title>
    <link>https://www.webmaster-forums.net/serverside-scripting/delete-file-older-x-days#comment-1075612</link>
    <description> &lt;p&gt;that worked! i didn&#039;t give the path of the file, that&#039;s what i made wrong, probably...&lt;br /&gt;
anyway, now it&#039;s working and it&#039;s great! thanks japhy!&lt;/p&gt;
 </description>
     <pubDate>Wed, 13 Dec 2000 08:18:18 +0000</pubDate>
 <dc:creator>merlin</dc:creator>
 <guid isPermaLink="false">comment 1075612 at https://www.webmaster-forums.net</guid>
  </item>
  <item>
    <title>How doesn&#039;t it work?</title>
    <link>https://www.webmaster-forums.net/serverside-scripting/delete-file-older-x-days#comment-1075601</link>
    <description> &lt;p&gt;You should be testing the return value of &lt;strong&gt;unlink()&lt;/strong&gt; -- maybe then, you&#039;ll have a better idea of why it&#039;s not working.  It works for me:&lt;/p&gt;
&lt;p&gt;&lt;div class=&quot;codeblock&quot;&gt;&lt;code&gt;opendir DIR, $path or die &amp;quot;can&amp;#039;t read $path: $!&amp;quot;;&lt;br /&gt;while (defined(my $file = readdir DIR)) {&lt;br /&gt;&amp;nbsp; # use the path to the file, not just the name of the file&lt;br /&gt;&amp;nbsp; next unless -f &amp;quot;$path/$file&amp;quot;;&lt;br /&gt;&amp;nbsp; if (-M &amp;quot;$path/$file&amp;quot; &amp;gt;= 7) {&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; # delete if a week old&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; unlink &amp;quot;$path/$file&amp;quot; or warn &amp;quot;can&amp;#039;t delete $path/$file: $!&amp;quot;;&lt;br /&gt;&amp;nbsp; }&lt;br /&gt;}&lt;br /&gt;closedir DIR;&lt;/code&gt;&lt;/div&gt;&#039;&lt;/p&gt;
 </description>
     <pubDate>Tue, 12 Dec 2000 23:20:43 +0000</pubDate>
 <dc:creator>japhy</dc:creator>
 <guid isPermaLink="false">comment 1075601 at https://www.webmaster-forums.net</guid>
  </item>
  </channel>
</rss>
