Filters the attached file based on the given ID.
$attachment_id, $file
Sortie :
@param string|false $file The file path to where the attached file should be, false otherwise. @param int $attachment_id Attachment ID. @param int $attachment_id Attachment ID. @param string $file File path for the attachment. @return int|bool Meta ID if the `_wp_attached_file` key didn't exist for the attachment.
// Utilisation de la fonction update_attached_file
$result = update_attached_file($attachment_id, $file);
if ($result) {
// Votre logique ici
}
Chargement des actualités...