Hi, I really struggled and failed to create a meaningful title! Sorry.

I have written a crude perl script to search through all the files in a directory for certain text strings and then collate these strings into one text file. The reason is to allow me to collect configuration information from a number of flat files.

If I create a file(s) and put strings in that will match, it works fine. I have successfully used it on one set of config files, however, another set do not work properly. I have added code to print out each of the lines from my array and the format of the data looks a bit weird. Hard to describe, but it looks like it is in a different font and with additional spaces. Even though these are exactly the same type of config files.

I'm guessing that there is something wrong with these particular files - they were copied straight off the server via the network share (same as the set that work), so it's not like I've FTP them as binary.

Can anyone shed any light as to why these files might be behaving like this?

Many Thanks.


In reply to Issue manipulating data - problem with data file format by maccas17

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.