Read the width and height of an image

Discussion in 'ASP General' started by Stilts, Apr 6, 2006.

  1. Stilts

    Stilts Guest

    Hi

    Working in asp (not asp.net) I need to read the width and height of an
    image before they are displayed on the page.

    I have a folder full of images that are dynamically put on a page and I
    need to read if they are landscape or protrait.

    Any help much appreciated.

    :)
     
    Stilts, Apr 6, 2006
    #1
    1. Advertising

  2. Stilts

    Slim Guest

    I don't thing you can server side.

    you may need to do so client side



    "Stilts" <> wrote in message
    news:...
    > Hi
    >
    > Working in asp (not asp.net) I need to read the width and height of an
    > image before they are displayed on the page.
    >
    > I have a folder full of images that are dynamically put on a page and I
    > need to read if they are landscape or protrait.
    >
    > Any help much appreciated.
    >
    > :)
    >
     
    Slim, Apr 6, 2006
    #2
    1. Advertising

  3. Stilts

    Stilts Guest

    There must be a way for the web code to read the image in a folder??

    Help!
     
    Stilts, Apr 6, 2006
    #3
  4. Stilts

    Evertjan. Guest

    Slim wrote on 06 apr 2006 in microsoft.public.inetserver.asp.general:
    > "Stilts" <> wrote in message
    > news:...
    >> Working in asp (not asp.net) I need to read the width and height of an
    >> image before they are displayed on the page.
    >>
    >> I have a folder full of images that are dynamically put on a page and I
    >> need to read if they are landscape or protrait.


    [please do not toppost on usenet]

    > I don't thing you can server side.
    >
    > you may need to do so client side


    PHP can (sorry OT):

    getimagesize()

    --
    Evertjan.
    The Netherlands.
    (Please change the x'es to dots in my emailaddress)
     
    Evertjan., Apr 6, 2006
    #4
  5. Stilts

    Evertjan. Guest

    Stilts wrote on 06 apr 2006 in microsoft.public.inetserver.asp.general:

    > There must be a way for the web code to read the image in a folder??


    Please quote what you are replying to. If you want to post a followup via
    groups.google.com, don't use the "Reply" link at the bottom of the article.
    Click on "show options" at the top of the article, then click on the
    "Reply" at the bottom of the article headers.
    <http://www.safalra.com/special/googlegroupsreply/>

    --
    Evertjan.
    The Netherlands.
    (Please change the x'es to dots in my emailaddress)
     
    Evertjan., Apr 6, 2006
    #5
  6. Stilts

    Stilts Guest

    Justin Piper wrote:
    > On Thu, 06 Apr 2006 09:03:46 -0500, Stilts <> wrote:
    > > Working in asp (not asp.net) I need to read the width and height of an
    > > image before they are displayed on the page.

    >
    > ImageMagick comes with a COM object that can do this.
    >
    > ' = Function: Dimensions =
    > ' Use an instance of the ImageMagickObject to determine the width and
    > ' height of an image.
    > '
    > ' Arguments:
    > ' im - An instance of the ImageMagickObject.
    > ' src - The name of the source file.
    > '
    > ' Returns:
    > ' An array containing the width and height as elements 0 and 1,
    > ' respectively.
    > Function Dimensions(im, src)
    > Dim msgs
    > msgs = im.Identify("-format", "%w,%h", src)
    > Dimensions = Split(msgs)
    > End Function
    >
    > You can find it at http://www.imagemagick.org/.
    >
    > --
    > Justin Piper
    > Bizco Technologies
    > http://www.bizco.com/


    Sorry but I'm not sure about above. I gather there's no standard asp
    version like phps getimagesize()???
     
    Stilts, Apr 6, 2006
    #6
  7. http://www.planet-source-code.com/vb/scripts/ShowCode.asp?lngWId=4&txtCodeId=6629


    "Stilts" <> wrote in message
    news:...
    > Hi
    >
    > Working in asp (not asp.net) I need to read the width and height of an
    > image before they are displayed on the page.
    >
    > I have a folder full of images that are dynamically put on a page and I
    > need to read if they are landscape or protrait.
    >
    > Any help much appreciated.
    >
    > :)
    >
     
    Kyle Peterson, Apr 6, 2006
    #7
  8. Stilts

    Stilts Guest

    Thanks Kyle, much appreciated :)
     
    Stilts, Apr 7, 2006
    #8
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. AndrewF
    Replies:
    1
    Views:
    785
    Bruce Barker
    Oct 10, 2005
  2. Sean Jorden
    Replies:
    1
    Views:
    600
    laurie
    Aug 19, 2003
  3. Lois
    Replies:
    1
    Views:
    3,245
    Ryan Stewart
    Dec 27, 2004
  4. cera
    Replies:
    1
    Views:
    1,275
    Neredbojias
    Aug 18, 2007
  5. Bernd Meier
    Replies:
    6
    Views:
    518
    GTalbot
    Jan 14, 2008
Loading...

Share This Page