Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Prevent website url in print from javascript

Hello (Prevent website url in print from javascript?)

I am sure some simple solution exists. I have a webapp, and I use a specific css for printing this form, which is working great. However on each paper it always prints the "URL" for the webapp, which I do not want. I am not sure but I suppose it's the browser that automatically includes this and not my webapp since that string does not exist in it at all, and I suppose there is no magic trick for hiding that in the print stylesheet either?

This URL is usually printed in the top center or bottom center/bottom right, it varies depending on browser

Anyway hopefully someone knows, thanks! It sucks! ;)

like image 556
neph Avatar asked May 10 '26 20:05

neph


1 Answers

You can't control this and it does suck. One way to get around this is to generate a PDF document for printing. Any document that is downloaded and printed from the client machine rather than from within the browser will not have this problem.

like image 103
D'Arcy Rittich Avatar answered May 13 '26 10:05

D'Arcy Rittich



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!