<?php
include_once $_SERVER['DOCUMENT_ROOT'] . '/include/shared-manual.inc';
$TOC = array();
$TOC_DEPRECATED = array();
$PARENTS = array();
include_once dirname(__FILE__) ."/toc/ref.info.inc";
$setup = array (
  'home' => 
  array (
    0 => 'index.php',
    1 => 'PHP Manual',
  ),
  'head' => 
  array (
    0 => 'UTF-8',
    1 => 'en',
  ),
  'this' => 
  array (
    0 => 'function.getlastmod.php',
    1 => 'getlastmod',
    2 => 'Gets time of last page modification',
  ),
  'up' => 
  array (
    0 => 'ref.info.php',
    1 => 'PHP Options/Info Functions',
  ),
  'prev' => 
  array (
    0 => 'function.getenv.php',
    1 => 'getenv',
  ),
  'next' => 
  array (
    0 => 'function.getmygid.php',
    1 => 'getmygid',
  ),
  'alternatives' => 
  array (
  ),
  'source' => 
  array (
    'lang' => 'en',
    'path' => 'reference/info/functions/getlastmod.xml',
  ),
  'history' => 
  array (
  ),
);
$setup["toc"] = $TOC;
$setup["toc_deprecated"] = $TOC_DEPRECATED;
$setup["parents"] = $PARENTS;
manual_setup($setup);

contributors($setup);

?>
<div id="function.getlastmod" class="refentry">
 <div class="refnamediv">
  <h1 class="refname">getlastmod</h1>
  <p class="verinfo">(PHP 4, PHP 5, PHP 7, PHP 8)</p><p class="refpurpose"><span class="refname">getlastmod</span> &mdash; <span class="dc-title">Gets time of last page modification</span></p>

 </div>
 
 <div class="refsect1 description" id="refsect1-function.getlastmod-description">
  <h3 class="title">Description</h3>
  <div class="methodsynopsis dc-description">
   <span class="methodname"><strong>getlastmod</strong></span>(): <span class="type"><span class="type"><a href="language.types.integer.php" class="type int">int</a></span>|<span class="type"><a href="language.types.singleton.php" class="type false">false</a></span></span></div>

  <p class="para rdfs-comment">
   Gets the time of the last modification of the main script of execution.
  </p>
  <p class="para">
   If you&#039;re interested in getting the last modification time
   of a different file, consider using <span class="function"><a href="function.filemtime.php" class="function">filemtime()</a></span>.
  </p>
 </div>


 <div class="refsect1 parameters" id="refsect1-function.getlastmod-parameters">
  <h3 class="title">Parameters</h3>
  <p class="para">This function has no parameters.</p>
 </div>


 <div class="refsect1 returnvalues" id="refsect1-function.getlastmod-returnvalues">
  <h3 class="title">Return Values</h3>
  <p class="para">
   Returns the time of the last modification of the current
   page. The value returned is a Unix timestamp, suitable for
   feeding to <span class="function"><a href="function.date.php" class="function">date()</a></span>. Returns <strong><code><a href="reserved.constants.php#constant.false">false</a></code></strong> on error.
  </p>
 </div>


 <div class="refsect1 examples" id="refsect1-function.getlastmod-examples">
  <h3 class="title">Examples</h3>
  <p class="para">
   <div class="example" id="example-1">
    <p><strong>Example #1 <span class="function"><strong>getlastmod()</strong></span> example</strong></p>
    <div class="example-contents">
<div class="phpcode"><code><span style="color: #000000"><span style="color: #0000BB">&lt;?php<br /></span><span style="color: #FF8000">// outputs e.g. 'Last modified: March 04 1998 20:43:59.'<br /></span><span style="color: #007700">echo </span><span style="color: #DD0000">"Last modified: " </span><span style="color: #007700">. </span><span style="color: #0000BB">date </span><span style="color: #007700">(</span><span style="color: #DD0000">"F d Y H:i:s."</span><span style="color: #007700">, </span><span style="color: #0000BB">getlastmod</span><span style="color: #007700">());<br /></span><span style="color: #0000BB">?&gt;</span></span></code></div>
    </div>

   </div>
  </p>
 </div>


 <div class="refsect1 seealso" id="refsect1-function.getlastmod-seealso">
  <h3 class="title">See Also</h3>
  <p class="para">
   <ul class="simplelist">
    <li><span class="function"><a href="function.date.php" class="function" rel="rdfs-seeAlso">date()</a> - Format a Unix timestamp</span></li>
    <li><span class="function"><a href="function.getmyuid.php" class="function" rel="rdfs-seeAlso">getmyuid()</a> - Gets PHP script owner's UID</span></li>
    <li><span class="function"><a href="function.getmygid.php" class="function" rel="rdfs-seeAlso">getmygid()</a> - Get PHP script owner's GID</span></li>
    <li><span class="function"><a href="function.get-current-user.php" class="function" rel="rdfs-seeAlso">get_current_user()</a> - Gets the name of the owner of the current PHP script</span></li>
    <li><span class="function"><a href="function.getmyinode.php" class="function" rel="rdfs-seeAlso">getmyinode()</a> - Gets the inode of the current script</span></li>
    <li><span class="function"><a href="function.getmypid.php" class="function" rel="rdfs-seeAlso">getmypid()</a> - Gets PHP's process ID</span></li>
    <li><span class="function"><a href="function.filemtime.php" class="function" rel="rdfs-seeAlso">filemtime()</a> - Gets file modification time</span></li>
   </ul>
  </p>
 </div>


</div><?php manual_footer($setup); ?>