asp.net - How to open the Facebook login window in new Tab on clicking the Like Button -
how can open facebook
window in new tab
instead of opening in new window
?
my html below
<div style="position: relative; top: 3px;" id="likebutton"> <iframe frameborder="0" scrolling="no" allowtransparency="true" style="border: none; overflow: hidden; width: 260px; height: 35px;" src="http://www.facebook.com/plugins/like.php?href=http:\\localhost\login.aspx|@&send=false&layout=button_count&width=100& show_faces=false&action=like&colorscheme=light&font=arial&height=35"> </iframe> </div>
issue is - on clicking like button
, opens facebook
login window in new window. how can open in new tab
my jsfiddle here
try code, working me.
<a style="position: absolute; top:0px; left: 0px; width:100px; height:40px; cursor:pointer;" href="https://www.facebook.com/login.php?skip_api_login=1&display=popup&social_plugin=like&external_page_url=http%3a%2f%2finvalid.invalid%2f&next=http%3a%2f%2fwww.facebook.com%2fconnect%2fuiserver.php%3fmethod%3dopt.inlike%26app_id%3d127760087237610%26display%3dpopup%26social_plugin%3dlike%26secure%3dfalse%26protocol%3dhttp%253a%26external_page_url%3dhttp%253a%252f%252finvalid.invalid%252f%26from_login%3d1%26client_id%3d127760087237610&rcount=1" target="_blank"></a> <div style="position: ansolute; top: 0px;z-index:0; cursor:pointer;" id="likebutton"> <iframe frameborder="0" scrolling="no" allowtransparency="true" style="border: none; overflow: hidden; width: 260px; height: 35px;z-index: 0;" src="http://www.facebook.com/plugins/like.php?href=http:\\localhost\login.aspx|@&send=false&layout=button_count&width=100& show_faces=false&action=like&colorscheme=light&font=arial&height=35"></iframe> </div>
working example : http://jsfiddle.net/jpwcf/
change external_page_url parameter href.
Comments
Post a Comment