Related posts popup
I’ve found exactly what I was looking for: http://wordpress.org/plugins/upprev/
I’ve found exactly what I was looking for: http://wordpress.org/plugins/upprev/
Please paste here all your code about this function. And next take a look at this tutorial: http://smallbusiness.chron.com/display-facebook-feed-wordpress-31436.html Best regards!
After some Google searches, I found all I needed to do was set the custom_post_type registration to include hierarchical => true and this solved my problem.
When query iterates it holds the number of current post (zero-based) in current_post property: echo $wp_query->current_post % 2 ? ‘cat1’ : ‘catA’;
The problem is that if you pass multiple category to a query, then you’ll retrieve 4 posts ordered by date, but if you last 4 posts are all in one category, you’ll get all 4 posts from same category. You have 2 choices: run 4 different queries, one per category, and retrieve one post per … Read more
Use get_post_field(‘post_content’, $product_page->ID ) to get the content outside loop. <?php $product_pages_args = array( ‘meta_key’ => ‘_wp_page_template’, ‘meta_value’ => ‘page_library_html.php’ ); $product_pages = get_pages( $product_pages_args ); ?> <?php foreach ( $product_pages as $product_page ) { echo ‘<div id=”posts” class=”flex_100″>’; echo ‘<div id=”library_title”><a href=”‘ . get_permalink( $product_page->ID ) . ‘”>’ . $product_page->post_title . ‘</a></div>’; echo ‘<div … Read more
WP Gallery Image Page Issue When 2 galleries share one image
I’ve used WordPress Conditional Tags to add a unique class or id to the containing div of the different page types. This could work well to change the background image/color for different types. Also, WordPress automatically adds a body class to the <body> tag for each page, so that could possibly be hooked into for … Read more
The function wp_get_archives as far as I know this will only output a list. Instead use the WordPress loop and WP Query’s Date parameters. For example to get yesterdays posts using WP_Query you can do something like: $yesterday = date(‘d.m.Y’,strtotime(“yesterday”)); $yesterdayarray = date_parse($yesterday); $query = new WP_Query( ‘&day=’ . $yesterdayarray[“day”] ); // grab the data … Read more
aha…white screen of death. I don’t know how I missed it. Your if statement lacks parenthesis. Try this: public function title() { if ( is_category() ) { echo ‘<h2 class=”post_title”>’; } else { echo ‘<h1 class=”post_title”>’; }; echo ‘<a href=”‘; the_permalink(); echo ‘” data-disqus-identifier=”‘; the_ID(); echo ‘”>’; the_title(); if ( is_category() ) { echo ‘</a></h2>’; … Read more