Solved

Sharing ASP Code Library Between Subdomains

Posted on 2007-11-18
6
577 Views
Last Modified: 2013-11-13
Hi.

I have one master website (mydomain.co.uk), and am building a regionalised website network.  There will be a separate website for each region:

london.mydomain.co.uk
birmingham.mydomain.co.uk
etc

There will be close to 40 subdomains in all.

There will be a central database, and central admin/cms system, but each sub domain will display content relevant to the region/sub domain.

I have not much experience with sub domains, and as this is a large project with minimal staffing, I need to get this right.  I need to minimize the amount of administration and coding work that is subsite-dependent.  For example I don't want to maintain separate sub folders of asp include files (my code library).  I want to use a central location that all sub domains can access, without jeopardizing the folder security on the web server.

The web server is iis6 running on a win2003 box, and the application is Classic ASP / SQL 2000.  

My questions really are:

1) Is there a better overall solution to what I am trying to achieve?
2) How can I safely share a common library of application files (css, js, asp, graphics)
3) Maintain a separate application (global.asa) for each sub domain, but also utilize a central global.asa?

Thanks,

TheFoot
0
Comment
Question by:Barry Jones
  • 3
  • 3
6 Comments
 
LVL 25

Expert Comment

by:kevp75
ID: 20310120
1-2) You could run everything from the database.  Store your individual site configurations in individual XML files.  Do some url REWriting so no-one sees that you are running a centralized app
3) I would stay away form using a global.asa file...too many issues with events not firing when they should
0
 
LVL 12

Author Comment

by:Barry Jones
ID: 20311493
Thanks for your reply.

That makes sense.  How does URL rewriting affect search engines and seo?  Do you also mean to store graphics and the actual asp include files as binary in the database?  I couldnt store all of them, and it wouldnt make sense to store some, but not all.  How do I rewrite URLs in IIS anyhow?

I see the advantage in storing global app configuration as xml or whatever, as opposed to global.asa.  I would still need individual global.asa's for session stuff no?

TheFoot
0
 
LVL 25

Accepted Solution

by:
kevp75 earned 500 total points
ID: 20316276
No, I wouldn't store any file in the database....too much of a hit on the server.  I meant configuration options, page content, etc...

You would need seperate global.asa files only if you are going to use multiple code bases.  If you use a single code base, you'll only need one  (still wouldn't recommend using it though...)

URL rewriting will make the pages more SEO, as instead of having youpage.asp?compID=MyVersionOfTheApp&myID=123&blah=blah, it tones them down to /youpage.asp  (and most of the time, you can make it spoof a directory, so it would become /yourpage/)
0
Windows Server 2016: All you need to know

Learn about Hyper-V features that increase functionality and usability of Microsoft Windows Server 2016. Also, throughout this eBook, you’ll find some basic PowerShell examples that will help you leverage the scripts in your environments!

 
LVL 12

Author Comment

by:Barry Jones
ID: 20316728
Ok I understand.  That happens to some degree now, except that I use global.asa for constant values, and session variables.

I will look into this URL rewriting a bit more - thanks for the advice.  Any ideas on how to share the application files?  Specifically I need to share javascript files, css files and asp code libraries.  I only want to store them in one location, and have all subdomains have access to them.

Thanks, TheFoot
0
 
LVL 12

Author Comment

by:Barry Jones
ID: 20345551
OK I am going to store all shared code in a subdomain, and map a virtual directory called "code" to it from each other subdomain.  That should work shouldn't it?

TheFoot
0
 
LVL 25

Expert Comment

by:kevp75
ID: 20345766
it should do the trick
0

Featured Post

Comprehensive Backup Solutions for Microsoft

Acronis protects the complete Microsoft technology stack: Windows Server, Windows PC, laptop and Surface data; Microsoft business applications; Microsoft Hyper-V; Azure VMs; Microsoft Windows Server 2016; Microsoft Exchange 2016 and SQL Server 2016.

Question has a verified solution.

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

"Disruption" is the most feared word for C-level executives these days. They agonize over their industry being disturbed by another player - most likely by startups.
Learn how ViaSat reduced average response times for IT incidents from 10 minutes to 30 seconds.

856 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