Skip to content

Instantly share code, notes, and snippets.

@lucianobragaweb
Last active February 19, 2022 13:42
Show Gist options
  • Save lucianobragaweb/7739742 to your computer and use it in GitHub Desktop.
Save lucianobragaweb/7739742 to your computer and use it in GitHub Desktop.
Excluir arquivo no servidor com PHP
<?php
// Script para deletar arquivos
// unlink -> função do php para deletar arquivos
$arquivo = "wp-config.php";
if (!unlink($arquivo)) {
echo ("Erro ao deletar $arquivo");
} else {
echo ("Deletado $arquivo com sucesso!");
}
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment