printer extension problems

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hey guys,

I'm writing a small script that will print pick lists for our online orders
using the printer functions provided with the stock extension. The problem
is I can't get it to span across multiple pages. I've tried checking the Y
position and using end_page and start_page accordingly but for some reason
it's locking up. Here's my code, I'm only posting the bit that's making it
lock up. If I take this bit out it prints flawlessly but it only gives me
one page of data. I commented it out after the fact so if anything isn't
clear just ask me to clarify.

if ($y == 6210){
   // I stuffed $y in to see where the page ended, the last line was 6210
   // $y increments 110 after every line I draw_text to with a little $y =
$y + 110;
   printer_delete_font($itemFont);
    // I've tried it with and without deleting the font but I get the same
results
   printer_end_page($handle);
    // according to the doc this shold end the page
   $itemFont = printer_create_font("Arial",72,48,400,false,false,false,0);
   // recreate the font
   printer_select_font($handle, $itemFont);
 // ..
   printer_start_page($handle);
   // this _should_ start a new page, below I have $y starting at 110 just
for the margin
   $y = 110;
  }

What am I doing wrong here? I've searched through tons of google's to find
an example of someone doing this but all I can find are endless amounts of
manual entries on the same functions. Little help?

-Chris

-- 
PHP Windows Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [PHP Users]     [PHP Database Programming]     [PHP Install]     [Kernel Newbies]     [Yosemite Forum]     [PHP Books]

  Powered by Linux