?

Log in

No account? Create an account

Previous Entry | Next Entry

Subhead on friends page? - Solved

  • Feb. 10th, 2007 at 5:15 PM
I've looked through the tags here and haven't really found anything about this. I know that you can assign a sub-head to the main journal page just by typing it into the "Basics" tab in the Edit Journal Style area. But I'm wondering if there is any css that you could use to put a subhead on your friends page? I tried changing the #header-name but all it did was override the journal sub-head (unless I'm doing something wrong). Any ideas?

Comments

( 2 comments — Leave a comment )
av8rmike
Feb. 12th, 2007 08:44 pm (UTC)
Not with straight CSS, no. You'll have to override the Page::lay_print_header_links () function in your theme layer, like so:
function Page::lay_print_header_links() {
    # Menu start
    """<div id="message-window" class="hidden"></div>\n""";
    container_open("header");
    container_open("header-content");
    """<div id="header-photo">\n<div id="header-photo-inner"></div>\n</div>\n""";
    """<div id="header-text"><ul class="nav">\n""";

    # Standard Journal Pages (Recent, Archive, Friends, Userinfo)
    foreach var string v ($.views_order) {
        var string url   = $.view_url{$v};
        var string text  = lang_viewname($v);
        var string class = "item";
        if($v == $.view) {
            $class = $class + " current";
        }
        if($v == $.views_order[0]) {
            $class = $class + " first";
        }

        $class = " class=\"$class\"";

        print """<li$class><a href="$url" title="$text">$text</a></li>""";
    }

    var Link memories_url = $.journal->get_link("memories");

    # Memories
    if($memories_url.url != "") {
        println """<li class="item"><a href="$memories_url.url" title="$*text_view_memories">$*text_view_memories</a></li>""";
    }

    # Menu end
    """
    </ul>
    <div id="header-name">""";
    var string base_url = $.journal->base_url();
    var string friends_url = $.view_url{"friends"};
    if ($this isa FriendsPage) {
        """<a href="$friends_url">""" + $this->view_title() + """</a>""";
    } else {
        """<a href="$base_url">$.global_title</a>""";
    }
    """
    </div>""";

    if($this isa FriendsPage) {
        """
      <div id="header-description">Crazy, Crazy friends</div>""";
    } else {
        """
      <div id="header-description">$.global_subtitle</div>""";
    }

    """
    </div>
    </div><span id="header-content-decor" class="decor"><b></b><u></u><s></s><i></i></span></div><!-- End Header Content -->
    </div><span id="header-decor" class="decor"><b></b><u></u><s></s><i></i></span></div><!-- End Header -->""";
}
The section in blue is the part I changed.
dragonheart97
Feb. 15th, 2007 11:07 pm (UTC)
Ahh okay... bit more complicated than I thought but at least there is a way if I decide to give it a shot. Thank you! (and sorry this reply is so late!)
( 2 comments — 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