Hello and welcome to our community! Is this your first visit?
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2

Thread: EXIF Thumbnails

  1. #1
    New to the CF scene
    Join Date
    Jan 2004
    Thanked 0 Times in 0 Posts

    EXIF Thumbnails

    I'm trying to display the thumbnail contained within the EXIF data of a picture file using the following code:

    $testthumbnailimage = exif_thumbnail([file path and name],$width, $height, $tempType);
    echo $testthumbnailimage;

    This code produces nothing. But if I remove the ,$width, $height, $tempType section from the first line, the following is displayed on my page:

    ۄ    !#"! $)4,$'1'-=-167:::"*?D>8B3796    OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOx ! }!1AQa"q2#BR$3br %& '()*456789:CDEFGHIJSTUVWXYZcdefghijstuvwxyz
     w!1AQaq"2B #3Rbr $4%& '()*56789:CDEFGHIJSTUVWXYZcdefghijstuvwxyz
    ?_Ξ- o_!Qk6 ^+uSy[GG  ŽAQR74Kom1vZa;k[Wd19#4'~>qV𵴶!0- s(]Kq˂yY'١KqTgFwt҃Z=*nKN!B|Ҵd=\:l
    H ;eG*q@Y*_qzj!$ R&=}FdGD5Afׇ.#Ԑ38<_ihk-"fUyXti´S[ cn8ˌC}EE|J93j8w=[_屲I8qޱ<)f.|Jzw+?%¿ C.y/Kj<k_bdOQOxZxZ@.*9@ʃ+yAfiY1ԟ r_S6YĪPWNP'r^G$35[G/䪎d3HK!s=so:̎SJppg\ֆ]:Q=9Ɩ Fe~\/eVt5v;VU#k.D3oC+%'WFhU!j2E"2) U) QS)r8\458R숎$E{E2kMA'Y,zv>T ANzT$Ӗo_ù N.]CT_9-w[c_f* ԓPj Q+V> s&T}*[v7d8AұnQI/#jtl?/l^g[e  ͫU4Gym g;Mfʩvg~SV͌QFH^QmNo?(wQ)V(GM;zl|)i {ޥ֝YSMEI1$8Ғ*M;25 X3D#S}kOTX}_sErMvg'_J p3SJǓM{ߊQ]cF:R /]'`8yةYm#ά9it#+6(sTʤl]lCusy L"b͓^%dmR"wr~i_c]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x ,<jEJV{b]M BȪQQi* 9Ͽac+&p RfaFx_׷F7]_ i.& zgJY-Ѣ.>Ki[o$ _~<ƫfYc24!FGθ\_n6ŎևU 75dRfg ֜)?M|mmvrn# [ B ϱ ,W)݀a}b+M#<AqH,P&it'xUC#AZv*]Ջ==I#LֲSgkM|}̅c1i+IUI{;&5_rR=_!j2x;

    I added
    header("Content-type: image/jpeg");
    to the top of my page, but still no luck.

    I was able to extract and display EXIF info about the file (comments and such), and would like to utilize the embedded thumbnails to make my life easier.


  • #2
    Super Moderator
    Join Date
    May 2002
    Perth Australia
    Thanked 92 Times in 90 Posts
    did you set the header type ??

    $testthumbnailimage = exif_thumbnail([file path and name],$width, $height, $type);
    header("Content-type: ".image_type_to_mime_type($type)); echo $testthumbnailimage;

    resistance is...

    MVC is the current buzz in web application architectures. It comes from event-driven desktop application design and doesn't fit into web application design very well. But luckily nobody really knows what MVC means, so we can call our presentation layer separation mechanism MVC and move on. (Rasmus Lerdorf)


    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts