{"id":1331989,"date":"2017-08-08T03:00:32","date_gmt":"2017-08-08T10:00:32","guid":{"rendered":"https:\/\/theeventscalendar.com\/support\/forums\/topic\/show-longterm-events-in-current-month\/"},"modified":"2017-08-08T03:00:32","modified_gmt":"2017-08-08T10:00:32","slug":"show-longterm-events-in-current-month","status":"closed","type":"topic","link":"https:\/\/theeventscalendar.com\/support\/forums\/topic\/show-longterm-events-in-current-month\/","title":{"rendered":"Show longterm events in current month"},"content":{"rendered":"<p>Hi guys,<\/p>\n<p>this might have been asked before, but maybe I simply didn&#8217;t find it:<\/p>\n<p>When I am in list view and I have events which are spanning over several weeks and months, the list keeps showing the event in the starting month. This makes the event look outdated. So I have written a quick filter to remove the date-header:<\/p>\n<pre><code>\/* Tribe Events: Remove the month header in the list view view if the starting month has passed *\/\nfunction tribe_remove_past_date_headers($html, $event_month, $event_year){\n    if(date(&#039;Ym&#039;, tribe_get_start_date(null, false, &#039;U&#039;)) &lt; date(&#039;Ym&#039;) ){\n        $html = &#039;&#039;;\n    }\n    return $html;\n}\nadd_filter( &#039;tribe_events_list_the_date_headers&#039;, &#039;tribe_remove_past_date_headers&#039;, 10, 2 );<\/code><\/pre>\n<p>I have also modified the &#8220;list\/single-event.php&#8221; to check if a longterm event has started already. It then displays the end-date instead with a little &#8220;until&#8221; pre-text before it. <\/p>\n<p>It would be nice if there would be a default way to do this. Maybe the snippet above helps anyone else though.<\/p>\n<p>Cya<br \/>\nFelix<\/p>\n","protected":false},"template":"","class_list":["post-1331989","topic","type-topic","status-closed","hentry"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v25.2 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>Show longterm events in current month -<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/theeventscalendar.com\/support\/forums\/topic\/show-longterm-events-in-current-month\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Show longterm events in current month -\" \/>\n<meta property=\"og:description\" content=\"Hi guys, this might have been asked before, but maybe I simply didn&#8217;t find it: When I am in list view and I have events which are spanning over several weeks and months, the list keeps showing the event in the starting month. This makes the event look outdated. So I have written a quick [&hellip;]\" \/>\n<meta property=\"og:url\" content=\"https:\/\/theeventscalendar.com\/support\/forums\/topic\/show-longterm-events-in-current-month\/\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data1\" content=\"1 minute\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/theeventscalendar.com\/support\/forums\/topic\/show-longterm-events-in-current-month\/\",\"url\":\"https:\/\/theeventscalendar.com\/support\/forums\/topic\/show-longterm-events-in-current-month\/\",\"name\":\"Show longterm events in current month -\",\"isPartOf\":{\"@id\":\"https:\/\/theeventscalendar.com\/support\/#website\"},\"datePublished\":\"2017-08-08T10:00:32+00:00\",\"breadcrumb\":{\"@id\":\"https:\/\/theeventscalendar.com\/support\/forums\/topic\/show-longterm-events-in-current-month\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/theeventscalendar.com\/support\/forums\/topic\/show-longterm-events-in-current-month\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/theeventscalendar.com\/support\/forums\/topic\/show-longterm-events-in-current-month\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/theeventscalendar.com\/support\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Topics\",\"item\":\"https:\/\/theeventscalendar.com\/support\/topics\/\"},{\"@type\":\"ListItem\",\"position\":3,\"name\":\"Calendar Products\",\"item\":\"https:\/\/theeventscalendar.com\/support\/forums\/forum\/events\/\"},{\"@type\":\"ListItem\",\"position\":4,\"name\":\"Events Calendar PRO\",\"item\":\"https:\/\/theeventscalendar.com\/support\/forums\/forum\/events\/events-calendar-pro\/\"},{\"@type\":\"ListItem\",\"position\":5,\"name\":\"Show longterm events in current month\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/theeventscalendar.com\/support\/#website\",\"url\":\"https:\/\/theeventscalendar.com\/support\/\",\"name\":\"\",\"description\":\"\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/theeventscalendar.com\/support\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Show longterm events in current month -","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/theeventscalendar.com\/support\/forums\/topic\/show-longterm-events-in-current-month\/","og_locale":"en_US","og_type":"article","og_title":"Show longterm events in current month -","og_description":"Hi guys, this might have been asked before, but maybe I simply didn&#8217;t find it: When I am in list view and I have events which are spanning over several weeks and months, the list keeps showing the event in the starting month. This makes the event look outdated. So I have written a quick [&hellip;]","og_url":"https:\/\/theeventscalendar.com\/support\/forums\/topic\/show-longterm-events-in-current-month\/","twitter_card":"summary_large_image","twitter_misc":{"Est. reading time":"1 minute"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/theeventscalendar.com\/support\/forums\/topic\/show-longterm-events-in-current-month\/","url":"https:\/\/theeventscalendar.com\/support\/forums\/topic\/show-longterm-events-in-current-month\/","name":"Show longterm events in current month -","isPartOf":{"@id":"https:\/\/theeventscalendar.com\/support\/#website"},"datePublished":"2017-08-08T10:00:32+00:00","breadcrumb":{"@id":"https:\/\/theeventscalendar.com\/support\/forums\/topic\/show-longterm-events-in-current-month\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/theeventscalendar.com\/support\/forums\/topic\/show-longterm-events-in-current-month\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/theeventscalendar.com\/support\/forums\/topic\/show-longterm-events-in-current-month\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/theeventscalendar.com\/support\/"},{"@type":"ListItem","position":2,"name":"Topics","item":"https:\/\/theeventscalendar.com\/support\/topics\/"},{"@type":"ListItem","position":3,"name":"Calendar Products","item":"https:\/\/theeventscalendar.com\/support\/forums\/forum\/events\/"},{"@type":"ListItem","position":4,"name":"Events Calendar PRO","item":"https:\/\/theeventscalendar.com\/support\/forums\/forum\/events\/events-calendar-pro\/"},{"@type":"ListItem","position":5,"name":"Show longterm events in current month"}]},{"@type":"WebSite","@id":"https:\/\/theeventscalendar.com\/support\/#website","url":"https:\/\/theeventscalendar.com\/support\/","name":"","description":"","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/theeventscalendar.com\/support\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"}]}},"_links":{"self":[{"href":"https:\/\/theeventscalendar.com\/support\/wp-json\/wp\/v2\/topic\/1331989","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/theeventscalendar.com\/support\/wp-json\/wp\/v2\/topic"}],"about":[{"href":"https:\/\/theeventscalendar.com\/support\/wp-json\/wp\/v2\/types\/topic"}],"version-history":[{"count":0,"href":"https:\/\/theeventscalendar.com\/support\/wp-json\/wp\/v2\/topic\/1331989\/revisions"}],"wp:attachment":[{"href":"https:\/\/theeventscalendar.com\/support\/wp-json\/wp\/v2\/media?parent=1331989"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}