Problem with default Page

This public forum is for user-to-user discussions of PHPMaker. Note that this is not support forum.
Post Reply
Bishu
User
Posts: 427

Problem with default Page

Post by Bishu »

I have 2 custom file
1) home.php ---- I have made this as a default page (Security given to the registered user only)

2) contact.php ---- Security given to the anonymous user.

Now when I open my url, it directly open the contact.php page.
I want to make the login.php page as a default for the anonymous user.


mobhar
User
Posts: 11660

Post by mobhar »

Simply put the following code in "Page_Redirecting" server event under "Server Events" -> "Other" -> "Default Page":

if (!IsLoggedIn()) {
$url = "login.php";
} else {
$url = "home.php";
}


Post Reply