function amr_meta_overview_page()
{
    /* the main setting spage  - num of lists and names of lists */
    global $amain;
    global $aopt;
    if (empty($amain)) {
        $amain = ausers_get_option('amr-users-main');
    }
    //amr_meta_main_admin_header('Overview of configured user lists'.' '.AUSERS_VERSION);
    amr_meta_admin_headings($plugin_page = '');
    // does the nonce check etc
    if (isset($_POST['import-list'])) {
        amr_meta_handle_import();
    } elseif (isset($_POST['action']) and $_POST['action'] == "save") {
        if (!empty($_POST['reset'])) {
            amr_meta_reset();
            return;
        } elseif (isset($_POST['export-list'])) {
            amr_meta_handle_export();
        } else {
            amrmeta_validate_overview();
        }
    } else {
        amr_handle_copy_delete();
    }
    if (!ameta_cache_enable() or !ameta_cachelogging_enable()) {
        echo '<h2>' . __('Problem creating DB tables', 'amr-users') . '</h2>';
    }
    if (!isset($amain['checkedpublic'])) {
        echo '<input type="hidden" name="checkedpublic" value="true"/>';
    }
    echo '<h2>' . __('Overview &amp; tools', 'amr-users') . '</h2>';
    echo PHP_EOL . '<div class="wrap"><!-- one wrap -->' . PHP_EOL;
    if (!isset($amain['names'])) {
        echo '<h2>' . __('There is a problem - Some overview list settings got lost somehow.  Try reset options.', 'amr-users') . '</h2>';
    } else {
        amr_meta_overview_onelist_headings();
        amr_meta_overview_onelist_headings_middle();
        foreach ($amain['names'] as $i => $name) {
            //for ($i = 1; $i <= $amain['no-lists']; $i++)	{
            amr_meta_overview_onelist_settings($i);
            echo '</tr>';
        }
        amr_meta_overview_onelist_headings_end();
    }
    echo '</div><!-- end of one wrap --> <br />' . PHP_EOL;
    //echo '<div style="clear: both; float:right; padding-right:100px;" class="submit">';
    echo ausers_submit();
    echo '<input class="button-primary" type="submit" name="addnew" value="' . __('Add new', 'amr-users') . '" />';
    amr_list_export_form();
    echo ausers_form_end();
    amr_list_import_form();
    // different form
}
function amr_meta_general_page()
{
    global $aopt;
    global $amr_nicenames;
    global $pluginpage;
    global $amain;
    $tabs['settings'] = __('General', 'amr-users');
    //$tabs['fields'] 	= __('Fields &amp; Nice Names', 'amr-users');
    //$tabs['overview']	= __('Overview &amp; tools', 'amr-users');
    if (isset($_GET['tab'])) {
        if ($_GET['tab'] == 'fields') {
            //nlr
            amr_users_do_tabs($tabs, 'fields');
            amr_meta_nice_names_page();
            return;
        } elseif ($_GET['tab'] == 'overview') {
            //nlr
            amr_users_do_tabs($tabs, 'overview');
            amr_meta_overview_page();
            return;
        } else {
            amr_users_do_tabs($tabs, 'settings');
        }
    } else {
        amr_users_do_tabs($tabs, 'settings');
    }
    //amr_meta_main_admin_header('General');
    amr_meta_admin_headings();
    // does the nonce check etc
    if (isset($_POST['action']) and $_POST['action'] == "save") {
        if (isset($_POST['reset'])) {
            amr_meta_reset();
            return;
        } else {
            amrmeta_validate_mainoptions();
        }
    }
    amr_meta_general_page_display();
    /* else do the main header page */
}