Okay
  Public Ticket #2147594
Link "_blank" to single event
Closed

Comments

  •  1
    romain started the conversation

    Hello

    I've set the "open_event_in=single" shortcode for my home page.
    Now events open in a single page. But how could I change the "_blank" link to "_self" link, because I don't want to open a new tab each time ?
    Thanks

  •  894
    Zhivko replied

    Hi,

    Open your theme functions.php file and following filter at the bottom:

    add_action('stec_after_html', function() {
        ?>
        <script type="text/javascript">
            (function ($) {
                $.stecExtend(function (m) {
                    m.eventsHandler.eventToggle = function (e) {
                        window.open(e.data('permalink'), '_self');
                        return false;
                    };
                });
            })(window.jQuery);
        </script>
        <?php
    });

    Stachethemes Developer