Admin Upload Utility in ModCP
-----
| Author | Message | |
|---|---|---|
|
Exorcizer |
||
| Sun Oct 01, 2006 8:24 pm Post subject: Admin Upload Utility in ModCP | ||
|
I installed both the Admin Upload Utility, and the ModCP, but I want the Admin Upload Utility to be available in the ModCP. I added the module to the ModCP, but when I click the link in the Moderator CP, it brings me a blank page.
Any ideas how I can make it work (or if its even possible)? |
||
|
Thoul |
||
| Mon Oct 02, 2006 2:42 pm Post subject: re: Admin Upload Utility in ModCP | ||
|
Did you make any changes to admin_upload.php? If so, can you post your version of the file, please?
|
||
|
Exorcizer |
||
| Mon Oct 02, 2006 4:17 pm Post subject: | ||
|
Yes, I made so change like they told me too in the modcp files that told me how to add a new module. Here are the edited part of my file:
Code: // Set basic paths.
// Might be useful for Nuke porters? $phpbb_adm_path = './'; $phpbb_root_path = $phpbb_adm_path . '../'; define('AUU_PATH', $phpbb_root_path . 'mods/uploader/'); define('AUU_ALL', 'all'); // Name of "list all modules" type // Show links to each upload module in admin navigation menu. // This feature is not compatible with PHP 5, so set this to TRUE // only when using PHP 4. define('SHOW_ALL_NAV', FALSE); if( !empty($setmodules) ) { $filename = basename(__FILE__); if (check_perms('General', 'Upload_Utility')) $modcp_module['General']['Upload_Utility'] = $filename; if( SHOW_ALL_NAV ) { $modules_dir = @opendir(AUU_PATH); while( $module_file = @readdir($modules_dir) ) { if( preg_match('/^module_(.*?)\.' . $phpEx . '$/', $module_file) ) { include_once(AUU_PATH . $module_file); } } @closedir($modules_dir); } return; } // Check for required version of PHP. if( phpversion() < '4.1.0' ) { die('Sorry, but this add-on requires PHP version 4.1.0 or later to operate. An older version seems to be installed on your server. Talk to your webhost about upgrading their PHP installation.'); } define('IN_PHPBB', TRUE); // Pull php extension if not already done. require_once($phpbb_root_path . 'extension.inc'); // Enable/disable the Module if (!check_perms('General', 'Upload_Utility')) { // End of Activation $message = $lang['Module_disabled'] . '<br /><br />' . sprintf($lang['Click_return_admin_index'], '<a href="' . append_sid('index.' . $phpEx . '?pane=right') . '">', '</a>'); message_die(GENERAL_MESSAGE, $message); } Code: if( $auu->module == AUU_ALL )
{ // List all installed modules $template->set_filenames(array( 'body' => 'modcp/uploader_list.html') ); Code: // Begin building the main part of the page. Header was done way up top.
$template->set_filenames(array( 'body' => 'modcp/uploader_body.html') ); Code: $template->pparse('body');
include('./page_footer_mod.' . $phpEx); // I didn't hear no fat lady!! ?> |
||
|
Thoul |
||
| Mon Oct 02, 2006 8:43 pm Post subject: re: Admin Upload Utility in ModCP | ||
|
Ok, remove all the changes in the first part you posted and see how that does. When I try that, I get a couple of undefined function errors from the check_perms stuff. It also changes the Upload Utility link in a way that would create another error.
|
||
|
Exorcizer |
||
| Mon Oct 02, 2006 9:30 pm Post subject: re: Admin Upload Utility in ModCP | ||
|
That worked fine for me (well, for now), thx alot! If I get some othe rproblems, I'll contact you
|
||
Page 1 of 1