Web Application Architecture Problem

Posted on 2008-02-08
Medium Priority
Last Modified: 2010-04-14
Hi all,

BusinessLogicLayer (C# Class Library)
DataAccessLayer (C# Class Library)
Website1.UI (website1.domainname.com)
Website2.UI (website2.domainname.com)
Website3.UI (website3.domainname.com)

I am developing an application where a user will log into a website and depending on the users login details they will be redirected to a particular section of the application. The application is very large and I would ideally like to split the sections into separate websites. Therefore the user will log into a website and then be redirected to the site that they have access right too. The application is far too large to just have separate sub directories in one website and use web.config files to handle authorisation and I would like to use the following standard architecture to achieve the goal of separation and easy build and maintenance of projects.

However I have a few questions regarding this solution:

1)      Once logged into one website how do you pass authentication across to another site?
2)      All sites share common UI elements such as style sheets, master pages etc. How can this be achieved?
3)      Is this architecture the wrong solution for the project? If so does anybody have any recommendations?

Many thanks

Question by:Cragly
  • 3
  • 2

Expert Comment

ID: 20849784
Nope this Structure is not wrong,

How ever you should try and setup your application like this

MasterApplication (this will handle all your authentication)
--- SubSite (subdomain1.yoursite.com)
--- SubSite (subdomain2.yoursite.com)
--- SubSite (subdomain3.yoursite.com)
Which means all this three application are using web.config file of their own and the master web.config


Author Comment

ID: 20851366
thanks for getting back to me so quickly.

How would this be structured in Visual Studio? If possible I would of liked to keep the websites in thier own projects so that they can be built and maintained independantly so I could make changes to one site and just deploy that sites new dll. Is this possible?


Expert Comment

ID: 20851478
what version of Studio Are you using ?

First you should open a Solution (mind you not a project, you should find that under Other Project Types)

then Under that solution add a new Web Project say MyMaster, HTTP, VB or C# as per your choice localhost/myMaster

then add a new webproject say myChildOne, HTTP, VB or C# as per your choice, Localhost.myMaster/MyChildOne

and so on.


Author Comment

ID: 20852997
I am using VS 2008

I am not sure what you mean. Are you saying that I have a solution l like this:

   MyMaster (Website)
   MyChildOne (Website)
   MyChildTwo (Website)

Then within IIS have the sites set up as a virtual directories under the MyMaster website?
How would authentication work between the sites. If you logged into the main site and then be redirected does the authentication remain? Or do I loose it?

Many thanks

Accepted Solution

hemaldesai earned 2000 total points
ID: 20857405
You should use Master Sites Application Scope for your varialbles.

or Pass a Authentation token in Query String.


Featured Post

Never miss a deadline with monday.com

The revolutionary project management tool is here!   Plan visually with a single glance and make sure your projects get done.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

A long time ago (May 2011), I have written an article showing you how to create a DLL using Visual Studio 2005 to be hosted in SQL Server 2005. That was valid at that time and it is still valid if you are still using these versions. You can still re…
Simulator games are perfect for generating sample realistic data streams, especially for learning data analysis. It is even useful for demoing offerings such as Azure stream analytics, PowerBI etc.
This is Part 3 in a 3-part series on Experts Exchange to discuss error handling in VBA code written for Excel. Part 1 of this series discussed basic error handling code using VBA. http://www.experts-exchange.com/videos/1478/Excel-Error-Handlin…
Get the source code for a fully functional Access application shell with several popular security features that Access VBA application developers desire, but find difficult or impossible to figure out how to code. You get the source code for managi…
Suggested Courses

601 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question