{"id":1551273,"date":"2018-06-12T03:22:06","date_gmt":"2018-06-12T10:22:06","guid":{"rendered":"https:\/\/theeventscalendar.com\/support\/forums\/topic\/change-event-url-to-a-button\/"},"modified":"2018-06-12T03:22:06","modified_gmt":"2018-06-12T10:22:06","slug":"change-event-url-to-a-button","status":"closed","type":"topic","link":"https:\/\/theeventscalendar.com\/support\/forums\/topic\/change-event-url-to-a-button\/","title":{"rendered":"Change Event URL to a Button"},"content":{"rendered":"<p>I am trying to make the event website url appear as a button instead of a url link. I am running Events Calendar + Events Calendar PRO. I have followed the instructions provided in the events calendar knowledgebase (see following link)<\/p>\n<p><a href=\"https:\/\/theeventscalendar.com\/knowledgebase\/url-as-word-button\/\" rel=\"noopener\" target=\"_blank\">https:\/\/theeventscalendar.com\/knowledgebase\/url-as-word-button\/<\/a><\/p>\n<p>I pasted the following snippet into my Theme functions.php (See attached) to change the URL to a Button<\/p>\n<p>add_filter(&#8216;tribe_get_event_website_link_label&#8217;, &#8216;tribe_get_event_website_link_label_default&#8217;);<\/p>\n<p>function tribe_get_event_website_link_label_default ($label) {<br \/>\n\tif( $label == tribe_get_event_website_url() ) {<br \/>\n\t\t$label = &#8220;Visit Website &raquo;&#8221;;<br \/>\n\t\t$class = &#8220;my-button-class&#8221;;<br \/>\n\t}<\/p>\n<p>\treturn &#8216;<a href=\"' . tribe_get_event_website_url() . '\">&#8216; . $label . &#8216; <\/a>&#8216;;<br \/>\n}<\/p>\n<p> and added the following to my style sheet (see attached):<\/p>\n<p>.my-button-class {<br \/>\nbackground-color: red;<br \/>\npadding: 10px;<br \/>\ncolor: #fff;<br \/>\nfloat: left;<br \/>\n}<\/p>\n<p>According to the instructions, a red button should appear instead of the URL link&#8230; However, I am just seeing a linked word. No Button (see attached)&#8230; <\/p>\n<p>Can anyone help me get this button to appear properly?<\/p>\n<p>Thanks,<\/p>\n<p>Sean<br \/>\nMedias.no<\/p>\n","protected":false},"template":"","class_list":["post-1551273","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>Change Event URL to a Button -<\/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\/change-event-url-to-a-button\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Change Event URL to a Button -\" \/>\n<meta property=\"og:description\" content=\"I am trying to make the event website url appear as a button instead of a url link. I am running Events Calendar + Events Calendar PRO. I have followed the instructions provided in the events calendar knowledgebase (see following link) https:\/\/theeventscalendar.com\/knowledgebase\/url-as-word-button\/ I pasted the following snippet into my Theme functions.php (See attached) to change [&hellip;]\" \/>\n<meta property=\"og:url\" content=\"https:\/\/theeventscalendar.com\/support\/forums\/topic\/change-event-url-to-a-button\/\" \/>\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\/change-event-url-to-a-button\/\",\"url\":\"https:\/\/theeventscalendar.com\/support\/forums\/topic\/change-event-url-to-a-button\/\",\"name\":\"Change Event URL to a Button -\",\"isPartOf\":{\"@id\":\"https:\/\/theeventscalendar.com\/support\/#website\"},\"datePublished\":\"2018-06-12T10:22:06+00:00\",\"breadcrumb\":{\"@id\":\"https:\/\/theeventscalendar.com\/support\/forums\/topic\/change-event-url-to-a-button\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/theeventscalendar.com\/support\/forums\/topic\/change-event-url-to-a-button\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/theeventscalendar.com\/support\/forums\/topic\/change-event-url-to-a-button\/#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\":\"Change Event URL to a Button\"}]},{\"@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":"Change Event URL to a Button -","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\/change-event-url-to-a-button\/","og_locale":"en_US","og_type":"article","og_title":"Change Event URL to a Button -","og_description":"I am trying to make the event website url appear as a button instead of a url link. I am running Events Calendar + Events Calendar PRO. I have followed the instructions provided in the events calendar knowledgebase (see following link) https:\/\/theeventscalendar.com\/knowledgebase\/url-as-word-button\/ I pasted the following snippet into my Theme functions.php (See attached) to change [&hellip;]","og_url":"https:\/\/theeventscalendar.com\/support\/forums\/topic\/change-event-url-to-a-button\/","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\/change-event-url-to-a-button\/","url":"https:\/\/theeventscalendar.com\/support\/forums\/topic\/change-event-url-to-a-button\/","name":"Change Event URL to a Button -","isPartOf":{"@id":"https:\/\/theeventscalendar.com\/support\/#website"},"datePublished":"2018-06-12T10:22:06+00:00","breadcrumb":{"@id":"https:\/\/theeventscalendar.com\/support\/forums\/topic\/change-event-url-to-a-button\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/theeventscalendar.com\/support\/forums\/topic\/change-event-url-to-a-button\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/theeventscalendar.com\/support\/forums\/topic\/change-event-url-to-a-button\/#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":"Change Event URL to a Button"}]},{"@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\/1551273","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\/1551273\/revisions"}],"wp:attachment":[{"href":"https:\/\/theeventscalendar.com\/support\/wp-json\/wp\/v2\/media?parent=1551273"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}