Skip to content

Instantly share code, notes, and snippets.

@danieldsf
Last active January 20, 2018 09:10
Show Gist options
  • Save danieldsf/cf0d1f38595a2b748471e63265782de8 to your computer and use it in GitHub Desktop.
Save danieldsf/cf0d1f38595a2b748471e63265782de8 to your computer and use it in GitHub Desktop.
<?php
#TESTA SE O ARQUIVO EXISTE:
$file = "endereco_do_arquivo_url";
$file_headers = @get_headers($file);
$existe = true;
if($file_headers[0] == 'HTTP/1.1 404 Not Found') {
$existe = false;
}
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment