Perl uses File::basename to get the code for the file name extension _perl

Source: Internet
Author: User
The File::basename module is used to extract directories, filenames, and suffixes from the file path.
This article introduces this example to get all the file suffixes in the/home/topgkw, where the directory returns a null value.
The detailed usage of this module can be viewed through the Perldoc file::basename command, suggesting that you often use Perldoc refer to the detailed introduction of the relevant modules, more than the online search to the information is much stronger.

Example:


Attention:

1), if you use print start_html, you will output something similar to the following:

<! DOCTYPE html
Public "-//W3C//DTD XHTML 1.0 transitional//en"
"Http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd" >
<title>untitled document</title>
<meta http-equiv= "Content-type" content= "text/html; Charset=iso-8859-1 "/>
<body>

2), using print end_html, you will output something similar to the following:

</body>

From: Script Academy
Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.