Multiple web-apps under one master page site?

G

Guest

Hi

I've just recently upgraded to VS2005 and started using/learning about the
Master Pages.

I'd like to know if it is possible to have separate web app projects use the
master page(s) from their "parent" site.

E.g.:
Main site at http://localhost/mainsite/
sub-app at http://localhost/subsite/

I'm considering using masterpages for our company website overhaul, so these
development locations would eventually map to the real locations of:
main site: http://www.myrealsite.com
sub-app: http://www.myrealsite.com/sub-app-name

(We host our site ourselves)

My reason for asking is motivated by the pre-compiled/site publishing
process of VS2005, which wants to delete any existing target files before
transferring the new versions. For a moderate or larger sized site this
would not be a desirable feature, even if it is quick in operation.

For example, I want to create a separate project/app that looks after a
specific requirement (say a questionairre, or quality feedback forms) that
uses the same master page(s) as the root site.

I guess I'm asking if it's possible to implement similar referential pathing
as I'm used to with stylesheets, etc (e.g. ../styles/global.css)? The
default pathing is app-specific (~/).

I've tried <%@ Page Language="VB" MasterPageFile="../copeohs/copeohs.master"
....
but get the server error of "The virtual path '/copeohs/copeohs.master' maps
to another application, which is not allowed."

Also tried: MasterPageFile="http://localhost/copeohs/copeohs.master"
but this returns "Parser Error Message:
'http://localhost/copeohs/copeohs.master' is not a valid virtual path." (The
path is correct but I assume this is IIS security preventing user-client
delivery of the master file.)

I don't want to use templates, as the idea is to have the masterpages hold
the menu content and thus greatly reduce maintenance requirements. I would
be using a root master for the global menu, plus nested master pages to
provide sub-section menus.

I've done some googling on the subject, but haven't (yet) come across anyone
discussing the particular aspect of separate projects sharing the master file.

Is it even possible - or am I barking up the wrong tree?

Appreciate any pointers to articles, etc, or specific methods.

Thanks.
 
A

Alec MacLean

Thanks Peter - that article has really helped.

Although parts 2 & 3 ar not yet writtne, it's provided enough background for
me to get the sub-site operating with the master pages held in the root
site, which is what I needed.

Thanks again.

Al
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,770
Messages
2,569,583
Members
45,075
Latest member
MakersCBDBloodSupport

Latest Threads

Top