• ×
    Information
    Need Windows 11 help?
    Check documents on compatibility, FAQs, upgrade information and available fixes.
    Windows 11 Support Center.
  • post a message
  • ×
    Information
    Need Windows 11 help?
    Check documents on compatibility, FAQs, upgrade information and available fixes.
    Windows 11 Support Center.
  • post a message
Guidelines
We have new content about printers, Click here to check it out!
Common problems for Connectivity Issues
We would like to share some of the most frequently asked questions about Printer Wi-Fi, Connectivity Issues and Offline Status. Check out this link: HP printer is offline or unavailable.
HP Recommended
M118dw

I am sending a PDF file direct to network attached M118dw laser printer.   I send the PDF file to port 9100 of the printer. But the print does not fit to the page.  Content on the edge of the page is clipped.  Are there print options I can specify when printing a PDF file in this way?

here is the PHP code that is used to send the PDF file to the printer:
  $print_data = file_get_contents('/downloads/packing list (40).pdf') ;

  $fp=pfsockopen("192.168.1.254",9100);
  fputs($fp,$print_data);
  fclose($fp);

 

2 REPLIES 2
HP Recommended

@SteveRichter

Thank you for posting on the HP Support Community.
 

Don't worry as I'll be glad to help, however, to provide an accurate resolution, I need a few more details:

  • Are you printing from your phone or computer?
  • What is the operating system? 

Keep me posted for further assistance.

ECHO_LAKE
I am an HP Employee

HP Recommended

@Echo_Lake 

 

Customer might be referring to PHP coding language as defined here:

What is PHP? 

 

 

Dragon-Fur

† The opinions expressed above are the personal opinions of the authors, not of HP. By using this site, you accept the <a href="https://www8.hp.com/us/en/terms-of-use.html" class="udrlinesmall">Terms of Use</a> and <a href="/t5/custom/page/page-id/hp.rulespage" class="udrlinesmall"> Rules of Participation</a>.