How To Get Server Info Using PHP

Discussion in 'PHP' started by sami1255, Sep 24, 2008.

  1. #1
    Am looking the way to display server information (on which the site is hosted) on the web page.. like;

    Running On (Operating System Name) (Apache/IIS) (PHP Version) (MySql) (How many SQL queries took place)

    i know almost all these can be viewed using phpinfo() but how to crop the info i needed?

    i know good posts deserve green
     
    sami1255, Sep 24, 2008 IP
  2. eric_basher

    eric_basher Peon

    Messages:
    185
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    0
    #2
    short server information..

    echo $_SERVER['SERVER_NAME'].' ';
    echo $_SERVER['SERVER_SIGNATURE'];
     
    eric_basher, Sep 24, 2008 IP
  3. sami1255

    sami1255 Well-Known Member

    Messages:
    835
    Likes Received:
    24
    Best Answers:
    0
    Trophy Points:
    125
    #3
    it works but the question stays there on the operating system, mysql and the sql queries took place !
     
    sami1255, Sep 24, 2008 IP
  4. piehead2000

    piehead2000 Peon

    Messages:
    11
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #4
    <?php var_dump($_SERVER); ?>
     
    piehead2000, Sep 24, 2008 IP