Results 1 to 10 of 10

Thread: PHP

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Registered User Airfan's Avatar
    Join Date: Dec:2001
    Location: Plovdiv
    Posts: 89

    PHP

    ,

    , 1 1900 . 16 2006 38823, 38823- 1 1900 . .
    .

    !
    I7-4770K@GA-Z97X-UD3H + CM Hyper 212 Evo + CM N500 + 4 x 4GB Geil Enhance Corca 1600MHz + Sapphire HD 5850 (Game edition)

  2. #2
    ! vbTheKing's Avatar
    Join Date: Sep:2003
    Location:
    Posts: 4,138
    - mktime(), Unix Timestamp 1970 , , . 60*60*24 (60 60 24 = 86400 ) 1900 . 1970 . ( 70*365+17 (17 ) = 25567).

    :
    PHP Code:
    <?php
    $day 
    19;
    $month 4;
    $year 2006;

    $seconds mktime(000$month$day$year);
    $days $seconds 86400;
    $total_days $days 25567;
    echo 
    rpund($total_days); //round()     -        ;)
    ?>

    , html .
    ''? * *
    - !
    ...

  3. #3
    Registered User LadyCroftFan's Avatar
    Join Date: Mar:2003
    Location: Kustendil
    Posts: 86
    ...

    PHP Code:
    <?php
    echo round((time()-mktime(000111990))/864000)."    01.01.1990.";
    ?>
    , :

    round() ( manual- ).

    time() 01.01.1970 .
    mktime() 01.01.1970 , :
    , , , , ,
    01.01.1970 01.01.1990.

    86400 (60*60*24).

    , , , . .-, .

    ,

    ...

    .. , ,

    Edit:: , strtotime() manual-a php-, , .
    I wanna love you, but I better not touch
    I wanna hold you, but my senses tell me to stop
    I wanna kiss you, but I want it too much

  4. #4
    ! vbTheKing's Avatar
    Join Date: Sep:2003
    Location:
    Posts: 4,138
    Quote Originally Posted by LadyCroftFan
    mktime() 01.01.1970 , :
    , , , , ,
    : , , , , ,

    , .
    , , , , . - ,
    PHP Code:
    $day 19
    $month 4
    $year 2006

    $seconds mktime(000$month$day$year); 

    PHP Code:
    $seconds time(); 
    ''? * *
    - !
    ...

  5. #5
    Registered User LadyCroftFan's Avatar
    Join Date: Mar:2003
    Location: Kustendil
    Posts: 86
    , , , .

    , , 10 , , 01.01.1970 .

    ..
    I wanna love you, but I better not touch
    I wanna hold you, but my senses tell me to stop
    I wanna kiss you, but I want it too much

  6. #6
    relative dude Skydive's Avatar
    Join Date: Nov:2002
    Location: /
    Posts: 2,863
    Quote Originally Posted by LadyCroftFan
    , , 10
    , ?

  7. #7
    ! vbTheKing's Avatar
    Join Date: Sep:2003
    Location:
    Posts: 4,138

    Cool

    Quote Originally Posted by LadyCroftFan
    , , 10
    ? , , Airfan.
    ''? * *
    - !
    ...

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

Copyright © 1999-2011 . .
iskamPC.com | mobility.BG | Bloody's Techblog | | 3D Vision Blog |