The Web Design Group

... Making the Web accessible to all.

Welcome Guest ( Log In | Register )

> Help with HTML code please, Trying to get my social buttons to open in a new window or tab
trishden
post Apr 16 2012, 11:03 AM
Post #1





Group: Members
Posts: 4
Joined: 16-April 12
Member No.: 16,922



Hi, I'm new to this blogging thing and just had a makeover from a knowledgable web designer. The problem is she set up my social buttons, (facebook, twitter, etc) and they leave my page when clicked on. I would like them to open in a new tab or window. This designer is so busy it take weeks for her to get back to me. I did some research and I think the code needs a target="blank" put somewhere in the code but I'm not sure where. The code is in my sidebar in a text widget and reads as follows:

<center><a href="https://twitter.com/#!/trishden"><img src="http://i939.photobucket.com/albums/ad232/jeags8/twitter1.png"></a>

<a href="https://plus.google.com/117443292363485259367/posts"><img src="http://i939.photobucket.com/albums/ad232/jeags8/google1.png"></a>

<a href="http://www.stumbleupon.com/stumbler/trishden"><img src="http://i939.photobucket.com/albums/ad232/jeags8/stumble_upon.png"></a>

<a href="https://www.facebook.com/pages/A-Fixer-Upper/253768451372938?sk=wall"><img src="http://i939.photobucket.com/albums/ad232/jeags8/facebook_1.png"></a>

<a href="http://feeds.feedburner.com/afixerupper/UiHg"><img src="http://i939.photobucket.com/albums/ad232/jeags8/rss1.png"></a>

<a href="http://digg.com/trishden"><img src="http://i939.photobucket.com/albums/ad232/jeags8/digg1.png"></a>

My site can be found here:
http://afixerupper.com/

Thanks for anyone who has the time to help me. I really appreciate it!

Gratefully,
Trish
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
 
Reply to this topicStart new topic
Replies
pandy
post Apr 16 2012, 11:10 AM
Post #2


🌟Computer says no🌟
********

Group: WDG Moderators
Posts: 20,730
Joined: 9-August 06
Member No.: 6



As with all attributes you put it in the start tag.

CODE
<a href="http://example.com" target="_blank">Link text</a>


Note that target can't be used with a Strict doctype since it's been deprecated for many years. It's kinda outdated, for many reasons. It's usually avoided nowadays so you may just want to leave things as they are. The user has every possibility to open pages in new windows anyway if they prefer, but it isn't as easy to stop new windows from opening if that is forced by the site. Open in same window = everyone can get it how they want it. Open in new window = some people will be unhappy and won't like what you are doing.
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post

Posts in this topic


Reply to this topicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 



- Lo-Fi Version Time is now: 24th April 2024 - 10:47 AM