Skip to content

Delete / Remove cropImage #9

@tomfrit

Description

@tomfrit

Hello,
I'm having problems deleting and removing images from a cropImage field via the API. I tried

foreach ($video->teaserbild as $img) {
    $video->teaserbild->remove($img);
}

and also

$video->teaserbild->removeAll();

But no success. The image file gets deleted but the data stays in the field. If I try again, unlink() throws an error since the file doesn't exist. I'm on PW 2.3.0 and cropImage is up to date.

Thanks,
thomas

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions