i see all my pages:
try SPEAKER
try ACT01
try ACT02
try ACT03
try BLCK01____a
try BLCK01____b
try BLCK02____c
Now when i activate the delete-action
$avpage->delete(true);
i got this result: the second in the list (ACT01) is not in the try and not in the catch, it’s skipped … I also changed the order of the items and the names, but it seems it’s always the second one that is skipped.
No, i checked this and i see no errors concerning this.
It sounds like a bug. I tested this on another place with the same problem.
I just created dynamically 100pages. Then i tried to delete them and they are all deleted except 1. The second is not deleted.
when you loop through the ‘listed’ pages it’s even worse, then only the first page is deleted.
foreach($availabilitiespage->children()->listed() as $avpage){
$avpage->delete(true);
}
I downloaded the latest Starterkit now and i added this code to the home.php template. This code should delete the notes-subpages and the photography-subpages.
The result for me is that the photography-pages are gone except 1 (the second in the list ‘trees’ has not been deleted)
For the notes succeeded page 1, 3, 5 and 7. (note 2, 4 and 6 are not deleted).
@texnixe@moeli
I tested both codes in a hook on the Starterkit project.
The notes are deleted correctly. But the Photography-pages are not. Only the first item is deleted. Is there a solution/workaround to get this working?