• Where or How do I locate the markup <div data-role=”collapsible-set”> in the following code to collapse the posts under the Category Tile. Here is what I have working right now – https://test3.dfigdesign.com
    and here is the code of the index.php

    `<?php get_header(); ?>

    <div id=”container”>
    <div id=”content” role=”main”>

    <?php
    // get all the categories from the database
    $cats = get_categories();

    // loop through the categries
    foreach ($cats as $cat) {
    // setup the cateogory ID
    $cat_id= $cat->term_id;

    // Make a header for the cateogry
    echo “<h2>”.$cat->name.”</h2>”;
    // create a custom wordpress query
    query_posts(“cat=$cat_id&post_per_page=100”);
    // start the wordpress loop!

    if (have_posts()) : while (have_posts()) : the_post(); ?>
    <ul data-role=”listview” data-inset=”true”>

    <?php // create our link now that the post is setup ?>
    <li><a href=”<?php the_permalink();?>”><?php the_title(); ?></a></li>

    </ul>

    <?php endwhile; endif; // done our wordpress loop. Will start again for each category ?>

    <?php } // done the foreach statement ?>

    </div><!– #content –>
    </div><!– #container –><?php
    /* Run the loop to output the posts.
    * If you want to overload this in a child theme then include a file
    * called loop-index.php and that will be used instead.
    */

    ?>

    <?php get_footer(); ?>`

Viewing 2 replies - 1 through 2 (of 2 total)
  • It is being added from the jquery.mobile.js file.

    Thread Starter dfigdesign

    (@dfigdesign)

    sorry – I’m new to WP and JqueryMobile. I didn’t ask correctly — how do I achieve the following with my WP page to collapse the categories similar to below for my test3 page?

    <div data-role="content">
        <div data-role="<strong>collapsible-set</strong>">
            <div data-role="collapsible" data-content-theme="c">
                <h3>Firs Collapsed list</h3>
                <ul data-role="listview" data-inset="false" data-theme="d">
    
    <li><a href="index.html">Acura</a></li>
    <li><a href="index.html">Audi</a></li>
    <li><a href="index.html">BMW</a></li>
            </div>
         </div><!--/content-primary -->
    </div>
Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘The Application of collapsible-set’ is closed to new replies.