thanks for the help :) okay, another related question:
($self, $keyword, $keyword2, $keyword3, $keyword4, $keyword5, $keyword +6, $domain) = (@_);
That's how I'm getting a series of values into a module, which seems to be working...however, when I parse those with this:
$sub1 = $keyword; $sub2 = $keyword2; $sub3 = $keyword3; $sub4 = $keyword4; $sub5 = $keyword5; $sub6 = $keyword6; $noun1 = &makeNlink($sub1, $domain); $noun2 = &makeNlink($sub2, $domain); $noun3 = &makeNlink($sub3, $domain); $noun4 = &makeNlink($sub4, $domain); $noun5 = &makeNlink($sub5, $domain); $noun6 = &makeNlink($sub6, $domain);
and then this is the sub &makeNlink
sub makeNlink { #($tobelink, $tobelinkurl) = @_; $tobelink = shift(@_); $tobelinkurl = shift(@_); $withspaces = $tobelink; $tobelink =~ s/\s/_/g; chomp($withspaces); chomp($tobelink); $totallyscrewed = "<a href \= \"http\:\/\/$domain\/$tobelink\" +>$withspaces<\/a>"; return $totallyscrewed; }
The values are used over and over, the same series each time, when in the main script they are totally different. How do I make sure the current value of each variable is imported into this module? Thanks very, very much for the help! This place rocks.

In reply to Re: Re: using perl variable in muliple modules by jeremy_goodrich
in thread using perl variable in muliple modules by jeremy_goodrich

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.