PHP is_link() Function

Definition

The is_link() function checks whether the specified file is a link.

Syntax

PHP is_link() Function has the following syntax.

is_link(file)

Parameter

ParameterIs RequiredDescription
fileRequired.File to check

Return

This function returns TRUE if it is a link.

Note

The result of this function are cached. Use clearstatcache() to clear the cache.

Example


<?php/* w  ww .  java  2s  .c  o m*/
$link = "images";
if(is_link($link)){
  echo ("$link is a link");
}else{
  echo ("$link is not a link");
}
?>

The code above generates the following result.





















Home »
  PHP Tutorial »
    Function reference »




PHP Array Functions
PHP Calendar Functions
PHP Class Functions
PHP Data Type Functions
PHP Date Functions
PHP File Functions
PHP Image Functions
PHP Math Functions
PHP MySQLi Functions
PHP SimpleXML Functions
PHP String Functions
PHP XML Functions
PHP Zip Functions