jelly_bean
Forum Replies Created
-
Forum: Plugins
In reply to: [Storyform] Storyform hides other sidebar items in adminIssue resolved by plugin developer.
Forum: Plugins
In reply to: [Ultimate WooCommerce Expandable Categories] Slide Up problemWell that’s not very helpful. I may have bought the pro version if you had answered my question. I wanted to know if a feature I needed was in the pro version. Now I guess I’ll never know.
Doesn’t matter now anyway, I found another solution, but just a friendly piece of advice – if you improve your customer care skills you may improve sales.
Forum: Plugins
In reply to: [Import any XML or CSV File to WordPress] CSV commas in paragraphsForum: Plugins
In reply to: [Import any XML or CSV File to WordPress] CSV commas in paragraphsThis isn’t working for me. I”m importing categories and I copied and pasted the above phrase and I now have two categories
(1) “This is the post content
(2) it can have commas”I’ve found a solution!
index.php line 1513 add
'operator' => 'AND'
to$res[] = array( 'taxonomy' => $tax_slug, 'field' => 'slug', 'terms' => $value, 'operator' => 'AND' );
I’m using checkboxes because I want to select more than one category at a time. It seems to be using an OR rather than an AND operator. I had a look at index.php of the plugin, but couldn’t work out what to change to add ‘relation’ => ‘AND’ to the query.
Forum: Plugins
In reply to: [WooCommerce] Show category list with titlesI’m just adding to this in case anyone wants more control over the categories. I’ve discovered I don’t actually want all of my categories to show up on my single post page.
<?php global $post; $args = array( 'parent' => 27 ); $terms = wp_get_post_terms( $post->ID, 'product_cat', $args ); foreach( $terms as $term )$categories[] = $term->slug; { echo 'Country: '.$term->name; }?>
Using this code I can call any category I want to and place it anywhere I want to.
Forum: Plugins
In reply to: [WooCommerce] Show category list with titlesIf anyone is interested in the answer to my original query here is the code:
<?php global $post; $args = array( 'taxonomy' => 'product_cat',); $terms = wp_get_post_terms($post->ID,'product_cat', $args); $count = count($terms); if ($count > 0) { foreach ($terms as $term) { echo '<div>'; $term = get_term_by( 'slug', $term->slug, 'product_cat' ); $parent = get_term_by( 'id', $term->parent, 'product_cat' ); if($parent): echo $parent->name; echo ': '; endif; echo $term->name; echo '</div>'; } }?>
Forum: Plugins
In reply to: [WooCommerce] Show category list with titlesAh thank you. I don’t know why I didn’t do that in the first place. That makes a lot more sense. doh!
Forum: Plugins
In reply to: [WooCommerce] Show category list with titlesI’m getting somewhere
<?php global $post; $args = array( 'taxonomy' => 'product_cat',); $terms = wp_get_post_terms($post->ID,'product_cat', $args); $count = count($terms); if ($count > 0) { foreach ($terms as $term) { echo '<div>'; echo $term->parent; echo $term->name; echo '</div>'; } }?>
I just need to work out how to echo the term parent name rather than the id.
Forum: Plugins
In reply to: [WooCommerce] Show category list with titlesThey are categories. My category structure is:
Type
-trousers
-skirts
-jacketsSize
-10
-12
-14etc.
Forum: Plugins
In reply to: [Event Organiser] Using venue taxonomy with another custom post typeThanks for your reply, that confirms what I found out when I had a play around with the code. I could have the venue taxonomy on either the event admin page or the club admin page, but not both.
I have decided to use a custom meta box on my club admin page for the club venues and keep them separate from the event venues.
Forum: Plugins
In reply to: [Event Organiser] Monthly Archive in sidemenuI just wanted to add a little note for anyone who stumbles across my code here. I have scrapped the first monthly filter and I am now using this which seems to work better.
<?php $months = $wpdb->get_col("SELECT DISTINCT MONTHNAME(StartDate) FROM wptr_eo_events WHERE MONTH(StartDate) < MONTH(CURDATE()) ORDER BY StartDate DESC ");?> <?php $test= strtotime("+1 month")?> <?php foreach($months as $month) : ?> <?php echo '<ul><li class"list-unstyled"><a href="'. site_url() .'/events/on/'.$year .'/'.date('m', strtotime($month)).'"/> ' . $month .'</a></li></ul>';?> <?php endforeach; ?>
Forum: Plugins
In reply to: [Event Organiser] Monthly Archive in sidemenuPerfect, thank you
Forum: Plugins
In reply to: [Event Organiser] Permalinks for child pagesThanks, I found the problem. I had called my events page “Events” and my single page also “Events”. I’ve changed the single page back to just “event” and now it works.