Custom Login Page Per Domain?

Discussions on webmail and the Professional version.
Post Reply
Sploit

Custom Login Page Per Domain?

Post by Sploit » Sat Sep 28, 2002 6:34 am

How would i be able to have a custom login page depending on which domain the user is coming from?
Ehhh?
Because lets say I virtually host multiple domains, And i want the mail.customersdomain.com to pull their own logo.
???
Any suggestions?

totomds
Posts: 24
Joined: Thu Aug 08, 2002 11:22 am

Post by totomds » Fri Oct 04, 2002 9:45 am

First I would suggest you learn some manners, and not make such a rude and informal post. Second, I suggest you learn html and asp to do what you want.

-toto

Guest

Post by Guest » Fri Oct 04, 2002 10:44 am

Totomds, while Sploit's post may have been "informal", yours is the rudest one I've ever read here. Please tone the attitude down, this forum is for people who need support, not abuse.

sunpost
Posts: 438
Joined: Wed Sep 04, 2002 3:04 pm

Post by sunpost » Fri Oct 04, 2002 12:54 pm

how about forcing the skin to the domain of the user...setting the session variable for the skin in the login.asp script...

Code: Select all

session("skin") = "/mewebmail/base/default/skins/" & Request.ServerVariables("SERVER_NAME") & "/"
remove all the code that allows the user to select the skin and the code that sets a cookie for the skin.

create a skin folder for each (sub)domain...such as mail.customersdomain.com, mail.customersdomain2.com...mail.customersdomainN.com.

this is only an informal suggestion-i did not test this idea--please excuse my manners...if you are not comfortable or so rudely did not learn asp let me know and i will walk you thru it without a f@#$ing arrogant attitude :wink:

sploit

Thanks for your help

Post by sploit » Sat Oct 12, 2002 8:59 am

Thanks for you help. That is the first flame I have gotten for asking a question.. LOL

Anyways, I was thinking if you could get mail enable to use dns to check to see what domain is accessing the mail server, it could go to a custom page for them. I am learning asp, but again, I am a newbie at asp. If anybody has done this, can they help me.

sunpost
Posts: 438
Joined: Wed Sep 04, 2002 3:04 pm

Post by sunpost » Sat Oct 12, 2002 12:32 pm

too bad it was a lame flame for your first :!:

this is how you might go about coding what you are asking for...in the default.asp page...

Code: Select all

Select Case Request.ServerVariables("SERVER_NAME")
	Case "mail.customersdomain1.com"
		Server.Transfer("customersdomain1.com.asp")
	Case "mail.customersdomain2.com"
		Server.Transfer("customersdomain2.com.asp")
	Case "mail.customersdomain3.com"
		Server.Transfer("customersdomain3.com.asp")
	Case Else
		Server.Transfer("error.asp")
End Select
the Request.ServerVariables("SERVER_NAME") returns the dns... Server.Transfer("customersdomain1.com.asp") will redirect to the specified page(iis5.0), use response.redirect("customersdomain1.com.asp") for iis < v5.0

good luck.

Sploit

I found a way to do it... but i will look into your way also

Post by Sploit » Sat Oct 12, 2002 1:42 pm

The way I found to do it, was to replicate the folder structure of the mail enable website as the secondary website.

I then copied login.asp and made a login2.asp (With the custom login prompt)

Also, I copied Default.asp and Made another one called default2.asp (These are just examples)

Then, In Internet Information Services, I made the secondary website (The Second Domain) Point to default2.asp, which then loads login2.asp (Which is the custom domain)

The only thing extra that the second domain needs, is a virtual site under it, replicating MEWEBMAIL directory of the first site (So it can find its files)

I can create a walkthrough visually if anybody wants it

It was fun learning it ;) :D

Post Reply