/** * Meta Box: Extra Settings */ public function call_box_admin_settings() { echo $this->form->set_current_option('screen')->open_form(); ?> <fieldset class="options"> <table class="form-table"> <tr> <th><?php $this->_e('Admin menu position'); ?> <?php echo $this->tooltip_help('Change the menu position of this plugin in "Screen Options".'); ?> </th> <td><label> <?php echo $this->form->select('menu_position', array('admin.php' => 'Main menu', 'index.php' => $this->__('Subitem of Dashboard'), 'edit.php' => $this->__('Subitem of Posts'), 'upload.php' => $this->__('Subitem of Media'), 'link-manager.php' => $this->__('Subitem of Links'), 'edit.php?post_type=page' => $this->__('Subitem of Pages'), 'edit-comments.php' => $this->__('Subitem of Comments'), 'themes.php' => $this->__('Subitem of Appearance'), 'plugins.php' => $this->__('Subitem of Plugins'), 'users.php' => $this->__('Subitem of Users'), 'tools.php' => $this->__('Subitem of Tools'), 'options-general.php' => $this->__('Subitem of Settings'))); ?> </label></td> </tr> </table> </fieldset> <?php echo $this->form->submit(); echo $this->form->close_form(); }
/** * Meta Box: Extra Settings */ public function call_box_extra_settings() { echo $this->form->set_current_option( 'extra' )->open_form(); ?> <fieldset class="options"> <table class="form-table"> <tr> <th style="width:250px;"><?php $this->_e( 'Solving problems' ) ?> <?php echo $this->tooltip_help( 'Some options to try when a problem occurs. These options can also cause other problems, so be carefull.' ) ?></th> <td><label><?php echo $this->form->checkbox( 'fix_js', 1 ); ?> <span><?php $this->_e( 'Replacing <code></a></code> with <code><\/a></code> in JavaScript code.' ) ?></span></label> <?php echo $this->tooltip_help( 'By replacing </a> with <\/a> in JavaScript code these tags will not be processed by the plugin.' ) ?> </td> </tr> <tr> <th style="width:250px;"><?php $this->_e( 'Use phpQuery library' ) ?> <?php echo $this->tooltip_help( 'Using phpQuery library for manipulating links. This option is experimental.' ) ?></th> <td><label><?php echo $this->form->checkbox( 'phpquery', 1 ); ?> <span><?php $this->_e( 'Use phpQuery for parsing document.' ) ?></span> <span class="description">(Test it first!)</span></label> </td> </tr> <tr class="filter_excl_sel" <?php echo ( $this->form->value( 'phpquery' ) ) ? '' : 'style="display:none;"'; ?>> <th><?php $this->_e( 'Do NOT apply settings on...' ) ?> <?php echo $this->tooltip_help( 'The external links of these selection will be excluded for the settings of this plugin. Define the selection by using CSS selectors.' ) ?></th> <td><label><?php echo $this->form->textarea( 'filter_excl_sel' ); ?> <span class="description"><?php _e( 'Define selection by using CSS selectors, f.e.: <code>.excl-ext-link, .entry-title, #comments-title</code> (look <a href="http://code.google.com/p/phpquery/wiki/Selectors" target="_blank">here</a> for available selectors).' ) ?></span></label> </td> </tr> <tr> <th style="width:250px;"><?php $this->_e( 'Plugin menu position' ) ?> <?php echo $this->tooltip_help( 'Change the menu position of this plugin in "Screen Options".' ) ?></th> <td><label><a id="admin_menu_position" href="#"><?php _e( 'Change menu position' ) ?></a></label> </td> </tr> </table> </fieldset> <?php echo $this->form->submit(); echo $this->form->close_form(); }
/** * Deactivation plugin callback */ public function call_deactivation() { $this->form->delete_options(); }