Heinz Duschanek

Forum Replies Created

Viewing 15 posts - 1 through 15 (of 35 total)
  • Author
    Posts
  • in reply to: RSVP Ticket is not stored #1358264
    Heinz Duschanek
    Participant

    Deactivating WPML fixes (fixes???) the error.

    Uhm, this can’t be true … Should we switch to polylang other than WPML?

    OMG!

    in reply to: tribe category nicename as CSS class on body tag #1320550
    Heinz Duschanek
    Participant

    For other users searching here: another solution to get the category slug into the body CSS classes for a single event (to be used in functions.php):

    add_filter('body_class','conf_class');
    function conf_class($classes) {
      if(in_the_loop()) { 
    	$post_id = get_the_ID(); 
      } else { 
    	$post_id = get_queried_object_id(); 
      }
    
      $terms = tribe_get_event_cat_slugs($post_id); 
      foreach ($terms as $term) { // loop needed? 
        $eventCatSlug = $eventCatSlug . 'tribe_events-category-' . $term;
      }
    
      $classes[] = $eventCatSlug;
      return $classes;
    } 

    Maybe the foreach loop is not needed, as it also works with:

    $classes[] = 'tribe_events-category-' . $terms[0];

    Now I try to figure out the same thing for category archive pages. Wish me luck.

    in reply to: tribe category nicename as CSS class on body tag #1320497
    Heinz Duschanek
    Participant

    Hi Shelby,

    thank you for your answer, but I think this is a misunderstanding.

    First: I do not need external PHP freelancer help, I can tweak code by myself.
    Second: I am just asking (as so many others here also did) how to get the slug of a tribe category within a function in functions.php. This is not an unsolvable mystery, I guess, so why not provide a working code snippet to me and the others?

    The themers guide the support team refers to is wonderful, but no help here.

    The category slug is a already there, as I can see it within <body> in a <div>-tag. All I ask is for some lines of code to put it into the <body>-tag additionally, as we need it for styling purposes.

    in reply to: previous/next event #1320487
    Heinz Duschanek
    Participant

    I am a little bit astonished that there is no way to set this. But yes, in that case I am interested in your resources … but where do I find something about prev/next in the themer’s guide?

    Thank you in advance.

    in reply to: tribe category nicename as CSS class on body tag #1319967
    Heinz Duschanek
    Participant

    I figured out this here, which at least adds the tribe category to the body CSS in case of single events:

    add_filter('body_class','category_id_class');
    function category_id_class($classes) {
      if(in_the_loop()) { 
    	$post_id = get_the_ID(); 
      } else { 
    	$post_id = get_queried_object_id(); 
      }
    
      $eventCatSlug = '';
    
      $terms = wp_get_post_terms($post_id, 'tribe_events_cat');
      $count = count($terms);
      if ( $count > 0 ){
     	foreach ( $terms as $term ) {
    	  $eventCatSlug = $eventCatSlug . ' tribe-events-category-' . $term->slug;
        }
      }
    
      $classes[] = $eventCatSlug;
      return $classes;
    }

    Uhm, tribe team, are you serious by not providing something easier to get the category slug in functions.php???

    How would I get the same result for a category of events instead of the single event? It is just not sufficient to have it later in a <div>…

    in reply to: permalink (plural) directs to homepage #1319935
    Heinz Duschanek
    Participant

    SOLVED: Chrome keeps cache rigidly, other browsers shows right behaviour.

    in reply to: tribe category nicename as CSS class on body tag #1319933
    Heinz Duschanek
    Participant

    I mean this code:

    function category_id_class($classes) {
    	global $post;
    	foreach((get_the_category($post->ID)) as $category)
    		$classes[] = $category->category_nicename;
    	return $classes;
    }
    add_filter('body_class', 'category_id_class');
    in reply to: Events Calendar Pro for Offline Courses #1288204
    Heinz Duschanek
    Participant

    The customer bought the two plugins now, and I really hope, there will be no showstopper here ….

    Regards,
    Heinz

    in reply to: Events Calendar Pro for Offline Courses #1287535
    Heinz Duschanek
    Participant

    Great, I think we suggest it to the customer then ….

    Thank you for your help so far.

    in reply to: Events Calendar Pro for Offline Courses #1287005
    Heinz Duschanek
    Participant

    So far it looks as if this can be done with your plugins.

    Yet two more issues:

    * Is it possible to get a demo version of event tickets plus, which works for e.g. two weeks on a staging server just to be able to create a working demo site for the customer (layout does not matter, it’s about the functionality)? Or is there already a demo site showing these features?

    * Concerning trainers: is it possible to display a picture of the trainer within the course (e.g. using a widget in sidebar)? Maybe by setting the name or id of the trainer as a <body> css class, to be able to do this with CSS? Or by using a post thumbnail/featured image, which can then be display along with the name of the organizer/trainer (by using a custom template)?

    in reply to: Events Calendar Pro for Offline Courses #1286974
    Heinz Duschanek
    Participant

    Thank you, Geoff,

    we think about your suggestions.

    Kind regards,
    Heinz

    in reply to: Events Calendar Pro PreSales Questions #1263294
    Heinz Duschanek
    Participant

    Last question so far:

    a registration for events with payment gateway API is there? Or would the registration process need to be done entirely externally?

    Thank you in advance,
    Heinz

    in reply to: Events Calendar Pro PreSales Questions #1261288
    Heinz Duschanek
    Participant

    Hi Shelby,

    thank you. By “plugin customization” you mean work in template files? Because that should not be overwritten with future plugin updates.

    Heinz

    in reply to: Venue not shown #1092837
    Heinz Duschanek
    Participant

    I think I was successful, please confirm.

    New code in the top part of /tribe-events/list/single-event.php:

    <?php 
    
    // Setup an array of venue details for use later in the template
    $venue_details = tribe_get_venue_details();
    
    // Venue
    $has_venue_address = ( ! empty( $venue_details['address'] ) ) ? ' location' : '';
    
    // Organizer
    $organizer = tribe_get_organizer();
    
    if ($venue_name = tribe_get_meta( 'tribe_event_venue_name' ) ) {
    	$venue_details[] = $venue_name;	
    }
    
    if ($venue_address = tribe_get_meta( 'tribe_event_venue_address' ) ) {
    	$venue_details[] = $venue_address;	
    }
    ?>

    And then display it with:

    <?php echo $venue_name . '<br />' . $venue_address; ?>

    I hope this change does not provide trouble in the future.

    in reply to: Venue not shown #1092783
    Heinz Duschanek
    Participant

    I could identify the file: /tribe-events/list/single-event.php

    It contains:

    <?php tribe_get_venue_link( get_the_ID(), class_exists( 'TribeEventsPro' ) ); ?>

    Or in full:

    <?php if( class_exists( 'TribeEventsPro' ) ): ?>
      <span class="datum-none"><?php tribe_get_venue_link( get_the_ID(), class_exists( 'TribeEventsPro' ) ); ?></span><br />
    <?php else: ?>
     <span class="datum-none"><?php echo tribe_get_venue( get_the_ID() ); ?></span>
    <?php endif; ?>
    </span>

    And this does not work anymore.

Viewing 15 posts - 1 through 15 (of 35 total)