79337069

Date: 2025-01-07 19:02:28
Score: 1
Natty:
Report link

You could try using @media print in your CSS to force the table borders and background colors to appear.

For example:

@media print {
  table {
    border-collapse: collapse; /* Ensures borders display properly */
  }
  table, th, td {
    border: 1px solid black; /* Forces visible borders */
  }
  th, td {
    background-color: #f0f0f0 !important; /* Forces background colors */
    color: black !important; /* Ensures text is visible */
  }
}

I’ve had a similar issue before where certain styles were being overridden or ignored during printing.

Reasons:
  • Long answer (-0.5):
  • Has code block (-0.5):
  • User mentioned (1): @media
  • Low reputation (1):
Posted by: Sailor Moon