Delete file

  다른 뜻에 대해서는 리눅스 unlink 문서를 참조하십시오.
unlink
rm

1 Bash[ | ]

echo 'John Smith' > /tmp/a.txt
if [ ! -f /tmp/a.txt ]; then echo 'File not found #1'; fi

rm -f /tmp/a.txt
if [ ! -f /tmp/a.txt ]; then echo 'File not found #2'; fi
# File not found #2

2 PHP[ | ]

file_put_contents('/tmp/a.txt', 'unlinkJohn Smith');
if( !file_exists('/tmp/a.txt') ) echo 'File not found #1'.PHP_EOL;

unlink('/tmp/a.txt');
if( !file_exists('/tmp/a.txt') ) echo 'File not found #2'.PHP_EOL;
// File not found #2

3 같이 보기[ | ]

문서 댓글 ({{ doc_comments.length }})
{{ comment.name }} {{ comment.created | snstime }}