How to check if a page has been only called from a specific domain
<p>I have given a task as below:</p>

<p>1-- when anyone open my website abc.com it shud be redirected to another domain(xyz.com).</p>

<p>2-- on xyz.com user will enter his username/password which is for this xyz.com (please note username/password is of xyz.com) and after successful authentication the user will be redirected to my website homepage again. this will be domain by xyz.com</p>

<p>3-- now my task is to check if my domain homepage is called from xyz.com successful authentication.</p>

<p>4-- if user goes to any other page on my abc.com website he should not go again to xyz.com for authentication as he has already authenticated... I guess this will be done via cookie.</p>

<p>some sample code will help a alot.</p>

<p>Edit: I dont have any control over xyz.com.. when user is redirect to my domain abc.com I just need to check that did he come from xyz.com or not...</p>
