Web Analytics Made Easy -
StatCounter Printing and Posting - CodingForum


No announcement yet.

Printing and Posting

  • Filter
  • Time
  • Show
Clear All
new posts

  • Printing and Posting

    Hi Guy's.

    I have a form that when submitted will insert all the data into a table.

    My question: Is it possible to submit the form to the database and at the same time physically print to printer?

    I hope this is not a stoooopied question.


  • #2
    Who's printer? Your printer?

    It appears to be possible - http://my.php.net/manual/en/ref.printer.php - but I don't really know. It would be significantly easier if the server had access to this network printer, but I'm guessing it wont. I'm really not sure how you would go about printing on a different network printer, if that is even possible, but hopefully that man page will at least give you a start.

    I'm not really sure why you would want to anyway, to be honest . Sounds like a waste of environmental resources lol for the simple reason that you have an online, 'cloud' of data anyway. It would be a better solution to maybe get the processing script to parse the information into a pdf file, then send it to you by email? That way you can choose to print it at home, if it's needed.
    Last edited by BluePanther; Aug 22, 2011, 03:20 AM.
    Useful function to retrieve difference in times
    The best PHP resource
    A good PHP FAQ
    PLEASE remember to wrap your code in [PHP] tags.
    PHP Code:
    // Replace this
    // With this
    // Then check for values/forms. Some IE versions don't send the submit button 
    Always code as if the guy who ends up maintaining your code will be a violent psychopath who knows where you live.