Reputation: 1129
I have been researching wordpress theme options page/panel.
Quite a few of them put everything in the function php but I want it to be more organised and put into a separate file called something like - theme-options.php
I dont want to create it as a plugin because I want it to be included automatic in the themes files.
Am i thinking that you would create the file(s) and then use wordpress hooks/actions to include the file on theme activation.
Any help would be appreciated. I have created several themes for individuals and myself which I have always made as automated as possible to limit the amount of possible errors and make them as effortless as possible but the next step would be theme options to easily add new logo, header image and colour scheme.
Upvotes: 0
Views: 105
Reputation: 591
Add an include to the top of your functions.php file with a path to the theme-options.php:
// Load our other customization modules
include(TEMPLATEPATH . '/includes/theme-options.php');
And then do all your theme options/customization panels in that php file.
Upvotes: 1