Title: Social Button links
Last modified: August 21, 2016

---

# Social Button links

 *  Resolved [l w](https://wordpress.org/support/users/leslielaortedu/)
 * (@leslielaortedu)
 * [12 years, 8 months ago](https://wordpress.org/support/topic/social-button-links/)
 * Social Button links are set to “_blank” but they are defaulting to “_self”
 * What is causing this?
 * [http://wordpress.org/plugins/wp-topbar/](http://wordpress.org/plugins/wp-topbar/)

Viewing 5 replies - 1 through 5 (of 5 total)

 *  Plugin Author [rfgoetz](https://wordpress.org/support/users/rfgoetz/)
 * (@rfgoetz)
 * [12 years, 8 months ago](https://wordpress.org/support/topic/social-button-links/#post-4076245)
 * Thanks — found a defect.
 * look in wp-topbar.php
 * There are two places that you have to change this:
 * `echo '<a href="'.$wptbOptions['social_icon'.$i.'_link'].'" target="_'.$wptbOptions['
   link_target'].'"><img src="'.$wptbOptions['social_icon'.$i.'_image'].'" style
   ="'.trim($wptbOptions['social_icon'.$i.'_css']).'"/></a>';`
 * to this:
 * `echo '<a href="'.$wptbOptions['social_icon'.$i.'_link'].'" target="_'.$wptbOptions['
   social_icon'.$i.'_link'_target].'"><img src="'.$wptbOptions['social_icon'.$i.'
   _image'].'" style="'.trim($wptbOptions['social_icon'.$i.'_css']).'"/></a>';`
 * Again, you have to do this in two places.
 * I will fix it in the next release.
 * Thanks for finding this!
 *  Thread Starter [l w](https://wordpress.org/support/users/leslielaortedu/)
 * (@leslielaortedu)
 * [12 years, 8 months ago](https://wordpress.org/support/topic/social-button-links/#post-4076317)
 * Thanks, Bob but Dreamweaver shows the new line of code as an error. What can 
   be causing that?
 *  Plugin Author [rfgoetz](https://wordpress.org/support/users/rfgoetz/)
 * (@rfgoetz)
 * [12 years, 8 months ago](https://wordpress.org/support/topic/social-button-links/#post-4076351)
 * Hmm.. try this… single quote was in the wrong place.
 *     ```
       echo '<a href="'.$wptbOptions['social_icon'.$i.'_link'].'" target="_'.$wptbOptions['social_icon'.$i.'_link_target'].'"><img src="'.$wptbOptions['social_icon'.$i.'_image'].'" style="'.trim($wptbOptions['social_icon'.$i.'_css']).'"/></a>';
       ```
   
 * I’ll be posting a new version with this fix over the weekend.
 * Bob
 *  Thread Starter [l w](https://wordpress.org/support/users/leslielaortedu/)
 * (@leslielaortedu)
 * [12 years, 8 months ago](https://wordpress.org/support/topic/social-button-links/#post-4076352)
 * That did it, Bob! Thank you.
 *  Plugin Author [rfgoetz](https://wordpress.org/support/users/rfgoetz/)
 * (@rfgoetz)
 * [12 years, 8 months ago](https://wordpress.org/support/topic/social-button-links/#post-4076403)
 * Great!

Viewing 5 replies - 1 through 5 (of 5 total)

The topic ‘Social Button links’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/wp-topbar_706d6d.svg)
 * [WP-TopBar](https://wordpress.org/plugins/wp-topbar/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/wp-topbar/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/wp-topbar/)
 * [Active Topics](https://wordpress.org/support/plugin/wp-topbar/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/wp-topbar/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/wp-topbar/reviews/)

## Tags

 * [_blank](https://wordpress.org/support/topic-tag/_blank/)

 * 5 replies
 * 2 participants
 * Last reply from: [rfgoetz](https://wordpress.org/support/users/rfgoetz/)
 * Last activity: [12 years, 8 months ago](https://wordpress.org/support/topic/social-button-links/#post-4076403)
 * Status: resolved