468,168 Members | 1,716 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 468,168 developers. It's quick & easy.

Embed non-ASP.NET pages in an ASP.NET page

Hi there.

I'm currently working on a project involving rebuilding our local
intranet site. The site was originally developed using frames, defining
a header, sidebar, and content area, which I've been working to replace
using ASP.NET master pages.

Right now I'm trying to find a solution for some of our older and
externally linked content. A good proportion of this content get loaded
into the content frame, leaving the header and sidebar intact. I'm
trying to find a solution that will allow me to still embed this
content inside the content area on my Master page without having to
modify the target.

I was thinking of using a dynamic iframe inside a place-holder page
that would load the desired content, however, I'm having troubling
getting this iframe to properly size to fill the whole content area.
I'm also not convinced that this is the proper direction to go.

Has anyone else encountered this type of problem and what solution did
they use to solve it?

Thanks

Dec 20 '06 #1
6 1309
"emorgoch" <em*************@gmail.comwrote in message
news:11**********************@80g2000cwy.googlegro ups.com...
I'm currently working on a project involving rebuilding our local
intranet site. The site was originally developed using frames, defining
a header, sidebar, and content area, which I've been working to replace
using ASP.NET master pages.
Excellent.
Right now I'm trying to find a solution for some of our older and
externally linked content. A good proportion of this content get loaded
into the content frame, leaving the header and sidebar intact. I'm
trying to find a solution that will allow me to still embed this
content inside the content area on my Master page without having to
modify the target.

I was thinking of using a dynamic iframe inside a place-holder page
that would load the desired content, however, I'm having troubling
getting this iframe to properly size to fill the whole content area.
I'm also not convinced that this is the proper direction to go.

Has anyone else encountered this type of problem and what solution did
they use to solve it?
I think it will depend on the format of your older and externally linked
content. If they are plain HTML files, then it will be fairly simple to
create a content page, place a literal control in it, open the HTML file,
copy everything inside the <body></bodytags using RegEx and then plug that
into the literal control.

One word of caution, though - don't even waste any time trying to come up
with a mechanism whereby the MasterPage controls the contents of its
ContentPage(s) - it just doesn't work like that at all...

Can you provide more information as to the format of your older and
externally linked content...?
Dec 20 '06 #2
you need to write javascript to size it. attach to the window onresize
event.

-- bruce (sqlwork.com)

emorgoch wrote:
Hi there.

I'm currently working on a project involving rebuilding our local
intranet site. The site was originally developed using frames, defining
a header, sidebar, and content area, which I've been working to replace
using ASP.NET master pages.

Right now I'm trying to find a solution for some of our older and
externally linked content. A good proportion of this content get loaded
into the content frame, leaving the header and sidebar intact. I'm
trying to find a solution that will allow me to still embed this
content inside the content area on my Master page without having to
modify the target.

I was thinking of using a dynamic iframe inside a place-holder page
that would load the desired content, however, I'm having troubling
getting this iframe to properly size to fill the whole content area.
I'm also not convinced that this is the proper direction to go.

Has anyone else encountered this type of problem and what solution did
they use to solve it?

Thanks
Dec 20 '06 #3
I think it will depend on the format of your older and externally linked
content. If they are plain HTML files, then it will be fairly simple to
create a content page, place a literal control in it, open the HTML file,
copy everything inside the <body></bodytags using RegEx and then plug that
into the literal control.

One word of caution, though - don't even waste any time trying to come up
with a mechanism whereby the MasterPage controls the contents of its
ContentPage(s) - it just doesn't work like that at all...

Can you provide more information as to the format of your older and
externally linked content...?
There's a variety of content.

