[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[no subject]
- <!--x-content-type: text/plain -->
- <!--x-date: Tue Jun 15 21:25:38 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 Regexe questions -->
- <li><em>date</em>: Tue Jun 15 21:25:38 2004</li>
- <li><em>from</em>: fletch at phydeaux.org (Fletch)</li>
- <li><em>in-reply-to</em>: <<a href="msg00330.html">[email protected]</a>> (Keith R. Watson's message of "Tue, 15 Jun 2004 20:36:55 -0400")</li>
- <li><em>references</em>: <<a href="msg00330.html">[email protected]</a>></li>
- <li><em>subject</em>: [ale] Perl Regexe questions</li>
[...]
Keith> use File::Basename;
Keith> my ($other_way, undef, undef) = fileparse($full_path,);
Keith> print ($other_way, "\n");
Actually my $name = basename( $full_path ) would probably be better
(not to mention the undefs are extraneous as any extra list elements
would just be dropped; a more succinct way would have been
my $path = ( fileparse( $full_path ) )[0];
--
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="00334" href="msg00334.html">[ale] Perl Regexe questions</a></strong>
<ul><li><em>From:</em> cfowler at outpostsentinel.com (Christopher Fowler)</li></ul></li>
</ul></li></ul>
<!--X-Follow-Ups-End-->
<!--X-References-->
<ul><li><strong>References</strong>:
<ul>
<li><strong><a name="00330" href="msg00330.html">[ale] Perl Regexe questions</a></strong>
<ul><li><em>From:</em> keith.watson at gtri.gatech.edu (Keith R. Watson)</li></ul></li>
</ul></li></ul>
<!--X-References-End-->
<!--X-BotPNI-->
<ul>
<li>Prev by Date:
<strong><a href="msg00330.html">[ale] Perl Regexe questions</a></strong>
</li>
<li>Next by Date:
<strong><a href="msg00332.html">[ale] Cable Modem Strangeness On The Road</a></strong>
</li>
<li>Previous by thread:
<strong><a href="msg00330.html">[ale] Perl Regexe questions</a></strong>
</li>
<li>Next by thread:
<strong><a href="msg00334.html">[ale] Perl Regexe questions</a></strong>
</li>
<li>Index(es):
<ul>
<li><a href="maillist.html#00331"><strong>Date</strong></a></li>
<li><a href="threads.html#00331"><strong>Thread</strong></a></li>
</ul>
</li>
</ul>
<!--X-BotPNI-End-->
<!--X-User-Footer-->
<!--X-User-Footer-End-->
</body>
</html>