javascript document.lastModified apache 1.3 error

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Kam Bansal

    javascript document.lastModified apache 1.3 error

    Hi all,

    We're using Apache 1.3 (I know, I know, there's a newer version...)
    and it seems that the document.lastMo dified does not return the
    correct date. On Netscape it shows 01/01/1970 and on IE etc it shows
    the "current" date, but not the file's last mod date!!!

    I've searched the net and I've seen many posts with simular issues,
    but I cannot find the solution...is there one??? Is there a setting in
    my https.conf file???

    Thanks in advance!

    ~Kam (^8*

    ps. on Solaris 9
  • Thomas 'PointedEars' Lahn

    #2
    Re: javascript document.lastMo dified apache 1.3 error

    Kam Bansal wrote:[color=blue]
    > We're using Apache 1.3 (I know, I know, there's a newer version...)[/color]

    Yes, Apache 1.3.31 and 2.0.50, both including many security
    fixes which is why you really want to update/upgrade.
    [color=blue]
    > and it seems that the document.lastMo dified does not return the
    > correct date.[/color]

    `document' refers to a host object. It is not guaranteed
    that this even exists, let alone that its properties exist.
    [color=blue]
    > On Netscape[/color]

    Which of the numerous Netscape versions are you talking about?
    [color=blue]
    > it shows 01/01/1970[/color]

    Reads like you have tried document.lastMo dified with the Date object,
    and the formats do not match. January 1, 1970 midnight is the zero
    date value.
    [color=blue]
    > and on IE[/color]

    Which platform, which version?
    [color=blue]
    > etc[/color]

    Define that.
    [color=blue]
    > it shows the "current" date, but not the file's last mod date!!![/color]
    ^^^
    Reads like you are referring to a document generated by a server-side
    application, e.g. PHP or ASP.
    [color=blue]
    > I've searched the net and I've seen many posts with simular issues,
    > but I cannot find the solution...is there one??? Is there a setting in[/color]
    ^^^[color=blue]
    > my https.conf file???[/color]
    ^^^
    Your keyboard is borken.

    If there were a solution, httpd.conf would be the appropriate configuration
    file and it would be off-topic here.

    Why do you pursue a solution with client-side J(ava)Script where Server-Side
    Includes or server-side scripting would be the reliable solution?


    PointedEars

    Comment

    • Dr John Stockton

      #3
      Re: javascript document.lastMo dified apache 1.3 error

      JRS: In article <667c26e7.04080 21319.719c98c0@ posting.google. com>,
      dated Mon, 2 Aug 2004 14:19:17, seen in news:comp.lang. javascript, Kam
      Bansal <kam@magickhat. com> posted :
      [color=blue]
      >We're using Apache 1.3 (I know, I know, there's a newer version...)
      >and it seems that the document.lastMo dified does not return the
      >correct date. On Netscape it shows 01/01/1970 and on IE etc it shows
      >the "current" date, but not the file's last mod date!!![/color]

      Your document.lastMo dified is a javascript string; it is derived, by
      something distantly approaching but nowhere near attaining logic, from
      the HTTP header Last-Modified line.

      You should arrange to inspect this line as transmitted, perhaps by
      telnetting into the server (can someone provide the Telnet grammar?). I
      expect that you will find it to be absent, or possibly corrupt. The
      correct format is :-
      Last-Modified: Tue, 15 Nov 1994 12:45:26 GMT

      Note : web-based page validation services often report HTTP headers.

      [color=blue]
      >I've searched the net and I've seen many posts with simular issues,
      >but I cannot find the solution...is there one??? Is there a setting in
      >my https.conf file???[/color]

      For that you should consult a servers newsgroup.


      Did you read the FAQ of this newsgroup, though? See footer.

      When posting date-related questions, you should give the relevant
      locations; it sometimes helps. What time does Netscape show?



      ANNOUNCE to regulars : The digit in js-date1.htm, js-date2.htm, js-
      date3.htm, and the first part of a shuffled js-date4.htm should in each
      case be decremented, with effect from August 1st, BST. I need more
      digits ...

      --
      © John Stockton, Surrey, UK. ?@merlyn.demon. co.uk Turnpike v4.00 IE 4 ©
      <URL:http://jibbering.com/faq/> JL / RC : FAQ for news:comp.lang. javascript
      <URL:http://www.merlyn.demo n.co.uk/js-index.htm> jscr maths, dates, sources.
      <URL:http://www.merlyn.demo n.co.uk/> TP/BP/Delphi/jscr/&c, FAQ items, links.

      Comment

      Working...