while trying to use imagesx(), I get an error: undefined function...
it looks like I've got to install the gd library
but using getimagesize(), I get the correct values...
why is this?
I just installed php, haven't installed any library...

    Well the only difference really is that while getimagesize retrieves width and height, imagesx only gets the width of an image. So...as long as getimagesize is working ok for you, then you should be good to go. I assume you want both w and h, not just the w, right? There are two different ways to do this. Either the getimagesize(), or you will have to use imagesx() and imagesy() on the same image to get the same results as getimagesize().

    Hope that helps any,

    -Blake

    P.S. I forgot to mention what mordecai says in below post.

      imagesx() and imagesy() are both GD functions, defined by the GD libs.
      getimagesize() is a native PHP function.

      It's listed under ref.image because it's used for images, but all GD functions begin with image*.

        Write a Reply...