How to host a site in another site - with little or no coding
- by tunmise fasipe
SUMMARY: All of these happens on Site A
User visits site A
User enter username and password
User click on Login Button
User authenticated on Site B behind the scene
User is shown a page on Site A that contains his/her profile from Site B as layout/styled from Site B
User can click links in the Profile page that links to other area in Site B
Meaning: Session has to be maintained somehow
I have web application where I store users' password and username. If you logon to this site, you can login with the password and username to have access to your profile.
There is another option that requires you to login to my site from your site and have your profile displayed within your site. This is because you might already have a site that your clients know you with.
This link is close to what I want to do: http://aspmessageboard.com/showthread.php?t=235069
A user on Site A login to Site B and have the information on site B showing in site A. He should not know whether Site B exists. It should be as if everything is happening in Site A
This latter part is what I don't know to implement.
I have these ideas:
Have a fixed IFrame within your site to contain my site: but I am concerned about size/layout since different clients have different layout/size for their content section. I am thinking of how to maintain session too
A webservice: I don't know how feasible this is since the Password and ID are on my server. You may have to send them back and forth. It means client would have to code with my API. But I am not just returning data, I have to show them a page that contains the profile details
OpenID, Single-SignOn: Just guessing - but the authentication and data resides on my server. there is nothing to access on your side in this case
Examples: like login into facebook within my site and still be able to do post updates, receive notifications
Facebook implement some of these with IFrame e.g. the Like button
*NOTE: * I have tested the IFrame option. It worked but I still have to remove my site specific content like my page Banner, Side Navigation etc.
I was able to login normally as if I was actually on the site.
This show my GUI but - style sheet was missing - content not styled with CSS - Any relative url won't work. It would look for that resource relative to the current server. Unless I change links to absolute - Clicking on the LogIn button produces this error: The state information is invalid for this page and might be corrupted.
UPDATE:
I was reading about REST webservice few days ago and I got this idea:
What about the idea of returning an XML from a webservice [REST or SOAP] and providing an XSLT (that I can provide) to display it. Thus they won't have to do much coding?