Link openned in a new page

Best WordPress theme for festivals or other events with responsive, clean and unique design.
GK User
Mon May 11, 2015 11:08 pm
Hi,

I use your Fest template and thanks a lot for it :-)

Regarding the link to external page :
- Facebook & Twitter buttons
- Sponsor logo buttons

These link are open in place of my page (same window/tab). Where and how to change to open it in a new window/tab ?

thanks for your help
Gau
User avatar
Fresh Boarder

GK User
Tue May 12, 2015 9:26 am
Hello,

Please edit Fest/gavern/widget.social.php file and change this fragment:
Code: Select all
if($fb_link !== '') echo apply_filters('gk_social_fb_link', '<a href="'.str_replace('&', '&amp;', $fb_link).'" class="gk-facebook-icon">Facebook</a>');
         if($twitter_link !== '') echo apply_filters('gk_social_twitter_link', '<a href="'.str_replace('&', '&amp;', $twitter_link).'" class="gk-twitter-icon">Twitter</a>');


to:
Code: Select all
if($fb_link !== '') echo apply_filters('gk_social_fb_link', '<a href="'.str_replace('&', '&amp;', $fb_link).'" target="_blank" class="gk-facebook-icon">Facebook</a>');
         if($twitter_link !== '') echo apply_filters('gk_social_twitter_link', '<a href="'.str_replace('&', '&amp;', $twitter_link).'" target="_blank" class="gk-twitter-icon">Twitter</a>');


in your sponsors code, you have to add attribute
Code: Select all
target="_blank"
to your links
Code: Select all
<a href=".." target="_blank"> ..</a>
User avatar
Moderator

GK User
Wed May 13, 2015 5:38 pm
Hi,

Thanks for your quick reply.
I'll do the modification soon and re-contact you if any problems.

Have a good day

Gauthier
User avatar
Fresh Boarder


cron