Hello guys im new to php, maybe my question is just too simple.  

But I wanna know if there is a way to redirect users who open **www.example.com/page.php** to **www.example.com**  

But if they try to open the page from www.example.com , then no redirects and the page loads completly.  

I actually have a from on my home page which it has a button on it and when users click the button they enters www.example.com/page.php  

But I dont want the users to access www.example.com/page.php without clicking on button.  

Can someone show me an example with php codes?