i noticed something i didn’t really understand.
I have two Pluginfolders in use: “kd-core-extension” and “kd-custom-extension”
The idea behind this is, that the core will contain generic stuff for the template which will be updated regularly and the custom is kind of a blank plugin, which will bring in adjustments specific for the customer i am designing for.
So in the core plugin i have a entry.php which is included perfectly.
If i create a entry.php in the custom plugin it should overide the file from the core. But for some reason this does not work. As soon as i rename the entry.php from the core-plugin. The entry.php form the custom kicks in.
From the alphabetical order “custom” should be loaded after “core” so i dont understand why this is not working.
Yes, that is to be expected (Kirby does an array_merge()), as the same snippet/template in a plugin that is loaded after the other, overwrites the first.
I noticed, that it works with templates.
So home.php in custom overides home.php in core.
But the entry.php snippet is always taken from the core. As soon as i rename or delete it from core, the snippet from custom kicks in.
What I don’t really understand is why you use a second plugin for the overwrites instead of simply putting the overwrite snippets into /site/snippets etc.
You are correct. Originally i thought it would be easier for me to handle in case of updating my template, if have all custom stuff in a single Plugin folder. But i know changed my structure, like you described and it should work super well also. Thanks^^