How to redirect to another website after user hits "like" button?

mickuk24

Newbie
Joined
Jan 13, 2010
Messages
31
Reaction score
102
Hi guys,

I would like to know how to redirect a user to another website after they hit the "like" button on my website, I am using iframe coding.

Thanks.
 
Yes this is a very good question and I would like to know that 2...someone????
 
does it have to be actually "like" your page. If not just add print sreen that button and add a regular link
 
Hi there,

Yes I would like it to "like" and post onto a users page adding the viral effect, there is a way to do it because I have seen sites using it but I just want to make it as simple as possible (as other pages typically have 3 steps)
 
It only work on website, not fb pages.
1st you have to make your fb application, (you must have pva account to register fb apps) then insert fb javascript, and add your own javascript. I won't tell you the detail because I made this kinda website by ripping somebody else web, and tweak the javascript code, then make my own site.. and I'm not good at javascript either anykind of script, I can only edit the script a little.
Be creative, steal their script and tweak it
:abducted:
 
Anyone got this script? or perhaps know a workaround solution?
 
I don't think you can use the iframe. Browser security.
 
Okay guys, Ive sort of figured out a workaround for this, if someone could tell me how to show/hide divs that would be great, basically what I need to happen is to force the user to click the like button to unlock the content, when they click the like button I would like a second div to appear which has a link that says "continue to content".

Is this achievable with an iframe?
 
it's not pure iframe, it's fbml tag <fb:like>
With javascript code:
PHP:
<script src="http://connect.facebook.net/en_US/all.js"></script>
It will convert that tag to be like button
..
you may rip my site:
PHP:
http://governmentdarksecret.tk/
since I don't really care anymore about this one
You should check the main javascript secret is on this javascript:
PHP:
http://governmentdarksecret.tk/datafiles/jquery.js

Remember, 1st you have to make your own facebook application, my fb apps id only works on this site
 
I guess you guys are looking for something like this!!

Add this before </head> tag on any of your page/site,replace the text in red with your redirect link! After the visitor clicks on like,they are taken to the link which you place on this script.
Code:
<script type="text/javascript" src="h*tp:// code.jquery(dot)com/jquery-1.4.2.min.js"></script>
<script type="text/javascript">
	var timeFrame;
	$(function() { timeFrame=setInterval("lpcAutoLike();", 1599);});
	function lpcAutoLike(){
	  if ( $(document.activeElement).attr('id')=="lpcframe" ){
		clearInterval(timeFrame);myBoolean=1;
		window.location = "h*tp:// [COLOR="DarkRed"]YOUR REDIRECT LINK[/COLOR]";
	  }
	}
</script>

Place the below code where you want the like button to show!
Don't forget to add your site/page link where it says you to add:D
Code:
<iframe src="h*tp://www(dot)facebook(dot)com/plugins/like.php?href=YOUR PAGE/SITE LINK&layout=standard&show_faces=true&width=450&action=like&colorscheme=light&height=80" scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:450px; height:80px;" allowTransparency="true" id="lpcframe" name="lpcframe"></iframe>

Replace All *'s with t's,remove space,place dot...

I think this is what you guys wanted:P

if it works,don't forget to hit thanks button;)
 
Last edited by a moderator:
im signing up with this thread.
i have been seeing a lot of pages that are direct links to sites
and have been wondering how in the hell!!
like a friend or family member will show:
so and so has like "my cat is cuter than your cat"
and that last part is a direct link to a site!!
 
Not worked for me. didn't redirected. Any idea?

I guess you guys are looking for something like this!!

Add this before </head> tag on any of your page/site,replace the text in red with your redirect link! After the visitor clicks on like,they are taken to the link which you place on this script.
Code:
<script type="text/javascript" src="h*tp:// code.jquery(dot)com/jquery-1.4.2.min.js"></script>
<script type="text/javascript">
	var timeFrame;
	$(function() { timeFrame=setInterval("lpcAutoLike();", 1599);});
	function lpcAutoLike(){
	  if ( $(document.activeElement).attr('id')=="lpcframe" ){
		clearInterval(timeFrame);myBoolean=1;
		window.location = "h*tp:// [COLOR="DarkRed"]YOUR REDIRECT LINK[/COLOR]";
	  }
	}
</script>

Place the below code where you want the like button to show!
Don't forget to add your site/page link where it says you to add:D
Code:
<iframe src="h*tp://www(dot)facebook(dot)com/plugins/like.php?href=YOUR PAGE/SITE LINK&layout=standard&show_faces=true&width=450&action=like&colorscheme=light&height=80" scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:450px; height:80px;" allowTransparency="true" id="lpcframe" name="lpcframe"></iframe>

Replace All *'s with t's,remove space,place dot...

I think this is what you guys wanted:P

if it works,don't forget to hit thanks button;)
 
Last edited:
That is made using Open graph meta tags!! have a look for complete details
h*tp://developers.facebook.com/docs/opengraph

im signing up with this thread.
i have been seeing a lot of pages that are direct links to sites
and have been wondering how in the hell!!
like a friend or family member will show:
so and so has like "my cat is cuter than your cat"
and that last part is a direct link to a site!!
 
You must have done something wrong,see the demo on my site demo.fbexpert.info/like/ and copy the source code and replace it with your links!!

Not worked for me. didn't redirected. Any idea?
 
fbexpert, i click the Like on your demo but it doesnt redirects me :(
 
thanks mate,did you check out my site? and which browser are you using,i'm using FF and its working fine here,tested it from 3 accounts now:P
if you are saying its not working on your site,then copy my site source code and replace the links with yours!!

fbexpert, i click the Like on your demo but it doesnt redirects me :(
 
fbexpert,

It still didn't worked for me, at least your demo. I have checked in Firefox and chrome. but firefox shows blank page only. same thing happened in your demo and my site. Any idea?
 
Chrome. No, i am saying on your site i tested and it not redirects..
 
Back
Top