Menu Home

symlink

osbo.com | PHP | Functions | symlink

Creates a symbolic link

Syntax

symlink ( string $target , string $link ) : bool

Parameters

target

Target of the link.

link

The link name.

Return

Returns TRUE on success or FALSE on failure.

Examples

<?

$target = 'symlink.php';
$link = 'symlink';

symlink($target, $link);
echo readlink($link);

unlink($link);

?>
symlink.php

PHP