zenphoto forums » General Zenphoto Discussion

PHP Call to Retrieve image type: .jpg, .png, so on

(4 posts)

Tags:

  1. Celcius

    Member
    Joined: Jan '11
    Posts: 11

    I am looking for a call that will return the image type: jpg, png, gif, bmp, and so on.

    getBareImageType()

    Or something like that. Does that exist?

    Posted 2 years ago #
  2. Zenphoto development team
    sbillard

    Chief Developer
    Joined: May '07
    Posts: 9,767

    getSuffix(imageobj->filename)

    Don't forget to read the Forum rules and usage resources
    Posted 2 years ago #
  3. Celcius

    Member
    Joined: Jan '11
    Posts: 11

    Didn't work for me:

    Parse error: syntax error, unexpected T_STRING in ... on line 75

    EDIT:

    Actually this is the error I am getting now:

    Parse error: syntax error, unexpected T_OBJECT_OPERATOR in ... on line 75

    Posted 2 years ago #
  4. Celcius

    Member
    Joined: Jan '11
    Posts: 11

    I did a search on this call:
    getFullImageURL();
    to match it up with .jpg and so on, to determine the filetype.
    It's a pretty hackish, but it works for now.

    Posted 2 years ago #

RSS feed for this topic

Reply

You must log in to post.