• Resolved chenryhen

    (@chenryhen)


    Is this possible? I tried to use Mini Loop in two different places on my a page, and it’s breaking my markup. Before I pull my hair out trying to fix it, can you even call Mini Loops more than once on a page? And if you can, what should I take into account to keep it from messing up the page?

    http://wordpress.org/extend/plugins/mini-loops/

Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Author Kailey (trepmal)

    (@trepmal)

    It shouldn’t be a problem to call the widget multiple times. In fact, I was just doing so moments ago to help another user out.

    If you can narrow down where the markup is breaking or provide more details, I might be able to offer more assistance.

    Thread Starter chenryhen

    (@chenryhen)

    It looks like some of my HTML just disappears. Let’s see. The site is at:

    http://chenryhen.com/clients/twg/

    Right now, it looks ok, because I put the information in statically. Here is what’s on the page itself, via the WordPress content box:

    <div id="story-slider">
    <ul id="features">
       -- I'm snipping just the elements in this list --
    </ul>
    </div>
    
    </div>
    <div id="main-content-bottom"></div>
    
    <div id="latest-news">
    <h1>Latest News</h1>
    [miniloop number_posts=1 categories=-4][ml_format][/miniloop]
    </div>

    I’d like the features ul to have posts in the ‘featured’ category though. But even if I just do this:

    <div id="story-slider">
    [miniloop]
    </div>
    
    </div>
    <div id="main-content-bottom"></div>
    
    <div id="latest-news">
    <h1>Latest News</h1>
    [miniloop number_posts=1 categories=-4][ml_format][/miniloop]
    </div>

    The bottom of that features area just disappears and the features div and the Latest News div run together. Thanks for offering to take a look!

    Plugin Author Kailey (trepmal)

    (@trepmal)

    Okay, I think I see.
    Mixing closing and self-closing shortcodes can cause unexpected results. Try closing the first one

    <div id="story-slider">
    [miniloop][/miniloop]
    </div>
    
    </div>
    <div id="main-content-bottom"></div>
    
    <div id="latest-news">
    <h1>Latest News</h1>
    [miniloop number_posts=1 categories=-4][ml_format][/miniloop]
    </div>

    Also, I hope that extra closing div is just the result of a partial snippet…?

    Let me know if that helps.

    Thread Starter chenryhen

    (@chenryhen)

    That extra div does belong to an open div tag further up. 🙂

    That did the trick! I think I’m back in business. Is it possible to create an ml_format2 or does it not work like that?

    Plugin Author Kailey (trepmal)

    (@trepmal)

    You can have extra [ml_format]s. Just pass an alternate custom field name. For example

    [ml_format name='ml_format2']

    Ah gotcha. I really appreciate all the help Kailey

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘[Plugin: Mini Loops] Multiple Mini Loops on the same page?’ is closed to new replies.