I am (and have been trying!) to find a good way to do the following few
things:
1. When a user requests a .aspx/.htm/.html file, the file needs to be
automatically integrated into a page template. In ASP.NET, how can I do
this?
2. I know I can put custom controls, map .htm/.html files to utilize custom
controls, etc, but I don't want to go through and update 2000 pages (and
growing) to .aspx files and then add the controls.
Basically, I want to send .aspx/.htm/.html files to a "site template" page,
or control (but which?). If I use either, how can I a) integrate the server
controls properly; b) load the contents of the page they requested into my
site template file? I was able to do all this with .ASP using an ISAPI
filter to intercept the requests and change the path of the request to (for
example) site_template.a sp. Any ideas and thoughts would be very much
appreciated.
And yes, I've tried googling asp.net template, and many other queries, but
99% of them refer to utilizing web controls. I need this also interact with
..htm/.html files in the most efficient manner possible.
Thanks for any help!
Chad 18 1451
Check out the next version of ASP.Net (code name "Whidbey") which includes
"Master Pages" - very similar to what you're describing.
--
HTH,
Kevin Spencer
..Net Developer
Microsoft MVP
Big things are made up
of lots of little things.
"Chad A. Beckner" <Ch*********@Pr ospectiveLink.c om> wrote in message
news:#H******** ******@TK2MSFTN GP11.phx.gbl... I am (and have been trying!) to find a good way to do the following few things:
1. When a user requests a .aspx/.htm/.html file, the file needs to be automatically integrated into a page template. In ASP.NET, how can I do this? 2. I know I can put custom controls, map .htm/.html files to utilize
custom controls, etc, but I don't want to go through and update 2000 pages (and growing) to .aspx files and then add the controls.
Basically, I want to send .aspx/.htm/.html files to a "site template"
page, or control (but which?). If I use either, how can I a) integrate the
server controls properly; b) load the contents of the page they requested into my site template file? I was able to do all this with .ASP using an ISAPI filter to intercept the requests and change the path of the request to
(for example) site_template.a sp. Any ideas and thoughts would be very much appreciated.
And yes, I've tried googling asp.net template, and many other queries, but 99% of them refer to utilizing web controls. I need this also interact
with .htm/.html files in the most efficient manner possible.
Thanks for any help!
Chad
i think you can make a HttpHandler to map the request
and create the content on demand.
for more detail about httpandler, please prefer msdn
"Chad A. Beckner" <Ch*********@Pr ospectiveLink.c om> дÈëÏûÏ¢ÐÂÎÅ
:#H************ **@TK2MSFTNGP11 .phx.gbl... I am (and have been trying!) to find a good way to do the following few things:
1. When a user requests a .aspx/.htm/.html file, the file needs to be automatically integrated into a page template. In ASP.NET, how can I do this? 2. I know I can put custom controls, map .htm/.html files to utilize
custom controls, etc, but I don't want to go through and update 2000 pages (and growing) to .aspx files and then add the controls.
Basically, I want to send .aspx/.htm/.html files to a "site template"
page, or control (but which?). If I use either, how can I a) integrate the
server controls properly; b) load the contents of the page they requested into my site template file? I was able to do all this with .ASP using an ISAPI filter to intercept the requests and change the path of the request to
(for example) site_template.a sp. Any ideas and thoughts would be very much appreciated.
And yes, I've tried googling asp.net template, and many other queries, but 99% of them refer to utilizing web controls. I need this also interact
with .htm/.html files in the most efficient manner possible.
Thanks for any help!
Chad
I know that Whidbey will do this, but I can't wait until 2005! :-) I've
checked out some HTTP Handlers, and I've added a line to my Global.asax file
(see below) that will route requests to "something" . The question from here
is, in this "something" , such as an aspx or ascx file, how can I "execute"
the page the user actually requested?
Ugh, there has got to be a better way to templating files in ASP.NET!!
Thoughts?
Chad
"Kevin Spencer" <ks******@takem pis.com> wrote in message
news:%2******** ********@TK2MSF TNGP11.phx.gbl. .. Check out the next version of ASP.Net (code name "Whidbey") which includes "Master Pages" - very similar to what you're describing.
-- HTH, Kevin Spencer .Net Developer Microsoft MVP Big things are made up of lots of little things.
"Chad A. Beckner" <Ch*********@Pr ospectiveLink.c om> wrote in message news:#H******** ******@TK2MSFTN GP11.phx.gbl... I am (and have been trying!) to find a good way to do the following few things:
1. When a user requests a .aspx/.htm/.html file, the file needs to be automatically integrated into a page template. In ASP.NET, how can I do this? 2. I know I can put custom controls, map .htm/.html files to utilize custom controls, etc, but I don't want to go through and update 2000 pages (and growing) to .aspx files and then add the controls.
Basically, I want to send .aspx/.htm/.html files to a "site template" page, or control (but which?). If I use either, how can I a) integrate the server controls properly; b) load the contents of the page they requested into
my site template file? I was able to do all this with .ASP using an ISAPI filter to intercept the requests and change the path of the request to (for example) site_template.a sp. Any ideas and thoughts would be very much appreciated.
And yes, I've tried googling asp.net template, and many other queries,
but 99% of them refer to utilizing web controls. I need this also interact with .htm/.html files in the most efficient manner possible.
Thanks for any help!
Chad
Got any good examples? How can I create the content on demand?
Chad
"coollzh" <co*****@hotmai .com> wrote in message
news:uP******** ******@TK2MSFTN GP09.phx.gbl... i think you can make a HttpHandler to map the request and create the content on demand. for more detail about httpandler, please prefer msdn
"Chad A. Beckner" <Ch*********@Pr ospectiveLink.c om> дÈëÏûÏ¢ÐÂÎÅ :#H************ **@TK2MSFTNGP11 .phx.gbl... I am (and have been trying!) to find a good way to do the following few things:
1. When a user requests a .aspx/.htm/.html file, the file needs to be automatically integrated into a page template. In ASP.NET, how can I do this? 2. I know I can put custom controls, map .htm/.html files to utilize custom controls, etc, but I don't want to go through and update 2000 pages (and growing) to .aspx files and then add the controls.
Basically, I want to send .aspx/.htm/.html files to a "site template" page, or control (but which?). If I use either, how can I a) integrate the server controls properly; b) load the contents of the page they requested into
my site template file? I was able to do all this with .ASP using an ISAPI filter to intercept the requests and change the path of the request to (for example) site_template.a sp. Any ideas and thoughts would be very much appreciated.
And yes, I've tried googling asp.net template, and many other queries,
but 99% of them refer to utilizing web controls. I need this also interact with .htm/.html files in the most efficient manner possible.
Thanks for any help!
Chad
"Chad A. Beckner" <Ch*********@Pr ospectiveLink.c om> wrote in message
news:%2******** ********@TK2MSF TNGP11.phx.gbl. .. I am (and have been trying!) to find a good way to do the following few things:
1. When a user requests a .aspx/.htm/.html file, the file needs to be automatically integrated into a page template. In ASP.NET, how can I do this? 2. I know I can put custom controls, map .htm/.html files to utilize
custom controls, etc, but I don't want to go through and update 2000 pages (and growing) to .aspx files and then add the controls.
I'm afraid you're not going to get a canned solution for this very soon. The
next version of ASP.NET would help you, but it's not even in beta yet.
It's possible that some of the solutions you found under "asp.net template"
would work for you even with the .htm files. If you set the IIS script
mappings such that .htm files are processed by aspnet_isapi.dl l the same as
..aspx files are, then even .htm files will be able to pass through any
HttpHandler or HttpModule you may have.
--
John Saunders
johnwsaundersii i at hotmail
I guess my next question would be: How can I "read" the content of the
requested file, the integrate it into my .aspx/ascx file, then have the file
compile/execute?
Chad
"John Saunders" <jo************ **@notcoldmail. com> wrote in message
news:Ov******** ******@TK2MSFTN GP10.phx.gbl... "Chad A. Beckner" <Ch*********@Pr ospectiveLink.c om> wrote in message news:%2******** ********@TK2MSF TNGP11.phx.gbl. .. I am (and have been trying!) to find a good way to do the following few things:
1. When a user requests a .aspx/.htm/.html file, the file needs to be automatically integrated into a page template. In ASP.NET, how can I do this? 2. I know I can put custom controls, map .htm/.html files to utilize custom controls, etc, but I don't want to go through and update 2000 pages (and growing) to .aspx files and then add the controls.
I'm afraid you're not going to get a canned solution for this very soon.
The next version of ASP.NET would help you, but it's not even in beta yet.
It's possible that some of the solutions you found under "asp.net
template" would work for you even with the .htm files. If you set the IIS script mappings such that .htm files are processed by aspnet_isapi.dl l the same
as .aspx files are, then even .htm files will be able to pass through any HttpHandler or HttpModule you may have. -- John Saunders johnwsaundersii i at hotmail
"Chad A. Beckner" <Ch*********@Pr ospectiveLink.c om> wrote in message
news:uv******** ******@TK2MSFTN GP11.phx.gbl... Got any good examples? How can I create the content on demand?
One very simple way to do this would be to create the .pdf file on the
server, but then have the page send it to the client via Response.WriteF ile.
--
John Saunders
johnwsaundersii i at hotmail
"Chad A. Beckner" <Ch*********@Pr ospectiveLink.c om> wrote in message
news:ui******** ******@tk2msftn gp13.phx.gbl... I guess my next question would be: How can I "read" the content of the requested file, the integrate it into my .aspx/ascx file, then have the
file compile/execute?
Your handler can use Request.Url to see what file was requested, then
Server.MapPath to find out where it is on disk, then you can read it just
like any other file.
Actually, in this case, you might consider creating a "template" page which
contains an <iframe runat="server" />. Have your handler use
Context.Rewrite Path to change the path to
template.aspx?p age=<originalRe questedHtml>. template.aspx could then set the
src attribute of the iframe to the <originalReques tedHtml>. I seem to recall
that I did that once to put a .pdf file inside of a template page.
--
John Saunders
johnwsaundersii i at hotmail
you can study .Text project of free source , in this project, the author use
the technology of Httphandler almost every where
you visit the author's blog http://scottwater.com/blog/
"Chad A. Beckner" <Ch*********@Pr ospectiveLink.c om> дÈëÏûÏ¢ÐÂÎÅ
:uv************ **@TK2MSFTNGP11 .phx.gbl... Got any good examples? How can I create the content on demand?
Chad
"coollzh" <co*****@hotmai .com> wrote in message news:uP******** ******@TK2MSFTN GP09.phx.gbl... i think you can make a HttpHandler to map the request and create the content on demand. for more detail about httpandler, please prefer msdn
"Chad A. Beckner" <Ch*********@Pr ospectiveLink.c om> дÈëÏûÏ¢ÐÂÎÅ :#H************ **@TK2MSFTNGP11 .phx.gbl... I am (and have been trying!) to find a good way to do the following
few things:
1. When a user requests a .aspx/.htm/.html file, the file needs to be automatically integrated into a page template. In ASP.NET, how can I
do this? 2. I know I can put custom controls, map .htm/.html files to utilize custom controls, etc, but I don't want to go through and update 2000 pages
(and growing) to .aspx files and then add the controls.
Basically, I want to send .aspx/.htm/.html files to a "site template" page, or control (but which?). If I use either, how can I a) integrate the server controls properly; b) load the contents of the page they requested
into my site template file? I was able to do all this with .ASP using an
ISAPI filter to intercept the requests and change the path of the request to
(for example) site_template.a sp. Any ideas and thoughts would be very much appreciated.
And yes, I've tried googling asp.net template, and many other queries, but 99% of them refer to utilizing web controls. I need this also
interact with .htm/.html files in the most efficient manner possible.
Thanks for any help!
Chad
This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Philip D Heady |
last post by:
I'm in need of a good PHP programmer to help me with my lodgings website
asap. Someone who can work on it during the day for a few hrs while I'm at
work would be great. Prefer they live in USA eastern standard time zone.
Please send me your hourly rate, slill level, website references, and
availability asap.
Thank you.
Philip D. Heady
|
by: whisper |
last post by:
Medium/small site with mod_python and sqllite or mySQL running Python
2.3.3 or later on Apache 2.x.
I can do the python and CGI, but might need a _little_ hand holding for
the rest.
Will also need SSL and a certificate.
Also mailboxes for ~12 people (to start). We don't do unsolicited
mailings or expect a huge amount of mail traffic at this time.
|
by: Witless |
last post by:
This is 'supposed' to be a simple problem and shouldn't need too much
time to solve :S
Below is a function that works like this:
int fn(int input)
{
int x=(input/8);
|
by: Corey Dyke |
last post by:
K here's the situation, attached is a copy of the lab i have due next week.
But I won't be around for the next few days, so I 've gotta get it done
ASAP. but it's driving me crazy.
We have to design a windows application for children to use for simple
arithmetic. They must have an option button to bring up a modal dialog
which allows them to choose non-zero single digit numbers, double digit
numbers, or one of each. They can also...
|
by: clinttoris |
last post by:
Hello,
If someone could help me it would be appreciated as I am not having
much luck.
I'm struggling with my asp code and have some questions relating to asp
and oracle database.
First question. I have a web survey that I am working on and have
successfully dynamically taken the info from a database, displayed it
on the screen and then taken the users answers and inserted them into a
| |
by: phez.asap |
last post by:
I am new to Python but come from a C++ background so I am trying to
connect the dots :) . I am really liking what I see so far but have
some nubee questions on what is considered good form. For one thing I
am used to class variables being accessable only through methods
instaed of directly refrenced from the object instence. From what I
have read it looks like when you access a class variable directly in
Python it has something in the...
|
by: jgill |
last post by:
Hello,
To start with here is the code:
Public Function Paymentget (s12MoRate)
strCompanyCode = objXML.selectSingleNode("policy/companyCode").text
strState = objXML.selectSingleNode("policy/insured/state").text
set rsDownPayment = getCache("down_payment")
|
by: daxco21 |
last post by:
I have been working on this simple project for a week, and come to the point where I feel like I need outside help. For the life of me I can't figure out what is wrong with this "sellIceCream(...)" method. I think theres something wrong with my if statement, because even if i have enough "ingredients", it still prints my "not enough" statement instead of selling.
The error that the online tester for this project gave me was:
"Test results...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
|
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...
|
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth.
The Art of Business Website Design
Your website is...
| |
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...
|
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...
|
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();...
|
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...
|
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
|
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...
| |