Great work
-
First of all, your code rocks; nice work ??
I found this theme while developing a standard interface for themes. I started with something like this:<?php /** * Interface WP_Theme. * * We can be add two extras methods: get and set generic for class, or for each groups of methods: * getStyles(), setStyles(), getFilters(), addFilters() etc. */ interface WP_Theme { # Attrs: private $_themeData; private $_styles; private $_scripts; private $_actions; private $_filters; private $_sidebars; private $_widgets; // ?? private $_plugins; private $_registry; // (Optional). Example: Zend Registry instead CONSTANTS. // Global public function getThemeData(); public function setThemeData($file); // Registry, note this: custom Zend_Registry public function getRegistry(); public function setRegistry(Zend_Registry $registry); // Force type // Styles public function addThemeStyle(); // Force WP_Styles? public function removeThemeStyle(); // Scripts public function addThemeScript(); // Force WP_Scripts? public function removeThemeScript(); // Actions public function addThemeAction(); public function removeThemeAction(); // Filters public function addThemeFilter(); public function removeThemeFilter(); // Sidebars public function addThemeSidebars(array $sidebars); public function removeThemeSidebars(array $sidebars); // Widgets public function addThemeWidget(WP_Widget $widgets); public function removeThemeWidget(WP_Widget $widgets); // Prepare: Setup or init methods. public function prepareTheme(); // Runs... public function runBackend(); public function runFrontend(); }
Time for proposals -ideas- for WordPress standar WP_Theme interface?
Viewing 4 replies - 1 through 4 (of 4 total)
Viewing 4 replies - 1 through 4 (of 4 total)
- The topic ‘Great work’ is closed to new replies.