Is it possible to duplicate a page in the panel? I guess i need a custom field with a button to achieve it. Is $page->hardcopy() the way to go?
That would be better off in a custom section, not a field, as it is not supposed to store anything in the page.
And no, not hardcopy (that creates a clone), you have to create a page ($page->create()).
Can i found some documentation about that, with some lines of code to get started please?
Is there a simple way to create a new page ($page->create()) with the content and structure of an existing page? What is the best way to do this?
Maybe as child of another page?
If you want to duplicate a page from a section, it would probably be best to create a custom section with an option to copy a page from the drop down (where you currently select
I know how to make a custom section with a button, but I think i will have to look in php for some code to copy/paste a specific directory and content. Seems not possible in Kirby, or i don’t know how Thanks anyway.
In the older versions of Kirby, duplicating a page was as easy as installing a plugin. Do none of these plugins work anymore? The methods above seem to be beyond my cap. Has anyone successfully implemented this function? If so, could you tell me how?
Do you have an example of these Kirby 2 plugins?