Redirect user back to user's profile page

Jul 30, 2007 at 6:44 AM
I need to redirect a user back to their profile page after doing a database update. I saw a discussion entry that suggested using the following line:

"http://www.facebook.com/profile.php?id=" + base.FBService.UserId as the url"

I added this line. It does redirect. However, I get a full facebook page displayed within my existing page. In other words, I have 2 sets of facebook menus and a canvas page within my canvas page.

How do I correct this?

Thanks in advance for your assistance.


Jul 30, 2007 at 2:44 PM
Edited Jul 30, 2007 at 3:15 PM
Hi,

You cannot use response.redirect as ASP is on the server and does not "see" framesets.

You can do the following

FACEBOOK_PROFILE_URL = "http://www.facebook.com/profile.php?id="

Response.Write("<script type=\"text/javascript\">\nif (parent != self) \ntop.location.href = \"" + FACEBOOK_PROFILE_URL + base.FBService.UserId + "\";\nelse self.location.href = \"" + FACEBOOK_PROFILE_URL + base.FBService.UserId + "\";\n</script>");
Response.End();