I'm attempting to customize the print CSS, and finding that it prints links out with the href
value as well as the link.
This is in Chrome.
For this HTML:
<a href="http://www.google.com">Google</a>
It prints:
Google (http://www.google.com)
And I want it to print:
Google
Work's perfect.
If you use the following CSS
just change it into the following style by adding media="screen"
I think it will work.
the former answers like
were not worked well in the chrome browse.
I encountered a similar problem only with a nested img in my anchor:
When I applied
I lost my img and the entire anchor width for some reason, so instead I used:
which worked perfectly.
Bonus tip: inspect print preview
It doesn't. Somewhere in your print stylesheet, you must have this section of code:
The only other possibility is you have an extension doing it for you.
Bootstrap does the same thing (... as the selected answer below).
Just remove it from there, or override it in your own print stylesheet:
For normal users. Open the inspect window of current page. And type in:
Then you shall not see the url links in print preview.