enabled ) {
if ( dynwid_sql_mode() ) {
echo '
';
_e('WARNING STRICT sql mode in effect. Dynamic Widgets might not work correctly. Please disable STRICT sql mode.', DW_L10N_DOMAIN);
echo '
';
}
// Actions
if ( isset($_GET['action']) && $_GET['action'] == 'edit' ) {
$dw_admin_script = '/dynwid_admin_edit.php';
$DW->loadModules();
} else {
$dw_admin_script = '/dynwid_admin_overview.php';
// Do some housekeeping
$lastrun = get_option('dynwid_housekeeping_lastrun');
if ( time() - $lastrun > DW_TIME_LIMIT ) {
$DW->housekeeping();
update_option('dynwid_housekeeping_lastrun', time());
}
}
require_once(dirname(__FILE__) . $dw_admin_script);
} else {
echo '
';
_e('Oops! Something went horribly wrong. Please reinstall Dynamic Widgets.', DW_L10N_DOMAIN);
echo '
';
}
?>