CSS
-Tricks
treehouse :
what would you like to learn today?
Web Design
Web Development
iOS Development
Show search box
Search
Search in:
All
Articles
Forums
Snippets
Videos
✕
Home
Forums
Snippets
Gallery
Videos
Almanac
Demos
Lodge
Navigation 'n' Search
Forums
Illustration by Nick Sirotich
Forums
»
CSS Combat
Add // to h1 tags
acondiff
Permalink to comment
#
February 2010
I was just wanting to know the best wat to add "//" At the begining of my text inside h1, h2, h3, and h4 tags. Could it be done with css or would I have to use javascript or even php? Any help would be great!
Thanks.
TT_Mark
Permalink to comment
#
February 2010
Can I ask why? Not certain, but I think adding // as text may have SEO implications so might be best to use a background image
acondiff
Permalink to comment
#
February 2010
Just a design look I was going for, but if it will hurt my ranking I wont do it.
coryschadt
Permalink to comment
#
February 2010
Ya a background image would probably be a good idea.
You could also do it with jquery.
Something like this:
$('//').prependTo('h1');
http://api.jquery.com/prependTo/
Cheers,
Cory
Robskiwarrior
Permalink to comment
#
February 2010
if you dont want any code implications you can use
&frast; &frast;
that would give //.
Add a Comment
Thanks.
You could also do it with jquery.
Something like this:
$('//').prependTo('h1');http://api.jquery.com/prependTo/
Cheers,
Cory