472,956 Members | 2,614 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 472,956 software developers and data experts.

How to manage a library of web pages? (best practice?)

Hi,

Is there a better (best practice) way to do this?

I have developed a large set of ASP.NET applications in C#. Like
most applications I have a set of utility pages that can be called by
applications or directly by users. On my own I have developed a
technique to manage the application and lib directories, but it seems a
little awkward. I was wondering how other people handle this.
My Directory Organization:
--------------------------

wwwroot\app_dir_1
\app_dir_2
\app_dir_3

wwwroot\lib\lookup
\TimedPopup
\MessageBox
\...and so on...
My Web.config file:
--------------------

In the wwwroot directory I have created a Web.config file put the
following entry in it.

<appSettings>
<add key="LibraryPagesBaseURL"
value="http://127.0.0.1/Lib/"/>
</appSettings>
My Global.asax.cs file:
-----------------------

I have added the following code to each Global.asax.cs file.

public class Global : System.Web.HttpApplication
{
public static string strLibPath =
System.Configuration.ConfigurationSettings.AppSett ings.Get
("LibraryPagesBaseURL");
}
My applications then used Global.strLibPath to reference pages in the
Lib directory.

Is there a more standard way to do this?

Thanks,
John

Nov 19 '05 #1
1 1194
Hi John:

I don't think there has been any best practices or easy methods put
forth to achieve what you need (share aspx across applications).
Server controls offer the best in modularity - if you can package your
functionality into one
(http://msdn.microsoft.com/library/de...mscontrol.asp).
The drawback is that they can be a little harder to develop.

--
Scott
http://www.OdeToCode.com/blogs/scott/
On 7 Apr 2005 11:49:23 -0700, "JohnH." <jo**@jrcc.net> wrote:
Hi,

Is there a better (best practice) way to do this?

I have developed a large set of ASP.NET applications in C#. Like
most applications I have a set of utility pages that can be called by
applications or directly by users. On my own I have developed a
technique to manage the application and lib directories, but it seems a
little awkward. I was wondering how other people handle this.
My Directory Organization:
--------------------------

wwwroot\app_dir_1
\app_dir_2
\app_dir_3

wwwroot\lib\lookup
\TimedPopup
\MessageBox
\...and so on...
My Web.config file:
--------------------

In the wwwroot directory I have created a Web.config file put the
following entry in it.

<appSettings>
<add key="LibraryPagesBaseURL"
value="http://127.0.0.1/Lib/"/>
</appSettings>
My Global.asax.cs file:
-----------------------

I have added the following code to each Global.asax.cs file.

public class Global : System.Web.HttpApplication
{
public static string strLibPath =
System.Configuration.ConfigurationSettings.AppSett ings.Get
("LibraryPagesBaseURL");
}
My applications then used Global.strLibPath to reference pages in the
Lib directory.

Is there a more standard way to do this?

Thanks,
John


Nov 19 '05 #2

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

Similar topics

1
by: jason | last post by:
Access 2000 I would like to be able to generate table reports listing all the TABLE NAMES, FIELDS and their datatypes in a neatly formatted table. Additionally I am building up a frightening...
43
by: Steven T. Hatton | last post by:
Now that I have a better grasp of the scope and capabilities of the C++ Standard Library, I understand that products such as Qt actually provide much of the same functionality through their own...
136
by: Matt Kruse | last post by:
http://www.JavascriptToolbox.com/bestpractices/ I started writing this up as a guide for some people who were looking for general tips on how to do things the 'right way' with Javascript. Their...
19
by: Deniz Bahar | last post by:
Hi, I would like to call one of my functions the exact name as an existing C library function (for example K&R2 exercises asks me to make an atof function). If I don't include the header with...
2
by: nyhetsgrupper | last post by:
Hi, Are you using the Microsoft enterpise library? I am considdering using this in a new project. I am specialy interested in the Logging, database, and exception modules. Anyone having experience...
24
by: Earl | last post by:
I have all of my data operations in a separate library, so I'm looking for what might be termed "best practices" on a return type from those classes. For example, let's say I send an update from...
2
by: sabbadin12 | last post by:
Hi, I'm going to work on an application that uses a postgreSQL database so that it can uses SQLServer 2005. I think I solved most problems on the programming side, but I still have some doubts...
0
by: kirk | last post by:
I have three events that I have created and manage with timers. Two of the timer event handlers, the last two in the code below, need to reset state management data, if the first event handler...
17
by: henry | last post by:
Folks Here's a skeleton, generic HTML page, call it "index.php". You'll see a bit of php code in the middle: <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"...
2
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 4 Oct 2023 starting at 18:00 UK time (6PM UTC+1) and finishing at about 19:15 (7.15PM) The start time is equivalent to 19:00 (7PM) in Central...
2
by: giovanniandrean | last post by:
The energy model is structured as follows and uses excel sheets to give input data: 1-Utility.py contains all the functions needed to calculate the variables and other minor things (mentions...
4
NeoPa
by: NeoPa | last post by:
Hello everyone. I find myself stuck trying to find the VBA way to get Access to create a PDF of the currently-selected (and open) object (Form or Report). I know it can be done by selecting :...
3
NeoPa
by: NeoPa | last post by:
Introduction For this article I'll be using a very simple database which has Form (clsForm) & Report (clsReport) classes that simply handle making the calling Form invisible until the Form, or all...
1
by: Teri B | last post by:
Hi, I have created a sub-form Roles. In my course form the user selects the roles assigned to the course. 0ne-to-many. One course many roles. Then I created a report based on the Course form and...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 1 Nov 2023 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM) Please note that the UK and Europe revert to winter time on...
3
by: nia12 | last post by:
Hi there, I am very new to Access so apologies if any of this is obvious/not clear. I am creating a data collection tool for health care employees to complete. It consists of a number of...
0
NeoPa
by: NeoPa | last post by:
Introduction For this article I'll be focusing on the Report (clsReport) class. This simply handles making the calling Form invisible until all of the Reports opened by it have been closed, when it...
2
by: GKJR | last post by:
Does anyone have a recommendation to build a standalone application to replace an Access database? I have my bookkeeping software I developed in Access that I would like to make available to other...

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.