For the sake of all that's holy, use some line breaks!
I was scrolling for a while to catch the end of the code...
I guess it would be kind of silly to change something like
$site =~ s/<BODY bgcolor="#000000" text="#000000" link="#00 +6666" vlink="#000000">/<BODY bgcolor="#000001" text="#4FFFAF" link="# +00BBBB" vlink="#4F2F9F">/;
to
my $from = '<BODY bgcolor="#000000" text="#000000" link="#006666" +vlink="#000000">'; my $to = '<BODY bgcolor="#000001" text="#4FFFAF" link="#00BBBB" vl +ink="#4F2F9F">'; $site =~ s/$from/$to/;
Perhaps extended regexps are the answer?
$site =~ s/ <BODY\sbgcolor="\#000000"\stext="\#000000"\slink="\#006666"\svlink +="\#000000"> /<BODY bgcolor="#000001" text="#4FFFAF" link="#00BBBB" vlink="#4F2 +F9F">/x;
Or even
$site =~ s/ <BODY[ ]bgcolor="\#000000"[ ]text="\#000000"[ ]link="\#006666"[ ]v +link="\#000000"> /<BODY bgcolor="#000001" text="#4FFFAF" link="#00BBBB" vlink="#4F2 +F9F">/x;
What do you think? It looks a little ugly, I suppose.

Instead of useing extended regexps, we could just use the
(somewhat less well known) regexp extensions:

$site =~ s/<BODY bgcolor="#000000" text="#000000" link="#006666" vlink +="#000000">(?# )/<BODY bgcolor="#000001" text="#4FFFAF" link="#00BBBB" vlink="#4 +F2F9F">/;
Which is probably the way to go.

In reply to RE: Dark Theme for /. through Perl by Alokito
in thread Dark Theme for /. through Perl by PipTigger

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.