Hi, Can anyone let me know if it is possible to style individual letters. So for example in the word 'welcome' the W would be big and curly?
Many thanks,
Slooshy![]()
| SitePoint Sponsor |
Hi, Can anyone let me know if it is possible to style individual letters. So for example in the word 'welcome' the W would be big and curly?
Many thanks,
Slooshy![]()

Wrap the letter(s) to be styled inside a span tag with an appropriate class.
Stephen J Chapman
javascriptexample.net, Book Reviews, follow me on Twitter
HTML Help, CSS Help, JavaScript Help, PHP/mySQL Help, blog
<input name="html5" type="text" required pattern="^$">


The :first-letter pseudo element in CSS is fairly widely supported today, so you use it to pick that letter out, if you like.

Hello
Well if W is the first letter of a paragraph you can do:HTML Code:<p class="first">Welcome to my site here is some text to tell you what it is about.</p>http://reference.sitepoint.com/css/p...nt-firstletterCode:p.first:first-letter { font-family:Georgia, Serif; font-size:1.1em; font-weight:bold; }
If however it is just a random word in a paragraph than you could do:HTML Code:<p>Here is some text to tell you what my site is about, <span class="first">W</span>elcome</p>Hope it helps.Code:.first{ font-family:Georgia, Serif; font-size:1.1em; font-weight:bold; }![]()



This tutorial could help - How to use initial caps
Trisha Cupra, Web Design Watchdog
Protecting website owners from the most painful online mistakes
I would go with span tags.
Bookmarks