function admin_form_end($button = null, $table = true)
 {
     if ($button === null) {
         $button = __('Import Now', 'seo-ultimate');
     }
     parent::admin_form_end($button, $table);
     $this->print_message('warning', sprintf(__('The import cannot be undone. It is your responsibility to <a href="%s" target="_blank">backup your database</a> before proceeding!', 'seo-ultimate'), suwp::get_backup_url()));
 }
Пример #2
0
 function get_admin_url($key = false)
 {
     if ($key) {
         return parent::get_admin_url($key);
     }
     if (is_network_admin()) {
         return false;
     }
     return 'widgets.php';
 }
 /**
  * Compares two modules to determine which of the two should be displayed first on the menu.
  * Sorts by menu position first, and title second.
  * Works as a uasort() callback.
  * 
  * @since 0.1
  * @uses SU_Module::get_menu_pos()
  * @uses SU_Module::get_menu_title()
  * 
  * @param SU_Module $a The first module to compare.
  * @param SU_Module $b The second module to compare.
  * @return int This will be -1 if $a comes first, or 1 if $b comes first.
  */
 function module_sort_callback($a, $b)
 {
     if ($a->get_menu_pos() == $b->get_menu_pos()) {
         return strcmp($a->get_menu_title(), $b->get_menu_title());
     }
     return $a->get_menu_pos() < $b->get_menu_pos() ? -1 : 1;
 }
 /**
  * Compares two modules to determine which of the two should be displayed first on the parent page.
  * Sorts by child order first, and title second.
  * Works as a uasort() callback.
  * 
  * @since 1.5
  * @uses SU_Module::get_child_order()
  * @uses SU_Module::get_module_subtitle()
  * 
  * @param SU_Module $a The first module to compare.
  * @param SU_Module $b The second module to compare.
  * @return int This will be -1 if $a comes first, or 1 if $b comes first.
  */
 function module_sort_callback($a, $b)
 {
     if ($a->get_child_order() == $b->get_child_order()) {
         return strcmp($a->get_module_subtitle(), $b->get_module_subtitle());
     }
     return $a->get_child_order() < $b->get_child_order() ? -1 : 1;
 }
Пример #5
0
 function get_jlsuggest_box($name, $value, $params = '', $placeholder = '')
 {
     if (empty($value) && $this->jlsuggest_box_post_id && current_theme_supports('post-thumbnails') && ($thumbnail_id = get_post_thumbnail_id($this->jlsuggest_box_post_id))) {
         $selected_post = get_post($thumbnail_id);
         $placeholder = sprintf(__('Featured Image: %s', 'seo-ultimate'), $selected_post->post_title);
     }
     return parent::get_jlsuggest_box($name, $value, $params, $placeholder);
 }