(no subject)

Jan 23, 2006 12:40

Let me just start off as saying I have no idea how any of this works. I'm fairly competent in HTML, but this-- I don't know what this is. This is HTML's deformed cousin who smells of cheese and no one likes.

User layout: ezqiinah
Problem areas: See Below

Okay, I've looked through the tags and memories, and I've found a few people with the same problem, but I still can't figue it out.

1) I'm trying to get my nav bar to line up with the rest of my journal (500px). Now, I know how to line everything else up with the nav bar, but not the other way around. Tried changing the "set page_width" up at the top, there, because it SEEMED like something that would do... something. But no-- I don't even know what that's there for.

I'm using Aeval's code (modified by Kunzite1) by the way.

And a few smaller issues-- also looked in the memories/tags. Found some answers, none of which worked.

2) How do I make the subject uppercase? I've seen the code used to do this (.subject {text-transform: uppercase;} ), but I can't get it to work for me. And how about links, too?

3) How do you get a -text- divider inbetween the links of the linklist? So far, all I've been doing is typing "//" before every link title.

4) Is it possible to add some space (or maybe even the above mentioned divider) between the nav links?

5) Aaand finally, how do I change the "<" in the nav bar to "<<<" or whatever? I found someone with the exact same problem, and it was answered. but I can't figure out WHERE to change the code. I think she was using Aeval's original code, which is probably why.


Hey, is this box freakishly small and hard to read for anyone else?

layerinfo "type" = "theme";
layerinfo "name" = "Simple Boxer (k1)";
layerinfo author_name = "Aeval @ LJ/Kunzite1 @ LJ";
layerinfo "des" = "Original modifications by Aeval. Cleaned by Kunzite1.";

set bg_color = "#f4f4f4";
set color_nav_bg = "#f4f4f4";
set entry_bg = "#ffffff";
set entry_font = "#000000";
set entry_link = "#c2c2c2";
set entry_link_visited = "#c2c2c2";
set font_family = "Verdana";
set font_size = "small";
set info_bg = "#c2c2c2";
set info_font = "#000000";
set info_link = "#c2c2c2";
set info_link_visited = "#c2c2c2";
set lineheight = 12;
set linklist_support = true;
set links_divider = "//";
set links_name = "";
set my_date = "long";
set nav_link = "#000000";
set nav_scale = "same";
set page_background_image = "";
set page_background_pattern = "none";
set page_friends_items = 25;
set page_recent_items = 5;
set page_width = 500;
set show_entry_userpic = false;
set show_mini_calendar = true;
set tags_aware = true;
set text_meta_mood = "Current Mood:";
set text_meta_music = "Current Music:";
set text_view_archive = "memories";
set text_view_friends = "Friend-types";
set text_view_month = "calendar";
set text_view_recent = "recent";

function Page::print_custom_head() {
"""

""";
}

function Page::print_linklist() {
"""


""";
if((size($.linklist) > 0) and $*linklist_support) {
var bool section_open = false;
"""

""";
foreach var UserLink link ($.linklist) {
if($link.is_heading) {
if($section_open) {
"
\n";
}
"""$link.title: """;
$section_open = true;
} else {
"""$link.title """;
}
}
"""


""";
}
"""


""";
}

function Page::lay_viewspec_nav() {
var string prev_url = "";
var string prev_text = "<";
var string next_url = "";
var string next_text = ">";

if($this isa RecentPage) {
var RecentPage rp = $this as RecentPage;

$prev_url = $rp.nav.backward_url;
$next_url = $rp.nav.forward_url;
}
if($this isa YearPage) {
var YearPage yp = $this as YearPage;

# $prev_url = $rp.nav.backward_url;
# $next_url = $rp.nav.forward_url;
}
if($this isa MonthPage) {
var MonthPage mp = $this as MonthPage;

$prev_url = $mp.prev_url;
$next_url = $mp.next_url;
}
if($this isa DayPage) {
var DayPage dp = $this as DayPage;

$prev_url = $dp.prev_url;
$next_url = $dp.next_url;
}
if($this isa EntryPage) {
var EntryPage ep = $this as EntryPage;

var Link prev = $ep.entry->get_link("nav_prev");
var Link next = $ep.entry->get_link("nav_next");
$prev_url = $prev.url;
$next_url = $next.url;
}
if($this isa ReplyPage) {
var ReplyPage rp = $this as ReplyPage;

var Link prev = $rp.entry->get_link("nav_prev");
var Link next = $rp.entry->get_link("nav_next");
$prev_url = $prev.url;
$next_url = $next.url;
}

if($prev_url != "") {
"""$prev_text""";
}
if($next_url != "") {
"""$next_text""";
}
}

