Welcome, guest!

Feel free to read the blog, browse for themes, or join the club.

Series plugin question...

  1. I'm trying to change the chronological order of posts on the Series archive page, or whatever the page is that lists all the posts for each Series.

  2. You must be a logged-in exclusive member to view this reply.

  3. I'll keep this next request here instead of starting a new topic. Here is how I'd like to output the Series on one of my pages:

    Series 1
    *Post 1
    *Post 2
    *Post 3

    Series 2
    *Post 1
    *Post 2

    Series 3
    *Post 1
    *Post 2

    I'm having a tough time getting this figured out, including geting some help on PHPFreaks.com.

  4. You must be a logged-in exclusive member to view this reply.

  5. I mean I want to have all of that on the same page, like my front page.

  6. That's a very nice feature, but it doesn't get me completely what I need. I'd like to have that on my front page in a DIV that I have put on my Front Page for *things*. It's where I have Serieses, with a limit of 5, listed in chronological order based on the most recent post.

  7. You must be a logged-in exclusive member to view this reply.

  8. Ok...that isolates the code needed to move it to a table on my front page. Now, how to mesh that with the code I have which prints it in chronological order based on the most recent post:

    $mf_query = <<<EOF
        SELECT t.*, tt.*, p.*
        FROM {$wpdb->posts} as p, {$wpdb->term_relationships} as tr, {$wpdb->terms} AS t, {$wpdb->term_taxonomy} AS tt
        WHERE tt.<code>taxonomy</code> = 'series'
        AND t.<code>term_id</code> = tt.<code>term_id</code>
        AND tr.<code>object_id</code> = p.<code>ID</code>
        AND tt.<code>term_taxonomy_id</code> = tr.<code>term_taxonomy_id</code>
        AND tt.<code>count</code> > 0
        GROUP BY t.<code>term_id</code>
        ORDER BY p.<code>post_date</code> DESC
    	LIMIT 5
    EOF;
    
    $mf_terms = $wpdb->get_results( $mf_query );
    
    if( !empty( $mf_terms ) ) {
        print "\n\t" . '<ul>';
        foreach ( $mf_terms as $mf_term  ) {
    	 		print "\n\t\t" . '<li><a href="' . get_term_link( $mf_term, $mf_term->taxonomy ) . '">' . $mf_term->name . '</a></li>';
    
        print "\n\t" . '</ul>';
    
    	}

    This, however, just prints the Series title. I'd like to have the Posts for each Series printed below it...just in chronological order. A limit of 5 Serieses. : )

  9. You must be a logged-in exclusive member to view this reply.

  10. Where am I supposed to put that? I tried it alone, as well after what you extracted above. I get lost between regular queries and WP queries.

  11. You must be a logged-in exclusive member to view this reply.

  12. I get errors for unexpected } or unexpected end.

  13. Part of the problem I'm having is the syntax between much of the PHP I'm used to working with vs. WordPress syntax. WP is has PHP tags surrounding almost every snippet of code. Most of what I'm working with, when I just go to PHP forums for help is dealt around PHP tags at the beginning of the page and the end.

    Here is what I'm working with from what you gave me:

    $loop = new WP_Query( array( 'series' => $mf_term->slug ) ); 
    
     if ( $loop->have_posts() ) : 
    
    echo $mf_term->name; 
    
    	echo '<ul>';
    		while ( $loop->have_posts() ) : $loop->the_post(); 
    
    		echo '<li><a href="' . the_permalink() . '">' . the_title() . '</a></li>';
    
    		endwhile; wp_reset_query();
    		echo '</ul>';
    
    		endif;

    The problem is, oddly, the href isn't printing correctly. It's not printing as a link. It just prints the permalink and the title in normal text. I've tried another href there, and it prints just fine.

    So when I put it where you told me to put it, it works except for how it prints the permalink and title.

    Here is my test page: http://hoosierhoopsreport.com/test.php

  14. Maybe you can explain it, but I used get_the_permalinks and get_the_title instead, and it worked. Does it have something to do the ones without "get_" strip HTML attributes? I read something like that with the_title, and it also said to See get_the_title. It works now. Crazy.

    Thanks for helping with this. I would think you'd have some users who want to list Series or taxonomies in general chronologically. Throw them this test page whenever you want to display it.

    http://hoosierhoopsreport.com/test.php

    Now I'm going to add back your comments part of the code, and I may even try to print the date.

  15. You must be a logged-in exclusive member to view this reply.

Reply

You must log in to post.

Limited Access

If you have an account, please take a moment to log in.

Non-exclusive members have limited access to the support forums.

To enjoy the full range of support, sign up for an exclusive membership in the theme club.

Support Forums

  • Core Framework (54 posts)
  • Hybrid Theme (22,711 posts)
  • Bliss Theme (255 posts)
  • Options Theme (10,362 posts)
  • Visionary Theme (767 posts)
  • WordPress (144 posts)
  • WordPress Plugins (2,146 posts)
  • bbPress Themes (308 posts)
  • General Discussion (5,572 posts)
  • Critical Theme (0 posts)
  • Hybrid News Theme (132 posts)
  • Hybrid Original Theme (26 posts)
  • Leviathan Theme (16 posts)
  • Life Collage Theme (9 posts)
  • Old School Theme (3 posts)
  • Outline Theme (108 posts)
  • Skeleton Theme (40 posts)
  • Structure Theme (2,768 posts)
  • Members Plugin (2 posts)
  • Cleaner Gallery Plugin (14 posts)
  • Get the Image Plugin (3 posts)
  • Message Board Plugin (0 posts)
  • Widgets Reloaded Plugin (0 posts)
  • Breadcrumb Trail Plugin (0 posts)
  • Query Posts Plugin (80 posts)
  • Hybrid Hook Plugin (7 posts)
  • Hybrid Hook Widgets Plugin (0 posts)
  • Hybrid Tabs (5 posts)