473,763 Members | 6,638 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

MasterPageFile problem - accessing another website

Hi All,

I wanted to set up my websites like this

c:\websites\int ranettemplate
c:\websites\app 1
c:\websites\app 2

Basically I wanted to have the master pages defined in the template
folder and all other apps would "reference" this folder to get the
appropriate master file that they need to include in their page.

Problem is this...I tried using
MasterPageFile= "../app1/MasterPage1.mas ter"
and i get an error saying that i am trying to access a master file in
another directory and this is not allowed.

Is this a security problem in IIS/Web Server that comes with VS.NET
2005 Web Developer Edition Beta or is it a restriction of the framework
i.e. must the master be in your website?

Any help would be greatly appreciated.

Thank you.

Reeza.

Nov 19 '05 #1
4 1610
Just like pages, master files must reside in the application directory somewhere.
I saw someone else post somewhere about a hack you could do to centralize
the location of files across multiple applications, but I can't recall where
I saw it.

-Brock
DevelopMentor
http://staff.develop.com/ballen
Hi All,

I wanted to set up my websites like this

c:\websites\int ranettemplate
c:\websites\app 1
c:\websites\app 2
Basically I wanted to have the master pages defined in the template
folder and all other apps would "reference" this folder to get the
appropriate master file that they need to include in their page.

Problem is this...I tried using
MasterPageFile= "../app1/MasterPage1.mas ter"
and i get an error saying that i am trying to access a master file in
another directory and this is not allowed.
Is this a security problem in IIS/Web Server that comes with VS.NET
2005 Web Developer Edition Beta or is it a restriction of the
framework i.e. must the master be in your website?

Any help would be greatly appreciated.

Thank you.

Reeza.


Nov 19 '05 #2
I saw that post somewhere too and can't find it.

I believe it was the same trick used to share user controls, that is
create a virtual directory (non-application vdir) as a subfolder and
point it to a physical directory of master pages.

--
Scott
http://www.OdeToCode.com/blogs/scott/

On Mon, 02 May 2005 08:39:58 -0700, Brock Allen
<ba****@NOSPAMd evelop.com> wrote:
Just like pages, master files must reside in the application directory somewhere.
I saw someone else post somewhere about a hack you could do to centralize
the location of files across multiple applications, but I can't recall where
I saw it.

-Brock
DevelopMento r
http://staff.develop.com/ballen
Hi All,

I wanted to set up my websites like this

c:\websites\int ranettemplate
c:\websites\app 1
c:\websites\app 2
Basically I wanted to have the master pages defined in the template
folder and all other apps would "reference" this folder to get the
appropriate master file that they need to include in their page.

Problem is this...I tried using
MasterPageFile= "../app1/MasterPage1.mas ter"
and i get an error saying that i am trying to access a master file in
another directory and this is not allowed.
Is this a security problem in IIS/Web Server that comes with VS.NET
2005 Web Developer Edition Beta or is it a restriction of the
framework i.e. must the master be in your website?

Any help would be greatly appreciated.

Thank you.

Reeza.



Nov 19 '05 #3
I think this is it....but i cannot find the dll for the website

http://www.codeproject.com/aspnet/ctrlreuse.asp

Nov 19 '05 #4
Also:

http://blogs.msdn.com/adamga/archive...12/407631.aspx

--
Scott
http://www.OdeToCode.com/blogs/scott/

On 3 May 2005 08:03:45 -0700, "reez" <re******@gmail .com> wrote:
I think this is it....but i cannot find the dll for the website

http://www.codeproject.com/aspnet/ctrlreuse.asp


Nov 19 '05 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
3593
by: Generic Usenet Account | last post by:
I am trying to create a Java application that reads a list of URLs from a file and stores their contents on the local file system. I have succeeded in accessing normal websites, but I am unable to access the secured websites (using the HTTPS protocol) using this approach. I would greatly appreciate if someone could suggest a way out. I have looked at the HttpsURLConnection class, but unfortunately this class is abstract.
36
16410
by: Thomas | last post by:
after spending countless hours trying, i give up and hope to get some help in here. on server1 i got the web myweb.com with my test.asp. in the test.asp, i'm trying to read a file from an UNC path with a FSO: Set myFile = Server.CreateObject("Scripting.FileSystemObject").GetFile("\\server2\myshare\myfile.txt") this fails with an Permission Denied. here's the deal:
9
1959
by: Justin Engelman | last post by:
Hi, I have a website that uses an ISAPI filter that will redirect anyone going to any page on the site to an SSL login page (on a different website with the same root domain) if they do not have the appropriate session cookie already. After logging in on that page successfully they are given the cookie and redirected back to the page they initially tried to go to. I would like to create a Windows application that gets data from that...
1
2127
by: Alexander Widera | last post by:
Is the a possibility to write the masterpages for different browsers into the web.config, so that i havn't to write in every single page e.g. ie:MasterPageFile=".." mozilla:MasterPageFile="..." ..... ? Thanks for help. Alex
0
1196
by: Brian Orrell | last post by:
I have set the masterPageFile property in my web.config as follows: <pages masterPageFile="~/Main.master" > When I create a webform and I don't specify a masterPageFile in the aspx (so that it uses the web.config specified master) and I go into design view for the aspx, I get the following error: Error Creating Control - Content Content controls can only be used in a content page
1
5779
by: meade | last post by:
Hi there, I was wondering if it's possible to display today's date on a website without accessing the visitor's computer? Internet Explorer gives me a warning that the site is trying to access my computer, so obviously I don't want my visitors to come across the same problem. I have no idea where to start and could really use some help with it! Thanks in advance! Maggie
1
1126
by: Alan Silver | last post by:
Hello, I have a site that uses master pages. To enable simple switching of the master page, and to avoid potential inconsistencies between pages, I set the master page file in the web.config file. This works fine, but causes VWD to give loads of bogus validation errors ("element HTML occurs to few times" etc), as it doesn't seem to know that there's a master file being used. Any way around this? TIA
3
4185
by: Greg Collins [Microsoft MVP] | last post by:
I'm looking to discover in what event I can programmatically set this.MasterPageFile for a master page. Documentation states that this property must be set in the PreInit or before, but master pages don't have a PreInit event -- just an Init event. So what event is available to a master page that comes before PreInit that can be used to programmatically set the MasterPageFile property? Thanks in advance! -- Greg Collins
3
5644
by: Nathan Sokalski | last post by:
When I attempt to access a Microsoft Access database from my website, I recieve the following error: Server Error in '/' Application. -------------------------------------------------------------------------------- Security Exception Description: The application attempted to perform an operation not allowed by the security policy. To grant this application the required permission please contact your system administrator or change the...
0
10148
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
9938
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9823
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
8822
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7368
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6643
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5270
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5406
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
3
2794
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.