Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations dencom on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

CSS Print Problemo

Status
Not open for further replies.

multichild

Programmer
Jan 28, 2006
76
GB
Im using css to control the print out, and liked the idea of printing out the url rather than the text.

So im using this:

@media print a:after {
content: " [" attr(href) "] ";
color: #000;
}

but its having an effect, can anyone see why?

also if you got an answer to it, is it possible to have it so that the text is first followed by the url using the css above

lee

Accend Web Solutions

 
I thought it might be the square brackets, so change those and still doesnt work.

@media print a:after {
content: " (" attr(href) ") ";
}

cheers

Lee

Accend Web Solutions

 
See what? We can't see the effect, we just know there's an effect. What kind of effect are you talking about? Have you thought about correctly using the media command in css?
Code:
@media print {
  a:after {
    content: " [" attr(href) "] ";
    color: #000;
  }
}
 
Thanks Vragabond

I just about go there with

@media print
{a:after{
content: attr(href)
}
}

But then found as usual, that it doesnt bloody work in I.E. Have you any work arounds for this.

thanks again

lee

Accend Web Solutions

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top