Filtering out graphics from a page

  • Thread starter Thread starter A. Elamiri
  • Start date Start date
A

A. Elamiri

I created a portal, and all my pages inherit from a customized class which
allows me to add header and footer to page and thus customize how it looks.

I would like to add the option of making any page in Low-Graphics mode, how
would I go about removing all images from the HTML output and replace it
with [<Image Name>]

Thanks!
 
What I would do is to create a custom Control that either displays an image
(writes an image tag to the page) or the text you mentioned, depending upon
a field or property of the Control, so that you can set a global variable
that each Control reads to determine which to display.

--
HTH,
Kevin Spencer
..Net Developer
Microsoft MVP
Neither a follower
nor a lender be.
 
I have no control over the pages, because the use inserts the image in the
backend using a RAD Editor, so I can't put the images in the control

--
Abdellah Elamiri
..net Developer
Efficacy through simplicity
Kevin Spencer said:
What I would do is to create a custom Control that either displays an image
(writes an image tag to the page) or the text you mentioned, depending upon
a field or property of the Control, so that you can set a global variable
that each Control reads to determine which to display.

--
HTH,
Kevin Spencer
.Net Developer
Microsoft MVP
Neither a follower
nor a lender be.

A. Elamiri said:
I created a portal, and all my pages inherit from a customized class which
allows me to add header and footer to page and thus customize how it looks.

I would like to add the option of making any page in Low-Graphics mode, how
would I go about removing all images from the HTML output and replace it
with [<Image Name>]

Thanks!
 
Could you derive your own base page class and override the render event.
You could call base.Render, take the html string returned, and replace what
you need to before the response is sent to the browser.

I am sure someone here could provide a code sample for you to use if you
want to take this approach.

bill

A. Elamiri said:
I have no control over the pages, because the use inserts the image in the
backend using a RAD Editor, so I can't put the images in the control

--
Abdellah Elamiri
.net Developer
Efficacy through simplicity
Kevin Spencer said:
What I would do is to create a custom Control that either displays an image
(writes an image tag to the page) or the text you mentioned, depending upon
a field or property of the Control, so that you can set a global variable
that each Control reads to determine which to display.

--
HTH,
Kevin Spencer
.Net Developer
Microsoft MVP
Neither a follower
nor a lender be.

A. Elamiri said:
I created a portal, and all my pages inherit from a customized class which
allows me to add header and footer to page and thus customize how it looks.

I would like to add the option of making any page in Low-Graphics
mode,
how
would I go about removing all images from the HTML output and replace it
with [<Image Name>]

Thanks!
 
You don't put the images into a Control. What I said was, the Control
creates an image tag in the page.

--
HTH,
Kevin Spencer
..Net Developer
Microsoft MVP
Neither a follower
nor a lender be.

A. Elamiri said:
I have no control over the pages, because the use inserts the image in the
backend using a RAD Editor, so I can't put the images in the control

--
Abdellah Elamiri
.net Developer
Efficacy through simplicity
Kevin Spencer said:
What I would do is to create a custom Control that either displays an image
(writes an image tag to the page) or the text you mentioned, depending upon
a field or property of the Control, so that you can set a global variable
that each Control reads to determine which to display.

--
HTH,
Kevin Spencer
.Net Developer
Microsoft MVP
Neither a follower
nor a lender be.

A. Elamiri said:
I created a portal, and all my pages inherit from a customized class which
allows me to add header and footer to page and thus customize how it looks.

I would like to add the option of making any page in Low-Graphics
mode,
how
would I go about removing all images from the HTML output and replace it
with [<Image Name>]

Thanks!
 
Back
Top