lochie1979
Forum Replies Created
Viewing 4 replies - 1 through 4 (of 4 total)
-
Forum: Themes and Templates
In reply to: I want plain page with blog onlyThe above code didn’t work. It only outputs the following:
Posts navigation
Older
postsBoth ‘Older’ and ‘Posts’ are on seperate lines and link to the same thing but there is no news.
Forum: Themes and Templates
In reply to: I want plain page with blog onlyThank you, I will give this a try. Where would I edit to select to only show a certain category?
- This reply was modified 8 years, 3 months ago by lochie1979.
Forum: Plugins
In reply to: [WooCommerce] Simple custom shortcode problemstill same issue but latest version of the code is:
function product_list_by_category_name( $product_category_name ){ $args = array( 'post_type' => 'product', 'product_cat' => $product_category_name ); $loop = new WP_Query( $args ); while ( $loop->have_posts() ) : $loop->the_post(); global $product; $amount = get_post_meta($product->post->ID, '_price', true) . ' ' . get_woocommerce_currency(); echo '<table width="400" border="0" cellspacing="0" cellpadding="2">'; echo '<tr><td width="250"><div align="left"><!-- <a href="'.get_permalink().'"> --!>'. get_the_title() .'<!-- </a> --!></div></td><td width="150"><div align="left"> '. $amount .'</div></td></tr>'; echo '</table>'; endwhile; wp_reset_query(); } /** SHORTCODE **/ function product_list_by_category_name_shortcode( $atts ) { extract(shortcode_atts(array( 'product_category_slug' => '' ), $atts)); return product_list_by_category_name( $product_category_slug ); } add_shortcode( 'product_list_by_category', 'product_list_by_category_name_shortcode' ); ?>
Forum: Fixing WordPress
In reply to: Needing a simple gallery but can only find overly complicated onesAs a competitor of theres I doubt they’d part with it I’m afraid.
Viewing 4 replies - 1 through 4 (of 4 total)