2013-03-16, 04:10:18
I'm trying to set up something similar to what modx is doing where I have two page templates, and each has different template variables and gets rendered differently. (would be nice to have a separate link to create different page types)
I know this is outside of the scope of getSimple, but I think I can make this work.
As I haven't hacked the core or created plugins before I'm interested in hearing any feedback on how to make this work. For now I'm not looking to add a plugin, but rather just hacking the core.
The point is to be able to manage a list of items, and rather than creating a component, I thought I'd reuse the page structure.
I'm planing on using the custom fields plugin
- I'll add a dropdown for the page names
- might add a separate field, to be able to pick which page template is used on
- otherwise just hardcode it
then add some javascript on the edit.php page that simply hides all the fields that are not being used based on the selection of the template dropdown
If anyone has some suggestions, I'd be happy to hear them.
I know this is outside of the scope of getSimple, but I think I can make this work.
As I haven't hacked the core or created plugins before I'm interested in hearing any feedback on how to make this work. For now I'm not looking to add a plugin, but rather just hacking the core.
The point is to be able to manage a list of items, and rather than creating a component, I thought I'd reuse the page structure.
I'm planing on using the custom fields plugin
- I'll add a dropdown for the page names
- might add a separate field, to be able to pick which page template is used on
- otherwise just hardcode it
then add some javascript on the edit.php page that simply hides all the fields that are not being used based on the selection of the template dropdown
If anyone has some suggestions, I'd be happy to hear them.