Re: ASP.Net, IE 5 & 5.01, Caching Problem

Discussion in 'ASP .Net' started by Joe Reazor, Jul 17, 2003.

  1. Joe Reazor

    Joe Reazor Guest

    Thanks Mark, I think that will solve my problem. A related question then
    would be, how can I write out these meta tags in code. All of my pages in
    my web app inherit from a custom class I wrote that inherits from Page, so I
    would like to add these meta tags in my custom class in code, so that I
    don't have to set them up in the html of all of my dozens of children
    classes.

    TIA.

    -
    ==============
    Joe Reazor
    Gorbel Inc.
    email: joereaATgorbelDOTcom
    "Mark MacRae" <> wrote in message
    news:up6hv#...
    > As a rule, I always put the following at the top of my ASPX pages (in the
    > <head></head> secion of course)
    >
    > <meta name="prevent_caching1" HTTP-EQUIV="Pragma" content="no-cache">
    > <meta name="prevent_caching2" HTTP-EQUIV="Cache-Control"

    CONTENT="no-cache">
    > <meta name="prevent_caching3" HTTP-EQUIV="Expires" CONTENT="0">
    >
    > HTH,
    > mark
    >
    >
    >
    > "Joe Reazor" <> wrote in message
    > news:...
    > > We've deployed a brand new web app built with ASP.Net and are

    experiencing
    > a
    > > strange case with our users accessing it using IE 5.0 or IE5.01. If the

    > go
    > > to Tools - Internet Options - Settings and have their "Check for newer
    > > versions of stored pages" setting set to "Automatically", then the first
    > > time they go to a page it looks right, but the next time they go to the
    > > page, if the page should be different because its dynamic, they don't

    get
    > > the new page, they get the same one they saw before. The page should be
    > > different even though the entire url is the same. This does not happen

    at
    > > all in IE 6 or even IE 5.5. I'm guessing its an issue with these old
    > > versions of IE, but thought maybe .Net has something to do with it if it

    > is
    > > detected the browser's capabilities. Anyone have any thoughts or ideas,
    > > short of having the users upgrade their browsers or forcing them to

    change
    > > the setting to "Every Visist to the Page" which also works fine.
    > >
    > > TIA
    > >
    > > ==============
    > > Joe Reazor
    > > Gorbel Inc.
    > > email: joereaATgorbelDOTcom
    > >
    > >

    >
    >
     
    Joe Reazor, Jul 17, 2003
    #1
    1. Advertising

  2. Joe Reazor

    Joe Iano Guest

    From a previous post. I haven't tried it, but it might be worth a look:

    <HEAD id="myHead" runat="server"></HEAD> suffices.

    In your code behind you then declare :

    protected System.Web.UI.HtmlControls.HtmlContainerControl myHead

    And you are free to access myHead properties. You are probably going to be
    interested in "InnerHtml" property the most.


    "Joe Reazor" <> wrote in message
    news:%...
    > Thanks Mark, I think that will solve my problem. A related question then
    > would be, how can I write out these meta tags in code. All of my pages in
    > my web app inherit from a custom class I wrote that inherits from Page, so

    I
    > would like to add these meta tags in my custom class in code, so that I
    > don't have to set them up in the html of all of my dozens of children
    > classes.
    >
    > TIA.
    >
    > -
    > ==============
    > Joe Reazor
    > Gorbel Inc.
    > email: joereaATgorbelDOTcom
    > "Mark MacRae" <> wrote in message
    > news:up6hv#...
    > > As a rule, I always put the following at the top of my ASPX pages (in

    the
    > > <head></head> secion of course)
    > >
    > > <meta name="prevent_caching1" HTTP-EQUIV="Pragma" content="no-cache">
    > > <meta name="prevent_caching2" HTTP-EQUIV="Cache-Control"

    > CONTENT="no-cache">
    > > <meta name="prevent_caching3" HTTP-EQUIV="Expires" CONTENT="0">
    > >
    > > HTH,
    > > mark
    > >
    > >
    > >
    > > "Joe Reazor" <> wrote in message
    > > news:...
    > > > We've deployed a brand new web app built with ASP.Net and are

    > experiencing
    > > a
    > > > strange case with our users accessing it using IE 5.0 or IE5.01. If

    the
    > > go
    > > > to Tools - Internet Options - Settings and have their "Check for newer
    > > > versions of stored pages" setting set to "Automatically", then the

    first
    > > > time they go to a page it looks right, but the next time they go to

    the
    > > > page, if the page should be different because its dynamic, they don't

    > get
    > > > the new page, they get the same one they saw before. The page should

    be
    > > > different even though the entire url is the same. This does not

    happen
    > at
    > > > all in IE 6 or even IE 5.5. I'm guessing its an issue with these old
    > > > versions of IE, but thought maybe .Net has something to do with it if

    it
    > > is
    > > > detected the browser's capabilities. Anyone have any thoughts or

    ideas,
    > > > short of having the users upgrade their browsers or forcing them to

    > change
    > > > the setting to "Every Visist to the Page" which also works fine.
    > > >
    > > > TIA
    > > >
    > > > ==============
    > > > Joe Reazor
    > > > Gorbel Inc.
    > > > email: joereaATgorbelDOTcom
    > > >
    > > >

    > >
    > >

    >
    >
     
    Joe Iano, Jul 17, 2003
    #2
    1. Advertising

  3. Hello Joe,

    Please also refer to http://www.codeproject.com/aspnet/page_templates.asp?print=true to see how to add customized
    header field from a inherited based page.

    Hope it helps.

    Best regards,
    Yanhong Huang
    Microsoft Online Partner Support

    Get Secure! - www.microsoft.com/security
    This posting is provided "AS IS" with no warranties, and confers no rights.

    --------------------
    !From: "Joe Reazor" <>
    !References: <> <up6hv#>
    <#> <>
    !Subject: Re: ASP.Net, IE 5 & 5.01, Caching Problem
    !Date: Thu, 17 Jul 2003 15:15:46 -0400
    !Lines: 114
    !X-Priority: 3
    !X-MSMail-Priority: Normal
    !X-Newsreader: Microsoft Outlook Express 6.00.2800.1106
    !X-MIMEOLE: Produced By Microsoft MimeOLE V6.00.2800.1106
    !Message-ID: <u70n$>
    !Newsgroups: microsoft.public.dotnet.framework.aspnet
    !NNTP-Posting-Host: smtp.gorbel.com 216.42.134.6
    !Path: cpmsftngxa06.phx.gbl!TK2MSFTNGP08.phx.gbl!TK2MSFTNGP12.phx.gbl
    !Xref: cpmsftngxa06.phx.gbl microsoft.public.dotnet.framework.aspnet:160050
    !X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet
    !
    !Actaully, all of my pages inherit from my custom class MyPage instead of
    !Page. In my class MyPage, I have all kinds of custom stuff that all of my
    !child pages get access to on top of the normal Page stuff. I was hoping
    !there would be a way for me to put some code in my OnLoad method of my
    !MyPage class that would write out these headers. I was looking at
    !Response.AppendHeader, but that didn't seem to do it. At least it didn't
    !write out the header in the generated HTML, but I have to imagine there is a
    !way to do it.
    !
    !
    !==============
    !Joe Reazor
    !Gorbel Inc.
    !email: joereaATgorbelDOTcom
    !
    !
    !"Mark MacRae" <> wrote in message
    !news:...
    !> Joe,
    !> Maybe I'm low tech, but all my ASPX pages are basically cloned from a
    !> template and that's in my template. You could use a server-side includes,
    !or
    !> some inline function to put it in at the top of each page, but as far as I
    !> can think, you'll have to be editing all your pages no matter which way
    !you
    !> go.
    !>
    !> "Joe Reazor" <> wrote in message
    !> news:%...
    !> > Thanks Mark, I think that will solve my problem. A related question
    !then
    !> > would be, how can I write out these meta tags in code. All of my pages
    !in
    !> > my web app inherit from a custom class I wrote that inherits from Page,
    !so
    !> I
    !> > would like to add these meta tags in my custom class in code, so that I
    !> > don't have to set them up in the html of all of my dozens of children
    !> > classes.
    !> >
    !> > TIA.
    !> >
    !> > -
    !> > ==============
    !> > Joe Reazor
    !> > Gorbel Inc.
    !> > email: joereaATgorbelDOTcom
    !> > "Mark MacRae" <> wrote in message
    !> > news:up6hv#...
    !> > > As a rule, I always put the following at the top of my ASPX pages (in
    !> the
    !> > > <head></head> secion of course)
    !> > >
    !> > > <meta name="prevent_caching1" HTTP-EQUIV="Pragma" content="no-cache">
    !> > > <meta name="prevent_caching2" HTTP-EQUIV="Cache-Control"
    !> > CONTENT="no-cache">
    !> > > <meta name="prevent_caching3" HTTP-EQUIV="Expires" CONTENT="0">
    !> > >
    !> > > HTH,
    !> > > mark
    !> > >
    !> > >
    !> > >
    !> > > "Joe Reazor" <> wrote in message
    !> > > news:...
    !> > > > We've deployed a brand new web app built with ASP.Net and are
    !> > experiencing
    !> > > a
    !> > > > strange case with our users accessing it using IE 5.0 or IE5.01. If
    !> the
    !> > > go
    !> > > > to Tools - Internet Options - Settings and have their "Check for
    !newer
    !> > > > versions of stored pages" setting set to "Automatically", then the
    !> first
    !> > > > time they go to a page it looks right, but the next time they go to
    !> the
    !> > > > page, if the page should be different because its dynamic, they
    !don't
    !> > get
    !> > > > the new page, they get the same one they saw before. The page
    !should
    !> be
    !> > > > different even though the entire url is the same. This does not
    !> happen
    !> > at
    !> > > > all in IE 6 or even IE 5.5. I'm guessing its an issue with these
    !old
    !> > > > versions of IE, but thought maybe .Net has something to do with it
    !if
    !> it
    !> > > is
    !> > > > detected the browser's capabilities. Anyone have any thoughts or
    !> ideas,
    !> > > > short of having the users upgrade their browsers or forcing them to
    !> > change
    !> > > > the setting to "Every Visist to the Page" which also works fine.
    !> > > >
    !> > > > TIA
    !> > > >
    !> > > > ==============
    !> > > > Joe Reazor
    !> > > > Gorbel Inc.
    !> > > > email: joereaATgorbelDOTcom
    !> > > >
    !> > > >
    !> > >
    !> > >
    !> >
    !> >
    !>
    !>
    !
    !
    !
     
    Yan-Hong Huang[MSFT], Jul 21, 2003
    #3
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Hypo
    Replies:
    6
    Views:
    423
  2. Troy Simpson

    Fragment Caching inside page caching?

    Troy Simpson, Jan 19, 2004, in forum: ASP .Net
    Replies:
    0
    Views:
    806
    Troy Simpson
    Jan 19, 2004
  3. Mike Sobeiski
    Replies:
    2
    Views:
    5,754
    Lenard Gunda
    Aug 7, 2004
  4. Ken Fine
    Replies:
    2
    Views:
    590
    Steven Cheng
    Sep 17, 2008
  5. JimLad
    Replies:
    3
    Views:
    925
    JimLad
    Jan 21, 2010
Loading...

Share This Page