options = $GLOBALS['EFL_options']; $this->defaults = array( 'home' => array(FALSE, '%site_title% Comments'), 'comments' => array(TRUE, 'Comments: %title%'), 'category' => array(TRUE, 'Category: %title%'), 'tag' => array(TRUE, 'Tag: %title%'), 'author' => array(TRUE, 'Author: %title%'), 'search' => array(TRUE, 'Search: %title%') ); $this->args = array( 'page_title' => 'Extra Feed Links', 'short_title' => 'Extra Feed Links', 'page_slug' => 'extra-feed-links' ); $this->nonce = 'efl-settings'; } protected function form_handler() { if ( empty($_POST['action']) ) return false; check_admin_referer($this->nonce); // Update options if ( 'Save Changes' == $_POST['action'] ) { foreach (array_keys($this->options->get()) as $name) { $new_format[$name][0] = $_POST['show-' . $name]; $new_format[$name][1] = $_POST['format-' . $name]; } $this->options->update($new_format); $this->admin_msg('Settings saved.'); } // Reset options if ( 'Reset' == $_POST['action'] ) { $this->options->reset(); $this->admin_msg('Settings reset.'); } } public function page_head() { ?> page_header(); ?>

The table below allows you to select which page types get an extra header link and the format of the link text.

nonce); ?> options->get() as $name => $value) { ?>
Page type Text format
input(array( 'type' => 'checkbox', 'names' => 'show-'.$name, 'desc_pos' => 'none' ), array('show-'.$name => $value[0])); ?> input(array( 'type' => 'text', 'names' => 'format-'.$name, 'desc_pos' => 'none' ), array('format-'.$name => $value[1])); ?>

Available substitution tags:

page_footer(); } }