Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7492147
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 29, 20262026-05-29T16:22:38+00:00 2026-05-29T16:22:38+00:00

This is not a how to code type question rather it is an approach

  • 0

This is not a how to code type question rather it is an approach that needs to be taken if possible.

Using PHP/MySQL I would like to have a user view something on their screen and then if they decide to print it out add a value from the db. This value should not display on the computer screen though.

Basically the physical medium print job (or print to pdf, etc.) needs to contain an additional value from the db than what screen print would render if the user just copied their screen in some way.

Is this possible? If so what needs to be accomplished to make it all happen?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-29T16:22:40+00:00Added an answer on May 29, 2026 at 4:22 pm

    This is doable with plain HTML and the correct CSS media types. You need only place the print-specific stuff into a container that is designated not to display on screen by CSS:

    Inside print.css:

    .printonly {
      display: block;
    }
    

    Inside screen.css:

    .printonly {
      display: none;
    }
    

    In your HTML:

    Inside the header, use the correct CSS links:

    <link rel='stylesheet' media='screen' href='screen.css' />
    <link rel='stylesheet' media='print' href='print.css' />
    

    And enclose the content in a container with class printonly. This won’t display on screen (in any modern browser) but will be printed out.

    <div class='printonly'>
      only for print!
    </print>
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Not all that sure how I would describe this question, so I'll jump right
This code does not throw an error but the query fails, that is, the
I am using the Python code at the bottom of this question to send
Why does this code not print an exception stack trace? public class Playground {
This is probably a quicky. Why does this code not return anything? import java.util.Scanner;
This code does not seem to compile, I just need to write something to
Why this code does not compile (Cygwin)? #include <vector> template <class Ttile> class Tilemap
This code does not function as expected: // $field contains the name of a
runat=server /> But this code is not working How can I add multiple controls
I am unsure why this code will not work. When I click a button

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.