[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[no subject]
- <!--x-content-type: text/plain -->
- <!--x-date: Fri Jul 30 13:02:39 2004 -->
- <!--x-from-r13: syrgpu ng culqrnhk.bet (Tyrgpu) -->
- <!--x-message-id: [email protected] -->
- <!--x-reference: [email protected] --> "http://www.w3.org/TR/html4/loose.dtd">
- <!--x-subject: [ale] Perl Question -->
- <li><em>date</em>: Fri Jul 30 13:02:39 2004</li>
- <li><em>from</em>: fletch at phydeaux.org (Fletch)</li>
- <li><em>in-reply-to</em>: <<a href="msg00785.html">[email protected]</a>> (Christopher Fowler's message of "30 Jul 2004 10:17:51 -0400")</li>
- <li><em>references</em>: <<a href="msg00785.html">[email protected]</a>></li>
- <li><em>subject</em>: [ale] Perl Question</li>
At any rate, yes it's quite feasable to pass key => value params, then
in your sub do something along the lines of:
sub foozle {
my %defaults = ( wonkle => 'zorbnats',
fleegle => 'wubba wubba', );
my %args = ( %defaults, @_ );
if( exists $args{ optional } ) {
## ...
}
print "fleegle: ", $args{ fleegle }, "\n";
}
--
Fletch | "If you find my answers frightening, __`'/|
fletch at phydeaux.org | Vincent, you should cease askin' \ o.O'
| scary questions." -- Jules =(___)=
| U
</pre>
<!--X-Body-of-Message-End-->
<!--X-MsgBody-End-->
<!--X-Follow-Ups-->
<hr>
<ul><li><strong>Follow-Ups</strong>:
<ul>
<li><strong><a name="00794" href="msg00794.html">[ale] Perl Question</a></strong>
<ul><li><em>From:</em> jkinney at localnetsolutions.com (James P. Kinney III)</li></ul></li>
</ul></li></ul>
<!--X-Follow-Ups-End-->
<!--X-References-->
<ul><li><strong>References</strong>:
<ul>
<li><strong><a name="00785" href="msg00785.html">[ale] Perl Question</a></strong>
<ul><li><em>From:</em> cfowler at outpostsentinel.com (Christopher Fowler)</li></ul></li>
</ul></li></ul>
<!--X-References-End-->
<!--X-BotPNI-->
<ul>
<li>Prev by Date:
<strong><a href="msg00792.html">[ale] local mailserver and POP3</a></strong>
</li>
<li>Next by Date:
<strong><a href="msg00794.html">[ale] Perl Question</a></strong>
</li>
<li>Previous by thread:
<strong><a href="msg00785.html">[ale] Perl Question</a></strong>
</li>
<li>Next by thread:
<strong><a href="msg00794.html">[ale] Perl Question</a></strong>
</li>
<li>Index(es):
<ul>
<li><a href="maillist.html#00793"><strong>Date</strong></a></li>
<li><a href="threads.html#00793"><strong>Thread</strong></a></li>
</ul>
</li>
</ul>
<!--X-BotPNI-End-->
<!--X-User-Footer-->
<!--X-User-Footer-End-->
</body>
</html>