Changeset 9738


Ignore:
Timestamp:
Mar 17, 2011, 12:51:38 AM (10 years ago)
Author:
patdenice
Message:

New admin URL.

Location:
extensions/PWG_Stuffs/trunk
Files:
5 edited
1 moved

Legend:

Unmodified
Added
Removed
  • extensions/PWG_Stuffs/trunk/admin.php

    r9736 r9738  
    88include_once(PHPWG_ROOT_PATH.'admin/include/tabsheet.class.php');
    99include_once(STUFFS_PATH . 'functions.inc.php');
    10 $my_base_url = get_admin_plugin_menu_link(__FILE__);
     10$my_base_url = get_root_url().'admin.php?page=plugin-'.STUFFS_DIR;
    1111
    1212// +-----------------------------------------------------------------------+
     
    1616
    1717$tabsheet = new tabsheet();
    18 $tabsheet->add('manage', l10n('stuffs_mods_management'), $my_base_url.'&tab=manage');
     18$tabsheet->add('manage', l10n('stuffs_mods_management'), $my_base_url.'-manage');
    1919if ($page['tab'] == 'add_module')
    2020{
    21   $tabsheet->add('add_module', l10n('stuffs_add_mod'), $my_base_url.'&tab=add_module&path='.$_GET['path']);
     21  $tabsheet->add('add_module', l10n('stuffs_add_mod'), $my_base_url.'-add_module&path='.$_GET['path']);
    2222}
    2323else
    2424{
    25   $tabsheet->add('new', l10n('stuffs_add_mod'), $my_base_url.'&tab=new');
     25  $tabsheet->add('new', l10n('stuffs_add_mod'), $my_base_url.'-new');
    2626}
    2727if ($page['tab'] == 'edit_module')
    2828{
    29   $tabsheet->add('edit_module', l10n('stuffs_edit_mod'), $my_base_url.'&tab=edit_module&edit='.$_GET['edit']);
     29  $tabsheet->add('edit_module', l10n('stuffs_edit_mod'), $my_base_url.'-edit_module&edit='.$_GET['edit']);
    3030}
    31 $tabsheet->add('config', l10n('Configuration'), $my_base_url.'&tab=config');
     31$tabsheet->add('config', l10n('Configuration'), $my_base_url.'-config');
    3232$tabsheet->select($page['tab']);
    3333$tabsheet->assign();
  • extensions/PWG_Stuffs/trunk/admin/add_module.inc.php

    r9737 r9738  
    9393        pwg_query($query);
    9494      }
    95       redirect(PHPWG_ROOT_PATH.'admin.php?page=plugin&section=' . STUFFS_DIR . '%2Fadmin%2Fadmin.php');
     95      redirect($my_base_url);
    9696    }
    9797  }
  • extensions/PWG_Stuffs/trunk/admin/manage.inc.php

    r9737 r9738  
    99{
    1010  pwg_query('DELETE FROM ' . STUFFS_TABLE . ' WHERE id = ' . $_GET['del'] . ' LIMIT 1;');
    11   redirect(PHPWG_ROOT_PATH.'admin.php?page=plugin&section=' . STUFFS_DIR . '%2Fadmin%2Fadmin.php');
     11  redirect($my_base_url);
    1212}
    1313
     
    8585    'WIDTH' => $module['width'],
    8686    'ID' => $module['id'],
    87     'U_EDIT' => PHPWG_ROOT_PATH . 'admin.php?page=plugin&section=' . STUFFS_DIR . '%2Fadmin%2Fadmin.php&tab=edit_module&edit='.$module['id'],
    88     'U_DELETE' => PHPWG_ROOT_PATH . 'admin.php?page=plugin&section=' . STUFFS_DIR . '%2Fadmin%2Fadmin.php&del=' . $module['id'],
     87    'U_EDIT' => $my_base_url.'-edit_module&edit='.$module['id'],
     88    'U_DELETE' => $my_base_url.'&del=' . $module['id'],
    8989    'MISSING' => $missing_message,
    9090    )
  • extensions/PWG_Stuffs/trunk/admin/new.inc.php

    r9737 r9738  
    1212  else
    1313  {
    14     redirect(PHPWG_ROOT_PATH.'admin.php?page=plugin&section=' . STUFFS_DIR . '%2Fadmin%2Fadmin.php&tab=add_module&path=' . urlencode($_POST['module']));
     14    redirect($my_base_url.'-add_module&path=' . urlencode($_POST['module']));
    1515  }
    1616}
  • extensions/PWG_Stuffs/trunk/class.inc.php

    r9737 r9738  
    117117        if (is_admin())
    118118        {
    119           $block['U_EDIT'] = PHPWG_ROOT_PATH.'admin.php?page=plugin&section='.STUFFS_DIR.'%2Fadmin%2Fadmin.php&tab=edit_module&edit='.$module['id'].'&redirect='.urlencode(urlencode($_SERVER['REQUEST_URI']));
     119          $block['U_EDIT'] = get_root_url().'admin.php?page=plugin-'.STUFFS_DIR.'-edit_module&edit='.$module['id'].'&redirect='.urlencode(urlencode($_SERVER['REQUEST_URI']));
    120120        }
    121121        $this->set_tpl_block($block, $module);
  • extensions/PWG_Stuffs/trunk/main.inc.php

    r9736 r9738  
    2929  array_push($menu, array(
    3030    'NAME' => 'PWG Stuffs',
    31     'URL' => get_admin_plugin_menu_link(STUFFS_PATH . 'admin/admin.php')
     31    'URL' => get_root_url().'admin.php?page=plugin-'.STUFFS_DIR
    3232    )
    3333  );
Note: See TracChangeset for help on using the changeset viewer.