MF_PostTypePages::ManagePosttype PHP Method

ManagePosttype() public method

Magic Fields manage Page
public ManagePosttype ( )
    function ManagePosttype()
    {
        global $mf_domain, $wpdb;
        //Getting the  Custom types
        $sql = $wpdb->prepare("SELECT id,name FROM " . MF_TABLE_POSTTYPES_TAXONOMIES);
        $items = $wpdb->get_results($sql);
        $customtypes = "";
        foreach ($items as $key => $value) {
            $customtypes .= "<tr>" . "<td>" . $value->id . "</td>" . "<td>" . $value->name . "</td>" . "<td>Post</td>" . "<td>" . __('Edit') . "|" . __('Delete') . "</td>" . "</tr>";
        }
        print "<div class ='wrap'>" . "<div id='icon-options-general' class='icon32'></div>" . "<h2>" . __('Manage Custom Types', $mf_domain) . "</h2>" . "<table class='widefat'>" . "<thead>" . "<tr>" . "<th>" . __('ID', $mf_domain) . "</th>" . "<th>" . __('Post Type Name', $mf_domain) . "</th>" . "<th>" . __("Capability Type", $mf_domain) . "</th>" . "<th>" . __("Actions", $mf_domain) . "</th>" . "</tr>" . "</thead>" . "<tbody>" . $customtypes . "</tbody>" . "<tfoot>" . "<tr>" . "<th>" . __('ID', $mf_domain) . "</th>" . "<th>" . __('Post Type Name', $mf_domain) . "</th>" . "<th>" . __('Capability Type', $mf_domain) . "</th>" . "<th>" . __('Actions', __($mf_domain)) . "</th>" . "</tr>" . "</tfoot>" . "</table>" . "<p class='submit'>" . "<a href='admin.php?page=mf_posttypes&action=add' class='button tagadd'>" . __('Add a new Custom Type', $mf_domain) . "</a>" . "</p>" . "</div>";
    }