Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Make an Event Website a link instead of showing the text url. This version opens a new window with the additional target=blank code.
<?php
add_filter( 'tribe_get_event_website_link_label', 'tribe_get_event_website_link_label_default' );
function tribe_get_event_website_link_label_default( $label ) {
if ( $label === tribe_get_event_website_url() ) {
$label = "Visit Website &raquo;";
}
return '<a href="' . tribe_get_event_website_url() . '" target="_blank">' . $label . '</a>';
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.