Help Regarding Php fpdf library

Discussion in 'PHP' started by Talat50, Dec 29, 2010.

  1. #1
    Hello every one i m using fpdf libray to creat pdf files from html form.

    i m using

    $pdf->Image('gg.PNG',60,140,120,0,'','');

    to display image on pdf.

    in its first parameter it asks for exact path.it doesn't accept any variable here.
    but i want to make dynamic.i have able to get a complete path in an variable.

    i have printed this variable.

    echo "$path";

    output
    ////////////////////
    <img alt="" src="file:///C:/DOCUME%7E1/gg.PNG"

    but how i put that path from variable in this parameter.?
     
    Talat50, Dec 29, 2010 IP
  2. shofstetter

    shofstetter Well-Known Member

    Messages:
    178
    Likes Received:
    7
    Best Answers:
    1
    Trophy Points:
    120
    #2
    The image has to be accessible to php. If it is not on the server with the script or is not accessible using a url it won't work. You could use a file input to upload the image. check out: http://www.tizag.com/phpT/fileupload.php
     
    shofstetter, Dec 29, 2010 IP