?

Log in

No account? Create an account

Previous Entry | Next Entry

I'm curious if there is a way to put a border around, or change the background color of, the sticky post and ONLY the sticky post. Basically, I'd like to set it apart from the rest of the entries in my community gardening

Suggestions? I know how to change the background color for the title of the sticky post, but that's not quite what I'm looking for.

Thanks for the help!

Comments

( 1 comment — Leave a comment )
av8rmike
May. 30th, 2008 02:04 pm (UTC)
If you want to add a background using a CSS-only method, there's one described here, which basically involves adding a background image to #alpha-inner and positioning it to line up with the sticky post.

A better (IMHO) method is to add a specific CSS ID to the sticky post, which will allow you to apply CSS styling to it specifically. The downside is that it requires a Paid account and theme layer.
function print_sticky() {
    if ($*sticky_post != "") {
        var string id = " id=\"asset-stickypost\""; # Add a CSS ID to the HTML element
        """
    <div$id class="post-asset asset">
      <div class="asset-inner">
        <div class="asset-header">
          <div class="asset-header-inner">
            <div class="asset-header-content">
              <div class="asset-header-content-inner">
        """;

        if ($*sticky_subject != "") {
            print safe """<h2 class="asset-name page-header2 asset-name-hover">$*sticky_subject</h2>""";
        } else {
            """<h2 class="asset-name page-header2 asset-name-hover">Sticky Post</h2>""";
        }

        "</div></div></div></div>\n";
        """<div class="asset-content">
         <div class="asset-body">""";

        print safe $*sticky_post;

        "</div>\n</div>\n";
        """<div class="asset-footer"></div>\n</div>\n</div>\n""";
    }
}
( 1 comment — Leave a comment )

Latest Month

March 2016
S M T W T F S
  12345
6789101112
13141516171819
20212223242526
2728293031  

S2 Help Communities

Tags

Powered by LiveJournal.com
Designed by chasethestars