1. Advertising
    y u no do it?

    Advertising (learn more)

    Advertise virtually anything here, with CPM banner ads, CPM email ads and CPC contextual links. You can target relevant areas of the site and show ads based on geographical location of the user if you wish.

    Starts at just $1 per CPM or $0.10 per CPC.

How to check if GD Library is installed?

Discussion in 'Apache' started by netpox, Feb 1, 2007.

  1. #1
    I have a dedicated server and under root i went to Software - Apache Update and on the list i saw GD (version 2.0.15) i am assuming thats GD Library. i checked that and started the build. After everything was done i go back and GD is still unchecked!

    Did it install? how do i check if it is installed? how do i install it if i did it wrong?
     
    netpox, Feb 1, 2007 IP
  2. aplus

    aplus Well-Known Member

    Messages:
    83
    Likes Received:
    3
    Best Answers:
    0
    Trophy Points:
    115
    #2
    do a
    
    <?php phpinfo(); ?>
    
    PHP:
    and search for the gd section. if there isnt, then you dont have it installed

    hope it helps
     
    aplus, Feb 1, 2007 IP
  3. netpox

    netpox Active Member

    Messages:
    1,625
    Likes Received:
    27
    Best Answers:
    0
    Trophy Points:
    90
    #3
    Thanks i did that and found this:
    GD Support enabled
    GD Version bundled (2.0.28 compatible)

    So it seems like its there...thanks!
     
    netpox, Feb 1, 2007 IP
  4. netpox

    netpox Active Member

    Messages:
    1,625
    Likes Received:
    27
    Best Answers:
    0
    Trophy Points:
    90
    #4
    Well my uploaded photos still dont show up..not sure why
     
    netpox, Feb 1, 2007 IP
  5. nirghum

    nirghum Banned

    Messages:
    44
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #5
    if you phpinfo showing gd is installed but if the photos are still not showing, then it might be a problem of your script. I think you should recheck your script.
     
    nirghum, Feb 3, 2007 IP
  6. JRBHosting

    JRBHosting Peon

    Messages:
    121
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    0
    #6
    Just an easier way to do the check for GD in a program

    
    <?php
    $data = phpinfo();
    if (preg_match("GD Support enabled",$data)) {
         // GD is there
    }
    ?>
    
    Code (markup):
     
    JRBHosting, Feb 4, 2007 IP
  7. trevlar

    trevlar Peon

    Messages:
    65
    Likes Received:
    10
    Best Answers:
    0
    Trophy Points:
    0
    #7
    That won't work, and it wouldn't be the best way even if it did.

    Try this:
    <?php
    if (extension_loaded('gd') && function_exists('gd_info')) {
    	echo "It looks like GD is installed";
    }
    ?>
    PHP:
    You could also spit some info about your GD version by doing this:

    <?php
    echo "<pre>"; var_dump(gd_info()); echo "</pre>";
    ?>
    PHP:
     
    trevlar, Feb 4, 2007 IP
  8. Manav1480

    Manav1480 Peon

    Messages:
    1
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    1
    #8
    type this in your shell:
    echo "<? phpinfo();" | php | grep GD

    You will see something like:
    GD Support => enabled
    GD Version => 2.0
     
    Manav1480, Feb 28, 2014 IP