I'm developing a mobile theme and need to change the format of posts that are using the tag.

Can I add something to functions.php to change the format?

Ideally i'd like to make each page a list-item then display all inline on one page versus an individual pages, is that possible?

1 Answer 1


One easy way to do this is to alter the global variables related to paging after calling the_post() in your loop.

global $post, $pages, $numpages, $multipage;
while( have_posts() ) {

    if( is_mobile() ) {
        $pages = array( $post->post_content );
        $page = $numpages = 1;
        $multipage = false;

    // ... template

Basically what you're doing is un-doing the paging setup done in setup_postdata()

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.