WordPress.org

Ready to get started?Download WordPress

Forums

Using CSS style markup in a post (10 posts)

  1. inspired888
    Member
    Posted 9 years ago #

    Hi there,
    I would like to know if it is possible to use CSS styles within a post?
    Also, I am using the Kubrick template so I assume I'd add my custom CSS styles into the kubrick.css file -- for use in the post as per my first question (above).
    With thanks,
    Jonathan

  2. Mark (podz)
    Support Maven
    Posted 9 years ago #

    Styles in a post ? Yes, so long as you have defined the style in the css already.

  3. serendipity
    Member
    Posted 9 years ago #

    To give an example, I have a class called "ipa" that sets a font for phonetic characters. When I use the international phonetic alphabet in a post, I type <span class="ipa">[...]</span>. Easy as pie.

  4. Root
    Member
    Posted 9 years ago #

    In a similar vein I have .post in my CSS.

  5. inspired888
    Member
    Posted 9 years ago #

    Okay. Thanks for the help.
    So let's say I have .highlight defined in my stylesheet... to use that in a post I simply add the tag
    <span class="highlight">highlighted text</span>
    and that will apply that style. Yes?
    Great. Easy as pie.,
    Cheers,
    Jonathan

  6. Mark (podz)
    Support Maven
    Posted 9 years ago #

    Yup. that'll do the job :)

  7. Mark (podz)
    Support Maven
    Posted 9 years ago #

    And to save any typing, you could make a quicktag for it ?
    http://www.mfr.f2s.com/quicktags/

  8. villas
    Member
    Posted 9 years ago #

    Hmm ... and if I need other CSS file atach only in that post ?

    I mean, for pages in WP 1.3(5) i need other CSS file or a link for it ... ??
    Like that:

    <style type="text/css">
    <!--
    h1 {
    border-bottom-width: 1px;
    border-bottom-style: dotted;
    border-bottom-color: #006600;
    }
    -->
    </style>

    Villas

  9. villas
    Member
    Posted 9 years ago #

    I discover that ! .. just include a new CSS tag in CSS theme file.

    the result: http://musica.educar.pro.br/WPR/index.php?page_id=3

  10. Lorelle
    Member
    Posted 9 years ago #

    Okay, but can you add just a style code within a post such as <a href="dummy.html" style="color:blue;border:solid 1px blue">fred</a>?

    And is there any way to attach a style sheet to just one post. I have done a series of CSS experiments that I want to post out of fixed html and they have styles embedded and added in the header. Any way to make that work?

    If I add all those experimental CSS codes...my style sheet would be a kilometer long. Any way to do that?

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.