SplFileInfo::isLink
(PHP 5 >= 5.1.2, PHP 7, PHP 8)
SplFileInfo::isLink — Tells if the file is a link
说明
Use this method to check if the file referenced by the SplFileInfo object is a link.
参数
此函数没有参数。
示例
示例 #1 SplFileInfo::isLink() example
<?php
$info = new SplFileInfo('/path/to/symlink');
if ($info->isLink()) {
echo 'The real path is '.$info->getRealPath();
}
?>
+添加备注
用户贡献的备注
此页面尚无用户贡献的备注。