WordPress.org

Ready to get started?Download WordPress

Forums

Multisite Language Switcher
[resolved] specific order (9 posts)

  1. freddy.donckels
    Member
    Posted 2 years ago #

    Hi,
    Is there a way to impose a specific order to the flags different from the default order or the alphabatic order?
    Thanks.
    Freddy

    http://wordpress.org/extend/plugins/multisite-language-switcher/

  2. realloc
    Member
    Plugin Author

    Posted 2 years ago #

    Yes, you can place some code in the functions.php of your theme like this.

  3. freddy.donckels
    Member
    Posted 2 years ago #

    Thank you !
    freddy

  4. ideeone
    Member
    Posted 2 years ago #

    Hello,
    I'm building my first multi lingual site....
    I don't seem to be able to change the order of the flags. I used the code to change the blog collection, but I'm not quite there yet.
    Do I need to use a specific blog ID to replace the numbers ( 1, 2, ) - where do I find it?
    Please help! Thank you.
    /ideeone

  5. realloc
    Member
    Plugin Author

    Posted 2 years ago #

    As network-admin in "Sites" you can just place your mouse over the links of the blogs and you can see the IDs.

  6. fraincs
    Member
    Posted 1 year ago #

    Trying to do the same, my blogs ID are 2 and 3

    So I added but my order stays the same what should I do

    function my_msls_blog_collection_get( $arr ) {
    $arr = array();
    foreach ( array( 3, 2, ) as $id ) {
    $arr[$id] = get_blog_details( $id );
    }
    return $arr;
    }
    add_filter( 'msls_blog_collection_construct', 'my_msls_blog_collection_get' );

  7. realloc
    Member
    Plugin Author

    Posted 1 year ago #

    There has changed something. For example there is a sort-method in the class MslsBlog so your function will just work on which blogs the plugin has to collect. At the moment you can sort by language-code or description but maybe you can explain what you want to do?

  8. fraincs
    Member
    Posted 1 year ago #

    I want to switch the order which my description shows on my website
    Right now it's EN - FR and I want FR - EN

    Description is EN and FR since E is before F I want the reverse order

  9. zouzouille
    Member
    Posted 1 year ago #

    Hello,

    I would like to display my flags in ascending order of IDs is it possible?

    I have DE FR PT US and I would like US(1) FR(2) DE(3) PT(4)

    Thanks for your help.

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic