{"id":1028208,"date":"2015-11-19T12:11:06","date_gmt":"2015-11-19T20:11:06","guid":{"rendered":"https:\/\/theeventscalendar.com\/support\/forums\/topic\/week-view-and-opening-hours\/"},"modified":"2015-11-19T14:25:51","modified_gmt":"2015-11-19T22:25:51","slug":"week-view-and-opening-hours","status":"closed","type":"topic","link":"https:\/\/theeventscalendar.com\/support\/forums\/topic\/week-view-and-opening-hours\/","title":{"rendered":"Week view and opening hours"},"content":{"rendered":"<p>Hello,<\/p>\n<p>I am writing this because I actually found the answer to this about 2 months ago when I initially setup my site, but for some reason the &#8220;fix&#8221; no longer works.<\/p>\n<p>I am needing to remove the full 24 hours from the week view. As it displays now, people see the day activities for the week at 12am and have to scroll down quite a bit to see the activities at 9am.<\/p>\n<p>I used this script before in my header file and it worked a couple months ago:<\/p>\n<p>add_filter( \u2018tribe_events_week_get_hours\u2019, \u2018filter_week_hours\u2019 );<br \/>\nfunction filter_week_hours( $hours ) {<br \/>\n$hour = 0;<\/p>\n<p>foreach ( $hours as $key =&gt; $formatted_hour ) {<br \/>\nif ( $hour &lt; 9 || $hour &gt; 19 ) {<br \/>\nunset( $hours[ $hour ] );<br \/>\n}<\/p>\n<p>$hour ++;<br \/>\n}<\/p>\n<p>return $hours;<br \/>\n}<\/p>\n<p>Now this code no longer works. All days in week view start at 12 am&#8230; is there any solution to this that will &#8220;stick&#8221;? I have hunted this forum for help with this, but I seem to be the only one with this issue&#8230; any help is appreciated, thank you<\/p>\n","protected":false},"template":"","class_list":["post-1028208","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>Week view and opening hours -<\/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\/week-view-and-opening-hours\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Week view and opening hours -\" \/>\n<meta property=\"og:description\" content=\"Hello, I am writing this because I actually found the answer to this about 2 months ago when I initially setup my site, but for some reason the &#8220;fix&#8221; no longer works. I am needing to remove the full 24 hours from the week view. As it displays now, people see the day activities for [&hellip;]\" \/>\n<meta property=\"og:url\" content=\"https:\/\/theeventscalendar.com\/support\/forums\/topic\/week-view-and-opening-hours\/\" \/>\n<meta property=\"article:modified_time\" content=\"2015-11-19T22:25:51+00:00\" \/>\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\/week-view-and-opening-hours\/\",\"url\":\"https:\/\/theeventscalendar.com\/support\/forums\/topic\/week-view-and-opening-hours\/\",\"name\":\"Week view and opening hours -\",\"isPartOf\":{\"@id\":\"https:\/\/theeventscalendar.com\/support\/#website\"},\"datePublished\":\"2015-11-19T20:11:06+00:00\",\"dateModified\":\"2015-11-19T22:25:51+00:00\",\"breadcrumb\":{\"@id\":\"https:\/\/theeventscalendar.com\/support\/forums\/topic\/week-view-and-opening-hours\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/theeventscalendar.com\/support\/forums\/topic\/week-view-and-opening-hours\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/theeventscalendar.com\/support\/forums\/topic\/week-view-and-opening-hours\/#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\":\"Welcome!\",\"item\":\"https:\/\/theeventscalendar.com\/support\/forums\/forum\/_welcome\/\"},{\"@type\":\"ListItem\",\"position\":4,\"name\":\"Pre-Sales Questions\",\"item\":\"https:\/\/theeventscalendar.com\/support\/forums\/forum\/_welcome\/pre-sales-questions\/\"},{\"@type\":\"ListItem\",\"position\":5,\"name\":\"Week view and opening hours\"}]},{\"@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":"Week view and opening hours -","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\/week-view-and-opening-hours\/","og_locale":"en_US","og_type":"article","og_title":"Week view and opening hours -","og_description":"Hello, I am writing this because I actually found the answer to this about 2 months ago when I initially setup my site, but for some reason the &#8220;fix&#8221; no longer works. I am needing to remove the full 24 hours from the week view. As it displays now, people see the day activities for [&hellip;]","og_url":"https:\/\/theeventscalendar.com\/support\/forums\/topic\/week-view-and-opening-hours\/","article_modified_time":"2015-11-19T22:25:51+00:00","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\/week-view-and-opening-hours\/","url":"https:\/\/theeventscalendar.com\/support\/forums\/topic\/week-view-and-opening-hours\/","name":"Week view and opening hours -","isPartOf":{"@id":"https:\/\/theeventscalendar.com\/support\/#website"},"datePublished":"2015-11-19T20:11:06+00:00","dateModified":"2015-11-19T22:25:51+00:00","breadcrumb":{"@id":"https:\/\/theeventscalendar.com\/support\/forums\/topic\/week-view-and-opening-hours\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/theeventscalendar.com\/support\/forums\/topic\/week-view-and-opening-hours\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/theeventscalendar.com\/support\/forums\/topic\/week-view-and-opening-hours\/#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":"Welcome!","item":"https:\/\/theeventscalendar.com\/support\/forums\/forum\/_welcome\/"},{"@type":"ListItem","position":4,"name":"Pre-Sales Questions","item":"https:\/\/theeventscalendar.com\/support\/forums\/forum\/_welcome\/pre-sales-questions\/"},{"@type":"ListItem","position":5,"name":"Week view and opening hours"}]},{"@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\/1028208","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":1,"href":"https:\/\/theeventscalendar.com\/support\/wp-json\/wp\/v2\/topic\/1028208\/revisions"}],"predecessor-version":[{"id":1028261,"href":"https:\/\/theeventscalendar.com\/support\/wp-json\/wp\/v2\/topic\/1028208\/revisions\/1028261"}],"wp:attachment":[{"href":"https:\/\/theeventscalendar.com\/support\/wp-json\/wp\/v2\/media?parent=1028208"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}