Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author nsp-code

    (@nsp-code)

    Hello,
    If it use the get_terms() function it should work fine. As alternative please check with advanced version.

    Thanks

    Thread Starter kmcminn

    (@kmcminn)

    Hi,

    Thank you for your response. How where can I check to see if it uses the get_terms() function? I’m pretty sure it does, but I’d like to make sure first before looking at the advanced version.

    Edit: I think I found it. Does this look like the correct portion of code?

    <select id="game-filter-platform" name="system" style="width: 110px">
    <option value="">All Systems</option>
    <?php foreach(gamedb_get_systems() as $k => $v) : ?>
    <option value="<?php echo $k ?>"<?php selected($k, get_query_var('system')) ?>><?php echo $v ?></option>
    <?php endforeach ?>
    </select>
    Plugin Author nsp-code

    (@nsp-code)

    Hi,
    Yes this appear to be the code, i suggest so you check with a function called gamedb_get_systems() this should use the get_terms().

    Thanks

    Thread Starter kmcminn

    (@kmcminn)

    Hi,

    Thank you again for your response. I’ve looked at the function, and here’s what I found:

    function gamedb_get_systems() {
        $all_systems = get_terms('system', array('hide_empty'=>false, 'orderby'=>'id'));
        $systems = array();
        foreach($all_systems as $system) {
            $systems[$system->slug] = $system->name;
        }
        return $systems;
    }

    I see that it uses get_terms, which is great.

    Also, I do see this commented out right above it:

    /*
    function gamedb_get_systems()
    {
        return array(
            'wii-u' => 'Wii U',
            '3ds' => '3DS',
            'wii-u-eshop' => 'Wii U eShop',
            '3ds-eshop' => '3DS eShop',
            'mobile' => 'Mobile',
        );
    }*/

    Looking at the commented function, shouldn’t I just be able to specify an order without having to use any plugin? What should my next step be?

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Rearranging Options’ is closed to new replies.