Jump to content

css style for a word in a paragraph


kiran22smiles

Recommended Posts

hi all

 

i have one probelm with css classes, i want a seperate css style for a word in a paragrapah without mentioning any attributes.

 

Example :

 

dfgfdgdfgsdgdfgdfggsgdggsd 'class' sdgfsdfsfsdfsdfsdf

 

 

in above paragraph i want a styel for word 'class'

 

is there any possibility. plz help me.

 

thanks in advance:(

Link to comment
Share on other sites

If you only want to style that one occurance in the whole site, just use inline styling:

 

dfgfdgdfgsdgdfgdfggsgdggsd 'class' sdgfsdfsfsdfsdfsdf

 

If the word 'class' occurs more often on your site, then put the CSS into your external stylesheet:

 

dfgfdgdfgsdgdfgdfggsgdggsd 'class' sdgfsdfsfsdfsdfsdf

 

and your CSS

 

.different {font-color: #123456;}

 

There's no way to avoid attributes - unless you are using an existing selector like:

 

dfgfdgdfgsdgdfgdfggsgdggsd 'class' sdgfsdfsfsdfsdfsdf

 

and CSS:

 

em {font-color: #123456;}

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...