Some of them are plain HTML files. However, not all of them are local
to the webserver that the ASP.NET page will run from. Some of them are
pages that are served by our parent company's intranet south of the
border (we're up in the great white north).

Another large portion of the content are pure PDF files that get
displayed (using acrobat reader's tie-into IE). There's a single
classic ASP application that won't "upgraded" for a while. Lastly,
there's a few Oracle written HTML manuals that we make available to
users.

Thanks

Dec 20 '06 #4
"emorgoch" <em*************@gmail.comwrote in message
news:11*********************@48g2000cwx.googlegrou ps.com...
>Can you provide more information as to the format of your older and
externally linked content...?

There's a variety of content.
I had a feeling there might be... ;-)
Some of them are plain HTML files.
They will present no problem.
However, not all of them are local to the webserver that the ASP.NET page
will run
from. Some of them are pages that are served by our parent company's
intranet south
of the border (we're up in the great white north).
That shouldn't be a problem either, so long as your webserver can "see"
them. Do a Google search for WebClient, HttpWebRequest & HttpWebResponse...
Another large portion of the content are pure PDF files that get
displayed (using acrobat reader's tie-into IE).
In which case, I don't think you'll need to worry about MasterPage /
ContentPage issues here as you'll be opening the PDFs in a separate browser
window, no...?
There's a single classic ASP application that won't "upgraded" for a
while.
That *should* work on the same principle as the static HTML files unless you
need to run the ASP application interactively in order to get it to display
the correct active content...
Lastly, there's a few Oracle written HTML manuals that we make available
to users.
How does that work? Do you have to query Oracle to get at the HTML? Again,
that should be fairly straightforward...
Dec 20 '06 #5
Hi Mark,

I've looked over the WebClient, HttpWebRequest/Response objects as you
suggested, and while I can see how they could be used, I don't feel
that they are going to be applicable in this instance. The reason I say
this is that most of the pages I'm going to be loading have links in
themselves to other pages that I will want to keep inside the "frame".
I guess it's feasible that I could re-map to an appropriate handler as
they are read, but is it really feasible?

The other part is that some of the pages do have some client-side
scripting too them as well. I'm not sure how well the WebClient and
other classes would handle those.

As for the oracle stuff: they are HTML based user manuals provided by
oracle, by hosted on our internal server.

I'm still feeling that an iFrame is the way to go, but am having
problems getting it to size properly in the window (which I guess is to
be expected in this case :P)

Mark Rae wrote:
"emorgoch" <em*************@gmail.comwrote in message
news:11*********************@48g2000cwx.googlegrou ps.com...
Can you provide more information as to the format of your older and
externally linked content...?
There's a variety of content.

I had a feeling there might be... ;-)
Some of them are plain HTML files.

They will present no problem.
However, not all of them are local to the webserver that the ASP.NET page
will run
from. Some of them are pages that are served by our parent company's
intranet south
of the border (we're up in the great white north).

That shouldn't be a problem either, so long as your webserver can "see"
them. Do a Google search for WebClient, HttpWebRequest & HttpWebResponse...
Another large portion of the content are pure PDF files that get
displayed (using acrobat reader's tie-into IE).

In which case, I don't think you'll need to worry about MasterPage /
ContentPage issues here as you'll be opening the PDFs in a separate browser
window, no...?
There's a single classic ASP application that won't "upgraded" for a
while.

That *should* work on the same principle as the static HTML files unless you
need to run the ASP application interactively in order to get it to display
the correct active content...
Lastly, there's a few Oracle written HTML manuals that we make available
to users.

How does that work? Do you have to query Oracle to get at the HTML? Again,
that should be fairly straightforward...
Dec 20 '06 #6
"emorgoch" <em*************@gmail.comwrote in message
news:11*********************@a3g2000cwd.googlegrou ps.com...
I've looked over the WebClient, HttpWebRequest/Response objects as you
suggested, and while I can see how they could be used, I don't feel
that they are going to be applicable in this instance. The reason I say
this is that most of the pages I'm going to be loading have links in
themselves to other pages that I will want to keep inside the "frame".
I guess it's feasible that I could re-map to an appropriate handler as
they are read, but is it really feasible?
Hmm - you didn't say that earlier! In which case, then, I don't feel the
"screen-scraping" approach will be of much use either...
The other part is that some of the pages do have some client-side
scripting too them as well. I'm not sure how well the WebClient and
other classes would handle those.
As above.
As for the oracle stuff: they are HTML based user manuals provided by
oracle, by hosted on our internal server.
Well, presumably they are self-contained units, or do they have external
links too...?
I'm still feeling that an iFrame is the way to go, but am having
problems getting it to size properly in the window (which I guess is to
be expected in this case :P)
Have you tried JavaScript code behind the window.onresize event, as Bruce
suggested...?
Dec 20 '06 #7

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

reply views Thread by Wolfgang Schwanke | last post: by
3 posts views Thread by Tony Sutton | last post: by
11 posts views Thread by Anna | last post: by
10 posts views Thread by Anna | last post: by
1 post views Thread by Frances Del Rio | last post: by
2 posts views Thread by Joe | last post: by
6 posts views Thread by qualitychecker | last post: by
reply views Thread by gcreed | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.