• hi
    i have a page called userinfo.php located in the wordpress folder.
    when i call this page i want to display some information from a table i created called WP_M_PROFILE

    i try to get results from the table but nothing comes back;

    im using

    <?php
    include (‘wp-blog-header.php’);
    header(“HTTP/1.0 200 OK”);
    global $wpdb;
    $ddatequery = $wpdb->get_row(“SELECT * FROM $wpdb->WP_M_PROFILE WHERE M_USERID = 4”);
    echo $ddatequery->M_DUEDATE;

    ?>

    the table is named WP_M_PROFILE and M_USERID, M_DUEDATE are fields in the table

    what am i doin wrong

The topic ‘select from a new table’ is closed to new replies.