Hi Monks

I am using mirror method to get the update webpage content

here is my code

if($mech->mirror("url","$filename") == RC_NOT_MODIFIED ) { print " link not Updated \n\n\n"; if($mech->response()->is_success){ print " response is success\n\n"; print " content :",$mech->response()->as_strin +g,"\n\n"; } else { print "failure \n\n"; } } else { print " link updated...\n\n"; $mech->save_content($filename); }

When i run this above code i get some irregular files except download file

# Command line output error Cannot rename '-23348' to '': No such file or directory $ls -23094 -23348 code.pl config.ini downloads downloads1 downloads2 + Download_Status.doc output.txt $ ls ./* -lthr 727 May 26 09:41 ./config.ini 9.2K May 26 09:54 ./code.pl 11M May 26 09:54 ./-23094 113 May 26 09:55 ./Download_Status.doc 26M May 26 10:04 ./-23348

my doubt is why am getting this "-23348" file and how can i get update page content???

Please Help me to find a correct path


In reply to Problem in mirror method by perlmad

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.