pdfLib create_pvf

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • 2bee
    New Member
    • Feb 2009
    • 1

    pdfLib create_pvf

    I'm having trouble creating multiple PVF files.

    It works with a single operKey, but not with multiple operKeys, the careQuery.php below goes to a database and pulls out a blob photo.

    Can anyone give me a clue?
    [code=php]
    $p->begin_docume nt ( "", "" ) ;
    for ( $k = 0; $k <= 3; $k += 1) {
    $p->begin_page_e xt ( $pagewidth, $pageheight, "" );
    $operKey = '10019152';

    /* This is commented out 'cause it doesn't work
    if ($k=0)
    $operKey = '10019152';
    if ($k=1)
    $operKey = '10000431';
    if ($k>1)
    $operKey = '10017721';
    */

    include './cardQuery.php';

    //Create PDF Virtual File (PVF)
    $pvf_filename = "/var/www/html/jops/" . $operKey . ".jpg";
    $p->create_pvf($pv f_filename,$pic ture,"");
    $image2 = $p->load_image("jp eg", $pvf_filename, "");
    $p->fit_image($ima ge2, 160,70,
    "boxsize={6 5 70} position={left top} fitmethod=meet" );
    $p->delete_pvf($pv f_filename);
    $p->end_page_ext ( "" );

    }
    $p->end_document ( "" );[/code]
    Last edited by Atli; Feb 4 '09, 04:37 PM. Reason: Added [code] tags.
Working...