dongmou9260 2013-01-02 22:23
浏览 18

加载页面时将时间存储在变量中

Is there a way to store the time when a page is loaded in a variable?

This is what I got:

<?php 
$time = time();
echo "Page loaded:"  . time() ?>

However this doesn't do what I want, it shows the current time, not the time when the page was loaded.

Any hints on how to do this is highly appreciated! :)

  • 写回答

2条回答 默认 最新

  • dtrovwl75780 2013-01-02 22:24
    关注

    You want $time, the variable you created, not time(), another call to the time function.

    评论

报告相同问题?