Convert HTTP Header Last Modification Date to Integer

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

    #1

    Convert HTTP Header Last Modification Date to Integer

    snoopy class can retrieve the specific page's lat modification date in
    String
    but is there any way to get into the integer or long?

    <?php
    include( "Snoopy.class.p hp" );


    $request = new Snoopy;
    $request->fetch( "http://www.mysite.com" );


    if( ! $request -error ){
    while( list( $key, $val ) = each( $request -headers ) ) {
    echo $key.": ".$val."<br>\n" ;
    }
    }
    ?>





  • Chung Leong

    #2
    Re: Convert HTTP Header Last Modification Date to Integer


    Shuan wrote:
    snoopy class can retrieve the specific page's lat modification date in
    String
    but is there any way to get into the integer or long?
    >
    <?php
    include( "Snoopy.class.p hp" );
    >
    >
    $request = new Snoopy;
    $request->fetch( "http://www.mysite.com" );
    >
    >
    if( ! $request -error ){
    while( list( $key, $val ) = each( $request -headers ) ) {
    echo $key.": ".$val."<br>\n" ;
    }
    }
    ?>
    strtotime() should work.

    Comment

    Working...