function Entry::print_metadata() {
# set header text for tags
var string tags_header = "Current Tags";
# set colon
var string tags_joiner = ":";
# can remote user edit tags?
var Link edit_tags = $this->get_link("edit_tags");

if ((size $.metadata > 0) or ($*tags_aware and (size $.tags > 0))) {
var string text = "";
var string val = "";
"""";
}
}

function Entry::print_linkbar() {
var string link_seperator = ""; # seperator for links

# initialize array/hashes
var string[] link_keyseq = [""];
var string{} link_url = {"" => ""};
var string{} link_caption = {"" => ""};
var string{} link_image = {"" => ""};

var string print = ""; # var for printing
var Page p = get_page(); # page handle to determine interentry
var bool show_interentry = ($p.view == "entry" or $p.view == "reply"); # if entry/reply view, show interentry
var int keyseq_index = 0; # set index point for new link_keyseq array

if($show_interentry) {
# if show interentry, put previous entry link first
# $link_keyseq[$keyseq_index++] = "nav_prev";

# get previous entry link information
var Link prev = $this->get_link("nav_prev");
$link_url{"nav_prev"} = $prev.url;
$link_caption{"nav_prev"} = $prev.caption;
$link_image{"nav_prev"} = $prev.icon.url;

# get next entry link information
var Link next = $this->get_link("nav_next");
$link_url{"nav_next"} = $next.url;
$link_caption{"nav_next"} = $next.caption;
$link_image{"nav_next"} = $next.icon.url;
}

# gather current linkbar
foreach var string link_key ($.link_keyseq) {
var Link link = $this->get_link($link_key);
$link_url{$link_key} = $link.url;
$link_caption{$link_key} = $link.caption;
$link_image{$link_key} = $link.icon.url;
$link_keyseq[$keyseq_index++] = $link_key; # add this to new link_keyseq array
}
if($show_interentry) {
# if show interentry, put next entry link last
# $link_keyseq[$keyseq_index++] = "nav_next";
}

#################################################################################################################
# by now, the above hashes should look something like: #
# #
# If interentry: #
# Previous Entry: #
# $link_url{"nav_prev"} = http://www.livejournal.com/go.bml?journal=exampleusername&itemid=256&dir=prev #
# $link_caption{"nav_prev"} = Previous Entry #
# $link_image{"nav_prev"} = http://stat.livejournal.com/img/btn_prev.gif #
# #
# Edit Entry: #
# $link_url{"edit_entry"} = http://www.livejournal.com/editjournal.bml?journal=exampleusername&itemid=256 #
# $link_caption{"edit_entry"} = Edit Entry #
# $link_image{"edit_entry"} = http://stat.livejournal.com/img/btn_edit.gif #
# #
# Edit Tags: #
# $link_url{"edit_tags"} = http://www.livejournal.com/edittags.bml?journal=exampleusername&itemid=256 #
# $link_caption{"edit_tags"} = Edit Tags #
# $link_image{"edit_tags"} = http://stat.livejournal.com/img/btn_edittags.gif #
# #
# Add to Memories: #
# $link_url{"mem_add"} = http://www.livejournal.com/tools/memadd.bml?journal=exampleusername&itemid=256 #
# $link_caption{"mem_add"} = Add to Memories #
# $link_image{"mem_add"} = http://stat.livejournal.com/img/btn_memories.gif #
# #
# If interentry: #
# Next Entry: #
# $link_url{"nav_next"} = http://www.livejournal.com/go.bml?journal=exampleusername&itemid=256&dir=next #
# $link_caption{"nav_next"} = Next Entry #
# $link_image{"nav_next"} = http://stat.livejournal.com/img/btn_next.gif #
#################################################################################################################

$link_image{"mem_add"} = $*memories;
$link_image{"edit_entry"} = $*edit;
$link_image{"edit_tags"} = $*edit;
$link_image{"tell_friend"} = $*mail;

# loop thru linkbar and add links to print var
foreach var string link_key ($link_keyseq) {
# if we can do performed action, url will be present
if($link_url{$link_key} != "") {
$print = $print + """""";
# if image url available, use it
if($link_image{$link_key} != "") {
$print = $print + """$link_caption{$link_key}""";
} else {
# else, just use text
$print = $print + "$link_caption{$link_key}";
}
# add a seperator
$print = $print + "
$link_seperator";
}
}

# hack off last seperator
$print = $print->substr(0, $print->length() - $link_seperator->length());

# we're done! let's print it!
print $print;
}

function CommentInfo::print_readlink() {
var Page p = get_page();
var string url = $.read_url;
var string text = get_plural_phrase($.count, "text_read_comments" + ($p.view == "friends" ? "_friends" : ""));
var string img_url = $*comment;
var int img_width = 20;
var int img_height = 21;
if($.count > 0 or $.screened) {
"""""";
if($img_url != "") {
"""$text""";
} else {
print $text;
}
"""
""";
}
}

function CommentInfo::print_postlink() {
var Page p = get_page();
var string url = $.post_url;
var string text = get_plural_phrase(0, "text_post_comment" + ($p.view == "friends" ? "_friends" : ""));
var string img_url = $*leave_comment;
var int img_width = 20;
var int img_height = 21;

"""""";

if($.maxcomments) {
$url = "";
$text = $*text_max_comments;
}

if($url != "") {
"""""";
}

if($img_url != "") {
"""$text""";
} else {
print $text;
}

if($url != "") {
"""
""";
}

"""
""";
}

function CommentInfo::print() {
if (not $.enabled) { return; }
$this->print_postlink();
$this->print_readlink();
}

function print_entry (Page p, Entry e, Color bgcolor, Color fgcolor, bool hide_text) {

var int entry_page_width = $*page_width;
var int entry_half_width = $entry_page_width / 2;
var bool userpic_view = false;
var string subject = $e.subject != "" ? $e.subject : """$*text_nosubject""";
var bool showposter = ($p.view == "friends") or (not $e.poster->equals($e.journal));
var bool showjournal = ($p.view == "friends" and (not $e.poster->equals($e.journal)));
if($*show_entry_userpic or $showposter) {
$userpic_view = true;
}

if($p.view != "friends") {
$bgcolor = $*entry_bg;
$fgcolor = $*entry_font;
}

if($userpic_view) {
var string url = $e.journal->base_url();
var string url2 = $e.poster->base_url();
$entry_page_width = $*page_width - 122;
$entry_half_width = $entry_page_width / 2;

"""







""";
if($showjournal) {
"""$e.poster.username:
""";
}
if($showposter) {
"""
$e.journal.username
""";
}

if($e.userpic.url != "") {
var string alt_text = $*use_shared_pic ? $e.journal.name : $e.poster.name;
"""
$alt_text""";
}

if($showposter) {
"""
$e.journal.name""";
}

"""

""";
}

"""
if($userpic_view == false) {
print """ class="new" """;
}
""">
















""";

if ($e.security) { print "locked"; }

"""

""";

print $e.time->date_format($*my_date);
print " " + $e.time->time_format();

"""



$subject


""";

if (not $hide_text) { "
"; $e->print_text(); "
"; "

"; $e->print_metadata(); "

"; }

"""

""";

$e.comments->print();

$e->print_linkbar();

"""






""";

if($userpic_view) {
"""

""";
}
}

function Page::print_entry (Entry e) {
print_entry($this, $e, null Color, null Color, false);
}

function FriendsPage::print_entry (Entry e) {
var Friend f = $.friends{$e.journal.username};
print_entry($this, $e, $f.bgcolor, $f.fgcolor, false);
}

function YearPage::print_year_links() {
"""





Years:
""";
var int count = 0;
foreach var YearYear y ($.years) {
if($count != 0) {
" | ";
}
$count = $count + 1;
if ($y.displayed) {
" $y.year ";
} else {
""" $y.year """;
}
}
"""


""";
}

function RecentPage::print_body {
foreach var Entry e ($.entries) {
$this->print_entry($e);
}
}

function MonthPage::print_body {
"""






""";
$.redir->print_hiddens();
if (size $.months > 1) {
"""

""";
}
"""



""";
foreach var MonthDay d ($.days) {
if ($d.has_entries) {
"""











""";
$d->print_subjectlist();
"""

""";
}
}
}

function DayPage::print_body() {
if ($.has_entries) {
foreach var Entry e ($.entries) {
$this->print_entry($e);
}
} else {
var Color bgcolor = "#000000";
var Color fgcolor = "#000000";
var int entry_page_width = $*page_width;
var int entry_half_width = $entry_page_width / 2;
var bool userpic_view = false;
var string subject = "No Entries";
var bool showposter = false;
var bool showjournal = false;

if($*show_entry_userpic or $showposter) {
$userpic_view = true;
}

if($userpic_view) {
var string url = $.journal->base_url();
$entry_page_width = $*page_width - 122;
$entry_half_width = $entry_page_width / 2;

"""







""";

if($showposter) {
"""
$.journal.username
""";
}

if($.journal.default_pic.url != "") {
var string alt_text = $.journal.name;
"""
$alt_text""";
}

if($showposter) {
"""
$.journal.name""";
}

"""

""";
}

"""
if($userpic_view == false) {
print """ class="new" """;
}
""">

















""";

print $.date->date_format($*my_date);

"""



$subject


$*text_noentries_day





""";

if($userpic_view) {
"""

""";
} }
}

function TagsPage::print_body() {

var Color bgcolor = "#000000";
var Color fgcolor = "#000000";
var int entry_page_width = $*page_width;
var int entry_half_width = $entry_page_width / 2;
var bool userpic_view = false;
var string subject = "Visible Tags";
var bool showposter = false;
var bool showjournal = false;

if($*show_entry_userpic or $showposter) {
$userpic_view = true;
}

if($userpic_view) {
var string url = $.journal->base_url();
$entry_page_width = $*page_width - 122;
$entry_half_width = $entry_page_width / 2;

"""







""";

if($showposter) {
"""
$.journal.username
""";
}

if($.journal.default_pic.url != "") {
var string alt_text = $.journal.name;
"""
$alt_text""";
}

if($showposter) {
"""
$.journal.name""";
}

"""

""";
}

"""
if($userpic_view == false) {
print """ class="new" """;
}
""">

















""";

print $.time->date_format($*my_date);
print " " + $.time->time_format();

"""



$subject


""";

if (size $this->visible_tag_list()) {
"
";

foreach var TagDetail td ($this->visible_tag_list()) {
"""$td.name
""";
}

"
";
}

"""





""";

if($userpic_view) {
"""

""";
}
}

function print_nav(Page p) {

# figure out the width of each table cell in the navigation based on total page width
var int blank = $*page_width - 500;
if($p.journal.website_url) {
$blank = $blank - 0;
}

"""




""";
}
"""


""";
}

function Page::print() {

var bool show_userpic = false;

var string title = $this->title();
var string k1Hheader_url = ""; # optional header url
var string k1Hheader_alt = ""; # optional header alt text

"""
http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
http://www.w3.org/1999/xhtml">


""";
$this->print_head();
"""
$title



http://wooshck.org/lj_header.jpg" alt="" title="" />

""";

if($k1Hheader_url != "") {
"""
$k1Hheader_alt
""";
}

print_nav($this);

var bool upic = $.journal.default_pic.url != "" and $show_userpic;
var bool linkl = (size($.linklist) > 0) and $*linklist_support;
var bool cal = $*show_mini_calendar;

var bool box = $upic or $linkl or $cal;

if($box) {
"""


""";

if($upic) {
"""

""";
}
if($linkl) {
$this->print_linklist();
}
if($cal) {
"""

""";
}
"""


""";
print_calendar($this);
"""

""";
}
$this->print_body();
print_nav($this);
"""



""";
}

Hopefully I got everything there. Don't beat me up. >.>

subject, links-list, navigation

Previous post Next post
Up