Forum Replies Created
-
AuthorPosts
-
thomasParticipant
he geoff,
i checked some links and now i have this:
if( here has to be the right code snippet ) {$termclass = "current-cat";} echo '<li class="'. $termclass .'"><a href="'. get_term_link($term->slug, 'tribe_events_cat') .'" >' . $term->name . '</a></li>';
i just need to check if the current category is viewed to put a “current-cat” class to the li.
but i don’t know how? anyway the class works …
thomasthomasParticipanthey brook,
i found out that you can activate shortcodes in contactform7 with this in your function.php
add_filter( 'wpcf7_form_elements', 'do_shortcode' );
all i need is to write a shortcode that does the following things:
– get the dates (i allready achieved this part)
– wrap them in the form of the select field (this is where i need help)thomasParticipanthey brook,
yes of course! as you can read in the first post i’d like to have those dates included in a contactform7 form as a select dropdown menu. how can i send the dates from the query to the contactform.
[select menu-dropdown "date1" "date2" "date3"]
regards
thomasJune 16, 2015 at 9:52 am in reply to: make events backend more clear (disable options and end date) #969804thomasParticipantokay i was thinking this is more easy. well i won’t do it then i allready ran far off from the original scope and my client will never understand to pay extra for little more comfort.
all my best
thomasthomasParticipantthis is working fine and lets me sort the categories with the simple custom post type plugin:
<?php $terms = get_terms( TribeEvents::TAXONOMY, array( 'orderby' => 'menu_order' ) ); foreach ( $terms as $term ) { echo '<li><a href="'. get_term_link($term->slug, 'tribe_events_cat') .'" >' . $term->name . '</a></li>'; }?>
thomasParticipanthey brook,
so far i got:
<?php query_posts(array( 'post_type' => 'tribe_events', 'order' => 'ASC', 'tag' => basename( get_permalink() ) )); while (have_posts()) : the_post(); $event = get_post(); echo "<br>"; echo tribe_get_start_date( $event, $displayTime = false, $dateFormat = "l, j. F Y" ); if ( -1 == $event->menu_order ) { echo " - bereits ausgebucht"; }; endwhile; wp_reset_query(); ?>
which checks if the tag of an event post is the same like the slug of the blog post.
i tried some stuff with the post title but i got no success at all…June 15, 2015 at 5:36 pm in reply to: display all events with same post title in a different template #969651thomasParticipantmy try is to use the search function in the query, because i read that by default the post title gets searched as well. somehow this is not working at all:
<?php query_posts(array( 'post_type' => 'tribe_events', 'order' => 'ASC', 's' => 'Das kleine Wein ABC' ));
maybe you got something that solves the last issue here…
June 15, 2015 at 5:11 pm in reply to: display all events with same post title in a different template #969649thomasParticipanthey george, i googled around and come up with this:
<?php query_posts(array( 'post_type' => 'tribe_events', 'order' => 'ASC', 'tag' => basename( get_permalink() ) )); while (have_posts()) : the_post(); $event = get_post(); echo "<br>"; echo tribe_get_start_date( $event, $displayTime = false, $dateFormat = "l, j. F Y" ); if ( -1 == $event->menu_order ) { echo " - bereits ausgebucht"; }; endwhile; wp_reset_query(); ?>
works quite well. only thing is i cannot search the post title – this seems to be a huge lack in wordpress itself. is there a workaround or solution for this?
June 15, 2015 at 2:32 pm in reply to: uncheck sticky in calendar view does not change event position #969624thomasParticipanthey nico, i am very sorry.
i just found out that this is conflicting with the nsp post types order plugin.
i switched to the simple custom post order plugin which also lets me sort events categories.
i exclude the event posts and everything is working well.the stickyness does not effect the query any longer.
thanksJune 15, 2015 at 12:50 pm in reply to: add fully booked behind dates with [event rocket] or [tribe_mini_calendar] #969561thomasParticipanthey george,
since the exclusion of the event tribes order in the plugin is only available in advanced version i switched to another plugin.
simple post types order
there i can include and excludes posts, categories…
everything is working fine!June 15, 2015 at 11:50 am in reply to: add fully booked behind dates with [event rocket] or [tribe_mini_calendar] #969526thomasParticipantgeorge, i just found out that the “post types order” plugin from nsp code interfeared with the events query.
i unchecked “admin sort” and “automatic sort” and the dates are shown in ascending order no matter what i checked.
the thing is i need to order the posts and will see if there is a way to exclude event tribe posts from the plugin.
maybe you know it and allready have a solution…June 15, 2015 at 11:30 am in reply to: add fully booked behind dates with [event rocket] or [tribe_mini_calendar] #969517thomasParticipantexcactly!
June 14, 2015 at 4:36 pm in reply to: display all events with same post title in a different template #969348thomasParticipanthey george, okay i understand your point.
is there a way i can read the tag of an event.this would be working too:
get all events that have the tag “wein-tante”
thanks and regardsJune 14, 2015 at 4:29 pm in reply to: add fully booked behind dates with [event rocket] or [tribe_mini_calendar] #969347thomasParticipanthey george,
thanks for this great hint, the functions.php entry didn’t work, however i ended up with this snippet in my dates.php which is working quite good:
<?php $event = get_post( $event_id ); echo "<br>"; echo tribe_get_start_date( $event, $displayTime = false, $dateFormat = "l, j. F Y" ); if ( -1 == $event->menu_order ) { echo " - fully booked"; } ?>
only the issue with the menu_order is still there. once checked the date will stay on top no matter how many times i uncheck the “sticky in calendar view” option of an event. actually i don’t need the stickyness at all (i like to have an ascending order for the dates all the time).
best regards
thomasJune 14, 2015 at 7:19 am in reply to: add fully booked behind dates with [event rocket] or [tribe_mini_calendar] #969287thomasParticipanthi right now i hitting into the right direction, i guess.
i use a custom template to display events now: tribe-events/dates.php
<?php echo "<br>"; echo tribe_get_start_date( $event = null, $displayTime = false ); if ( $EventShowInCalendar=="yes" ) echo 'fully booked'; ?>
somehow this is not working
regards -
AuthorPosts