diff -r ac34de920762 -r eefe9ab7fe7c plugins/SpecialAdmin.php --- a/plugins/SpecialAdmin.php Fri Dec 28 16:52:03 2007 -0500 +++ b/plugins/SpecialAdmin.php Sun Dec 30 01:13:24 2007 -0500 @@ -1,8 +1,8 @@ ' . $lang->get('acphome_heading_main') . ''; + echo '
' . $lang->get('acphome_welcome_line1') . '
'; + echo '' . $lang->get('acphome_welcome_line2') . '
'; // Demo mode if ( defined('ENANO_DEMO_MODE') ) { - echo 'If you borked something up, or if you\'re done testing, you can reset this site. The site is reset automatically once every two hours. When a reset is performed, all custom modifications to the site are lost and replaced with default values.
'; + echo '' . $lang->get('acphome_msg_demo_body', array('reset_url' => makeUrlNS('Special', 'DemoReset', false, true))) . '
'; } // Check for the installer scripts if( ( file_exists(ENANO_ROOT.'/install.php') || file_exists(ENANO_ROOT.'/schema.sql') ) && !defined('ENANO_DEMO_MODE') ) { - echo 'Periodically, new releases of Enano will be made available. Click the button below to check for updates to Enano. During this process, a request will be sent to the Enano CMS server (germantown.enanocms.org) over HTTP for an XML file containing a list of the latest releases. No information about your Enano installation will be transmitted.
'; - echo ''; + echo '' . $lang->get('acphome_msg_updates_info', array('updates_url' => 'http://germantown.enanocms.org/meta/updates.xml')) . '
'; + echo ''; // Inactive users - $q = $db->sql_query('SELECT * FROM '.table_prefix.'logs WHERE log_type=\'admin\' AND action=\'activ_req\';'); - if($q) - if($db->numrows() > 0) + $q = $db->sql_query('SELECT time_id FROM '.table_prefix.'logs WHERE log_type=\'admin\' AND action=\'activ_req\';'); + if ( $q ) + { + if ( $db->numrows() > 0 ) { $n = $db->numrows(); - if($n == 1) $s = $n . ' user is'; - else $s = $n . ' users are'; - echo ''.print_r($stats,true).''); $c = 0; $cls = 'row2'; - echo '
Page | Hits |
---|
' . $lang->get('acphome_th_toppages_page') . ' | +' . $lang->get('acphome_th_toppages_hits') . ' | +
---|---|
'.$data['page_title'].' | '.$data['num_hits'].' | '; - echo '+ '.$data['page_title'].' | '.$data['num_hits'] + . ' | '; + echo ''; } - echo '
' . $lang->get('acphome_btn_seclog_full') . '
'; } @@ -278,15 +294,15 @@ } else { - echo 'Users and communication | +get('acpgc_heading_users'); ?> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
User account activation | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
get('acpgc_heading_activate'); ?> | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
- If you would like to require users to confirm their e-mail addresses by way of account activation, you can enable this behavior here. If this option is set to "None", users will be able to register and use this site without confirming their e-mail addresses. If this option is set to "User", users will automatically be sent e-mails upon registration with a link to activate their accounts. And lastly, if this option is set to "Admin", users' accounts will not be active until an administrator activates the account. - You may also disable registration completely if needed. - Note: because of abuse by project administrators, sending account activation e-mails will not work on SourceForge.net servers. + get('acpgc_activate_intro_line1'); ?> + get('acpgc_activate_intro_line2'); ?> + get('acpgc_activate_intro_sfnet_warning'); ?> |
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Account activation: | + | get('acpgc_field_activate'); ?> |
Disable registration '; - echo ''; - echo ''; - echo ''; + echo ' '; + echo ''; + echo ''; + echo ''; ?> |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Account lockouts | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
get('acpgc_heading_lockout'); ?> | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Configure Enano to prevent or restrict logins for a specified period of time if a user enters an incorrect password a specific number of times. | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
get('acpgc_lockout_intro'); ?> | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Lockout threshold: - How many times can a user enter wrong credentials before a lockout goes into effect? + | get('acpgc_field_lockout_threshold'); ?> + get('acpgc_field_lockout_threshold_hint'); ?> |
@@ -454,8 +530,8 @@ | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Lockout duration: - This is how long an account lockout should last, in minutes. + | get('acpgc_field_lockout_duration'); ?> + get('acpgc_field_lockout_duration_hint'); ?> |
@@ -463,34 +539,34 @@ | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Lockout policy: - What should be done when a lockout goes into effect? + | get('acpgc_field_lockout_policy'); ?> + get('acpgc_field_lockout_policy_hint'); ?> |
- - - + + + |
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Password strength | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
get('acpgc_heading_passstrength'); ?> | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
- Enable password strength analysis - This should be enabled in most cases. When this is enabled, a strength meter and a numerical score will be displayed wherever a password can be changed. + get('acpgc_field_passstrength_title'); ?> + get('acpgc_field_passstrength_hint'); ?> |
- + | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
- Minimum strength score - This is the lowest score a password will be allowed to have. -10 will allow any password. A score of under -3 is considered weak, under 1 is fair, under 4 is good, under 10 is strong, and 10 and above are very strong. The scale is open-ended. This only has an effect if the meter is enabled above. + get('acpgc_field_passminimum_title'); ?> + get('acpgc_field_passminimum_hint'); ?> |
@@ -499,87 +575,130 @@ - | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
E-mail sent from the site | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
E-mail sending method: Try using the built-in e-mail method first. If that doesn't work, you will need to enter valid SMTP information here. |
- - |
- ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
SMTP hostname: This option only applies to the external SMTP mode. |
- - | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
SMTP credentials: This option only applies to the external SMTP mode. |
- Username: - Password: |
- ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Avatars | -|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
- Avatars are small images that users can display on their profiles and in comments. + | + get('acpgc_heading_email'); ?> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
- Enable avatar support: - Supported formats are JPEG, PNG, and GIF™. + get('acpgc_field_email_method'); ?> + get('acpgc_field_email_method_hint'); ?> |
-
+
+
+ + + |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
- Maximum avatar file size: - For smaller sites, the highest value for this should be about 50KB, 51200. Larger sites with more visitors will likely want to use something much smaller, such as 10KB. + get('acpgc_field_email_smtp_hostname'); ?> + get('acpgc_field_email_smtp_hostname_hint'); ?> |
- /> bytes + | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
- Maximum avatar dimensions: - The format is width × height. Typically you want to have this square (the same width and height). These are only maximum dimensions; users are not prevented from having smaller images. + get('acpgc_field_email_smtp_auth'); ?> + get('acpgc_field_email_smtp_hostname_hint'); ?> |
- /> ×
- /> pixels
+ get('acpgc_field_email_smtp_username'); ?> + get('acpgc_field_email_smtp_password'); ?> + |
+ ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
get('acpgc_heading_avatars'); ?> | +|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
+ get('acpgc_avatars_intro'); ?> + + | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
+ get('acpgc_field_avatar_enable'); ?> + get('acpgc_field_avatar_enable_hint'); ?> + |
+ + | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
- Allow animated avatars: - If this is checked, users can upload APNG and Animated GIF™ avatars. Sometimes such images can be specifically made to be distracting, like rapidly flashing images. If this is unchecked, these formats will be blocked, and only still PNGs and GIFs will be allowed. + get('acpgc_field_avatar_max_filesize'); ?> + get('acpgc_field_avatar_max_filesize_hint'); ?> |
- + /> get('etc_unit_bytes'); ?> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
- Allowed upload methods: - + get('acpgc_field_avatar_max_dimensions'); ?> + get('acpgc_field_avatar_max_dimensions_hint'); ?> |
- - + /> × + /> get('etc_unit_pixels'); ?> |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
- Avatar storage directory: - This should be relative to your Enano root and should contain only alphanumeric characters and forward slashes, even if your server runs Windows. + get('acpgc_field_avatar_allow_anim_title'); ?> + get('acpgc_field_avatar_allow_anim_hint'); ?> + |
+ + + | +||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
+ get('acpgc_field_avatar_upload_methods'); ?> + + |
+
+
+
+ + + + |
+ ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
+ get('acpgc_field_avatar_directory'); ?> + get('acpgc_field_avatar_directory_hint'); ?> |
/>
@@ -593,90 +712,114 @@
No plugin specified. ';
+ }
+ else if ( !preg_match('/^[A-z0-9_-]+\.php$/', $_GET['plugin']) )
{
- case "enable":
- $q = $db->sql_query('INSERT INTO '.table_prefix.'logs(log_type,action,time_id,edit_summary,author,page_text) VALUES(\'security\',\'plugin_enable\',' . time() . ',\'' . $db->escape($_SERVER['REMOTE_ADDR']) . '\',"' . $db->escape($session->username) . '","' . $db->escape($_GET['plugin']) . '");');
- if ( !$q )
- $db->_die();
- setConfig('plugin_'.$_GET['plugin'], '1');
- break;
- case "disable":
- if ( defined('ENANO_DEMO_MODE') && strstr($_GET['plugin'], 'Demo') )
- {
- echo('Error disabling pluginThe demo lockdown plugin cannot be disabled in demo mode. '); - break; - } - if ( !in_array($_GET['plugin'], $plugins->system_plugins) ) - { - $q = $db->sql_query('INSERT INTO '.table_prefix.'logs(log_type,action,time_id,edit_summary,author,page_text) VALUES(\'security\',\'plugin_disable\',' . time() . ',\'' . $db->escape($_SERVER['REMOTE_ADDR']) . '\',"' . $db->escape($session->username) . '","' . $db->escape($_GET['plugin']) . '");'); + echo 'Hacking attempt ';
+ }
+ else
+ {
+ $plugin =& $_GET['plugin'];
+ switch($_GET['action'])
+ {
+ case "enable":
+ $q = $db->sql_query('INSERT INTO '.table_prefix.'logs(log_type,action,time_id,edit_summary,author,page_text) VALUES(\'security\',\'plugin_enable\',' . time() . ',\'' . $db->escape($_SERVER['REMOTE_ADDR']) . '\',"' . $db->escape($session->username) . '","' . $db->escape($_GET['plugin']) . '");');
if ( !$q )
$db->_die();
- setConfig('plugin_'.$_GET['plugin'], '0');
- }
- else
- {
- echo('Error disabling pluginThe plugin you selected cannot be disabled because it is a system plugin. '); - } - break; + setConfig("plugin_$plugin", '1'); + break; + case "disable": + if ( defined('ENANO_DEMO_MODE') && strstr($_GET['plugin'], 'Demo') ) + { + echo('' . $lang->get('acppl_err_heading') . '+' . $lang->get('acppl_err_demo_plugin') . ' '); + break; + } + if ( !in_array($plugin, $plugins->system_plugins) ) + { + $q = $db->sql_query('INSERT INTO '.table_prefix.'logs(log_type,action,time_id,edit_summary,author,page_text) VALUES(\'security\',\'plugin_disable\',' . time() . ',\'' . $db->escape($_SERVER['REMOTE_ADDR']) . '\',"' . $db->escape($session->username) . '","' . $db->escape($_GET['plugin']) . '");'); + if ( !$q ) + $db->_die(); + setConfig("plugin_$plugin", '0'); + } + else + { + echo '' . $lang->get('acppl_err_heading') . '+' . $lang->get('acppl_err_system_plugin') . ' '; + } + break; + } } } $dir = './plugins/'; @@ -896,23 +1152,37 @@ $thelist[$file]['auth'] = $f[3]; $thelist[$file]['vers'] = $f[4]; $thelist[$file]['aweb'] = $f[5]; + + if ( preg_match('/^[a-z0-9]+_[a-z0-9_]+$/', $thelist[$file]['name']) ) + $thelist[$file]['name'] = $lang->get($thelist[$file]['name']); + + if ( preg_match('/^[a-z0-9]+_[a-z0-9_]+$/', $thelist[$file]['desc']) ) + $thelist[$file]['desc'] = $lang->get($thelist[$file]['desc']); + } } closedir($dh); } else { - echo 'The plugins/ directory could not be opened. ';
+ echo '' . $lang->get('acppl_err_open_dir') . ' ';
return;
}
}
else
{
- echo 'The plugins/ directory is missing from your Enano installation. ';
+ echo '' . $lang->get('acppl_err_missing_dir') . ' ';
return;
}
echo('
' . $lang->get('adm_err_not_auth_title') . ''; + echo '' . $lang->get('adm_err_not_auth_body', array( 'login_link' => $login_link )) . ' '; + return; + } + + echo 'Page management'; + + if ( isset($_POST['search']) || isset($_POST['select']) || ( isset($_GET['source']) && $_GET['source'] == 'ajax' ) ) + { + // The object of the game: using only the text a user entered, guess the page ID and namespace. *sigh* I HATE writing search algorithms... + $source = ( isset($_GET['source']) ) ? $_GET['source'] : false; + if ( $source == 'ajax' ) + { + $_POST['search'] = true; + $_POST['page_url'] = $_GET['page_id']; + } + if ( isset($_POST['search']) ) + { + $pid = $_POST['page_url']; + } + elseif ( isset($_POST['select']) ) + { + $pid = $_POST['page_force_url']; + } + else + { + echo 'Internal error selecting page search terms'; + return false; + } + // Look for a namespace prefix in the urlname, and assign a different namespace, if necessary + $k = array_keys($paths->nslist); + for ( $i = 0; $i < sizeof($paths->nslist); $i++ ) + { + $ln = strlen($paths->nslist[$k[$i]]); + if(substr($pid, 0, $ln) == $paths->nslist[$k[$i]]) + { + $ns = $k[$i]; + $page_id = substr($pid, $ln, strlen($pid)); + } + } + // The namespace is in $ns and the page name or ID (we don't know which yet) is in $page_id + // Now, iterate through $paths->pages searching for a page with this name or ID + for ( $i = 0; $i < sizeof($paths->pages) / 2; $i++ ) + { + if ( !isset($final_pid) ) + { + if ( $paths->pages[$i]['urlname_nons'] == str_replace(' ', '_', $page_id) ) + { + $final_pid = str_replace(' ', '_', $page_id); + } + else if ( $paths->pages[$i]['name'] == $page_id ) + { + $final_pid = $paths->pages[$i]['urlname_nons']; + } + else if ( strtolower($paths->pages[$i]['urlname_nons']) == strtolower(str_replace(' ', '_', $page_id)) ) + { + $final_pid = $paths->pages[$i]['urlname_nons']; + } + else if ( strtolower($paths->pages[$i]['name']) == strtolower(str_replace('_', ' ', $page_id)) ) + { + $final_pid = $paths->pages[$i]['urlname_nons']; + } + if ( isset($final_pid) ) + { + $_POST['name'] = $paths->pages[$i]['name']; + $_POST['urlname'] = $paths->pages[$i]['urlname_nons']; + } + } + } + if ( !isset($final_pid) ) + { + echo 'The page you searched for cannot be found. Back'; + return false; + } + $_POST['namespace'] = $ns; + $_POST['old_namespace'] = $ns; + $_POST['page_id'] = $final_pid; + $_POST['old_page_id'] = $final_pid; + if ( !isset($paths->pages[$paths->nslist[$_POST['namespace']].$_POST['urlname']]) ) + { + echo 'The page you searched for cannot be found. Back'; + return false; + } + } + + if ( isset($_POST['page_id']) && isset($_POST['namespace']) && !isset($_POST['cancel']) ) + { + $cpage = $paths->pages[$paths->nslist[$_POST['old_namespace']].$_POST['old_page_id']]; + if(isset($_POST['submit'])) + { + switch(true) + { + case true: + // Create a list of things to update + $page_info = Array( + 'name'=>$_POST['name'], + 'urlname'=>sanitize_page_id($_POST['page_id']), + 'namespace'=>$_POST['namespace'], + 'special'=>isset($_POST['special']) ? '1' : '0', + 'visible'=>isset($_POST['visible']) ? '1' : '0', + 'comments_on'=>isset($_POST['comments_on']) ? '1' : '0', + 'protected'=>isset($_POST['protected']) ? '1' : '0' + ); + + $updating_urlname_or_namespace = ( $page_info['namespace'] != $cpage['namespace'] || $page_info['urlname'] != $cpage['urlname_nons'] ); + + if ( !isset($paths->nslist[ $page_info['namespace'] ]) ) + { + echo 'The namespace you selected is not properly registered. ';
+ break;
+ }
+ if ( isset($paths->pages[ $paths->nslist[$page_info['namespace']] . $page_info[ 'urlname' ] ]) && $updating_urlname_or_namespace )
+ {
+ echo 'There is already a page that exists with that URL string and namespace. ';
+ break;
+ }
+ // Build the query
+ $q = 'UPDATE '.table_prefix.'pages SET ';
+ $k = array_keys($page_info);
+ foreach($k as $c)
+ {
+ $q .= $c.'=\''.$db->escape($page_info[$c]).'\',';
+ }
+ $q = substr($q, 0, strlen($q)-1);
+ // Build the WHERE statements
+ $q .= ' WHERE ';
+ $k = array_keys($cpage);
+ if ( !isset($cpage) )
+ die('[internal] no cpage');
+ foreach($k as $c)
+ {
+ if($c != 'urlname_nons' && $c != 'urlname' && $c != 'really_protected')
+ {
+ $q .= $c.'=\''.$db->escape($cpage[$c]).'\' AND ';
+ }
+ else if($c == 'urlname')
+ {
+ $q .= $c.'=\''.$db->escape($cpage['urlname_nons']).'\' AND ';
+ }
+ }
+ // Trim off the last " AND " and append a semicolon
+ $q = substr($q, 0, strlen($q)-5) . ';';
+ // Send the completed query to MySQL
+ $e = $db->sql_query($q);
+ if(!$e) $db->_die('The page data could not be updated.');
+ // Update any additional tables
+ $q = Array(
+ 'UPDATE '.table_prefix.'categories SET page_id=\''.$page_info['urlname'].'\',namespace=\''.$page_info['namespace'].'\' WHERE page_id=\'' . $db->escape($_POST['old_page_id']) . '\' AND namespace=\'' . $db->escape($_POST['old_namespace']) . '\';',
+ 'UPDATE '.table_prefix.'comments SET page_id=\''.$page_info['urlname'].'\',namespace=\''.$page_info['namespace'].'\' WHERE page_id=\'' . $db->escape($_POST['old_page_id']) . '\' AND namespace=\'' . $db->escape($_POST['old_namespace']) . '\';',
+ 'UPDATE '.table_prefix.'logs SET page_id=\''.$page_info['urlname'].'\',namespace=\''.$page_info['namespace'].'\' WHERE page_id=\'' . $db->escape($_POST['old_page_id']) . '\' AND namespace=\'' . $db->escape($_POST['old_namespace']) . '\';',
+ 'UPDATE '.table_prefix.'page_text SET page_id=\''.$page_info['urlname'].'\',namespace=\''.$page_info['namespace'].'\' WHERE page_id=\'' . $db->escape($_POST['old_page_id']) . '\' AND namespace=\'' . $db->escape($_POST['old_namespace']) . '\';',
+ 'UPDATE '.table_prefix.'acl SET page_id=\''.$page_info['urlname'].'\',namespace=\''.$page_info['namespace'].'\' WHERE page_id=\'' . $db->escape($_POST['old_page_id']) . '\' AND namespace=\'' . $db->escape($_POST['old_namespace']) . '\';'
+ );
+ foreach($q as $cq)
+ {
+ $e = $db->sql_query($cq);
+ if(!$e) $db->_die('Some of the additional tables containing page information could not be updated.');
+ }
+ // Update $cpage
+ $cpage = $page_info;
+ $cpage['urlname_nons'] = $cpage['urlname'];
+ $cpage['urlname'] = $paths->nslist[$cpage['namespace']].$cpage['urlname'];
+ $_POST['old_page_id'] = $page_info['urlname'];
+ $_POST['old_namespace'] = $page_info['namespace'];
+ echo 'Your changes have been saved. ';
+ break;
+ }
+ } elseif(isset($_POST['delete'])) {
+ $q = Array(
+ 'DELETE FROM '.table_prefix.'categories WHERE page_id=\'' . $db->escape($_POST['old_page_id']) . '\' AND namespace=\'' . $db->escape($_POST['old_namespace']) . '\';',
+ 'DELETE FROM '.table_prefix.'comments WHERE page_id=\'' . $db->escape($_POST['old_page_id']) . '\' AND namespace=\'' . $db->escape($_POST['old_namespace']) . '\';',
+ 'DELETE FROM '.table_prefix.'logs WHERE page_id=\'' . $db->escape($_POST['old_page_id']) . '\' AND namespace=\'' . $db->escape($_POST['old_namespace']) . '\';',
+ 'DELETE FROM '.table_prefix.'page_text WHERE page_id=\'' . $db->escape($_POST['old_page_id']) . '\' AND namespace=\'' . $db->escape($_POST['old_namespace']) . '\';',
+ );
+ foreach($q as $cq)
+ {
+ $e = $db->sql_query($cq);
+ if(!$e) $db->_die('Some of the additional tables containing page information could not be updated.');
+ }
+
+ if(!$db->sql_query(
+ 'DELETE FROM '.table_prefix.'pages WHERE urlname="'.$db->escape($_POST['old_page_id']).'" AND namespace="'.$db->escape($_POST['old_namespace']).'";'
+ )) $db->_die('The page could not be deleted.');
+ echo 'This page has been deleted. ';
+ return;
+ }
+ $url = makeUrlNS('Special', 'Administration', 'module='.$paths->cpage['module'], true);
+ echo ' |