I wanted to change my date format, so I took the code from this entry
http://www.livejournal.com/community/component_help/337925.html
Only I had to put the rest of the code in for the entries or they wouldnt show up.
Now they are fine but My mood theme icons dont show up.
Is there anything Im doing wrong?
######################################## ######################################## #######################################
### Override the printing of entries. This affects the Recent/Day pages, Friends pages, and Entry pages.
function print_entry(Page p, Entry e, Color bgcolor, Color fgcolor, bool hide_text) {
# Print the anchor to be used in the page summary.
if ($p.view=="friends") {
"""""";
} else { # for recent, day, entry pages.
"""""";
}
var string noscroll ;
if ($p.view == "recent" or $p.view == "friends") {
$noscroll = "class=\"fixed\"" ;
}
var string content_top = """<td class="" width="100%" valign="top">
[Error: Irreparable invalid markup ('<table [...] $noscroll>') in entry. Owner must fix manually. Raw contents below.]
Hey.Ive been customising my jounral pretty well. I dont know how to code so its just a game of see what works. So far so good but I cant now get my pictures for my mood theme to show up.
I wanted to change my date format, so I took the code from this entry
http://www.livejournal.com/community/component_help/337925.html
Only I had to put the rest of the code in for the entries or they wouldnt show up.
Now they are fine but My mood theme icons dont show up.
Is there anything Im doing wrong?
<lj-cut text="Full code I put in my theme">
<code>
#######################################################################################################################
### Override the printing of entries. This affects the Recent/Day pages, Friends pages, and Entry pages.
function print_entry(Page p, Entry e, Color bgcolor, Color fgcolor, bool hide_text) {
# Print the anchor to be used in the page summary.
if ($p.view=="friends") {
"""<a name="$e.journal.username$e.itemid"></a>""";
} else { # for recent, day, entry pages.
"""<a name="item$e.itemid"></a>""";
}
var string noscroll ;
if ($p.view == "recent" or $p.view == "friends") {
$noscroll = "class=\"fixed\"" ;
}
var string content_top = """<td class="entryHolderBg" width="100%" valign="top">
<table cellspacing="0" cellpadding="0" border="0" width="100%">
<tr>
<td width="100%">
<table cellspacing="0" cellpadding="0" border="0" width="100%" $noscroll>
<tr>
<td width="1" class="medLine"><img src="http://www.livejournal.com/palimg/component/clear.gif" width="1" height="1" alt="" border="0" /></td>
<td class="medLine"><img src="http://www.livejournal.com/palimg/component/clear.gif" width="1" height="1" alt="" border="0" /></td>
<td width="1" class="medLine"><img src="http://www.livejournal.com/palimg/component/clear.gif" width="1" height="1" alt="" border="0" /></td>
</tr>
<tr>
<td width="1" class="medLine"><img src="http://www.livejournal.com/palimg/component/clear.gif" width="1" height="1" alt="" border="0" /></td>
<td class="entry">
""";
# Print the header for the entry. For specifications of available formats or how to construct
# your own formats, you can see: http://www.livejournal.com/doc/s2/siteapi.core1.html#siteapi.core1.dateformats
print_entry_header(
"<div class=date1b>"+$e.time->date_format("%%day%%")+"</div>
<div class=date1>"+$e.time->date_format("%%day%%")+"</div>
<div class=date2b>"+$e.time->date_format("long")+"</div>
<div class=date2>"+$e.time->date_format("long")+"</div>
<div class=date3b>"+$e.time->time_format()+"</div>
<div class=date3>"+$e.time->time_format()+"</div>"
);
print_system_box_top();
"""<table cellspacing="0" cellpadding="0" border="0" width="100%"><tr>""";
# Check to see if we need to display a usericon and/or journal names, and if so, then print them
# Cases - 1. We are viewing a friends page, so we need to display icons if they exist and journal/poster names
# 2. We are viewing a recent/day/entry page, so we display only the icon if it exists and the user has set recent userpics on.
# The code in red is the logic to decide whether or not to show the userpics. You can modify it as you see fit.
if ($p.view=="friends" or ($*show_entry_userpic and defined $e.userpic) or $e.journal.journal_type=="C") {
# Start the table that will hold the icon and/or names
"""
<td valign="top" style="padding-right: 8px;">
<table cellspacing="0" cellpadding="0" border="0" align="center" >
<tr>
<td><img src="http://www.livejournal.com/palimg/component/clear.gif" width="1" height="7" alt="" border="0" /></td>
</tr>
""";
# Display the icon if it exists
if (defined $e.userpic) { """
<tr>
<td><img src="http://www.livejournal.com/palimg/component/clear.gif" width="1" height="7" alt="" border="0" /></td>
""";
# If we are on the friends view, then we want to print the extra border around the image that have the colors
# which are custom defined. If you don't like the colors or the border on the friends view, then you can just
# remove the blue segments. By default the recent/day/entry pages have a border around the usericons. If a user
# has a non-rectangular image, this may look strange, so you can replace the 1 with a 0 to remove the border.
#
""" <td align="center" class="userpic"><img border="0" src="$e.userpic.url" width="$e.userpic.width" height="$e.userpic.height" alt="" /></td> """;
"""
</tr>
"""; }
# Display the journal and possibly poster name if we are viewing the friends page or any page on a community
# This code will print the journal the entry was made on, and if the poster is different, will print the poster under it.
# I made the names centered under the image, but if you want to keep them left aligned as in the original, then
# remove the blue segments
if ($p.view=="friends" or $e.journal.journal_type=="C") { """
<tr>
<td><img src="http://www.livejournal.com/palimg/component/clear.gif" width="1" height="2" alt="" border="0" /></td>
<td class="ljuser">$e.journal""";
if ($e.journal.username!=$e.poster.username) {"""
<div class="ljuser">$e.poster</div>""";
} """
</td>
</tr>""";
}
"""
</table>
</td>
"""; }
# Start the main entry text area
print $content_top;
# If the subject is not empty, then print it followed by the line to seperate it from the entry text
# You can modify the lines in red if you want to adjust the way your subject prints, but the other lines must remain as is.
if ($e.subject!="") { """
<div class="entryHeader">$e.subject</div>
<div class="entryDash"><img src="http://www.livejournal.com/palimg/component/clear.gif" width="1" height="1" alt="" border="0" /></div>
</td>
<td width="1" class="medLine"><img src="http://stat.livejournal.com/palimg/component/clear.gif" width="1" height="1" alt="" border="0" /></td>
</tr>
<tr>
<td width="1" class="medLine"><img src="http://stat.livejournal.com/palimg/component/clear.gif" width="1" height="1" alt="" border="0" /></td>
<td class="entry">
"""; }
"""<div class="scrollentry">""";
# Print the entry text.
"""$e.text""";
# Print Mood and/or Music Fields:
# If we have a mood to print
if ($e.metadata{"mood"}!="") {
# first we need a spacer after the entry text
"""<br/><br/>""";
"""<div class="entryDash"><img src="$*PALIMGROOT/component/clear.gif" width="1" height="1" alt="" border="0" /></div>""";
# and then we print the mood label, followed by a mood icon if one exists, followed by the mood text.
# If you want the mood icon to be after the mood text, then you need to change the order of the two lines in red.
"""<div class=metaText>$*text_meta_mood : $e.metadata{"mood"}</.div>""";
"""<br/>""";
# if ($e.metadata{"music"}=="") { """<br/>"""; }
}
# If we have music to print
if ($e.metadata{"music"}!="") {
# If we didn't print a spacer because the mood was empty, then print one
if ($e.metadata{"mood"}=="") { """<div class="entryDash"><img src="$*PALIMGROOT/component/clear.gif" width="1" height="1" alt="" border="0" /></div>"""; }
# then print the actual music label and the music
"""<div class=metaText>$*text_meta_music : $e.metadata{"music"}</.div>""";
}
# Close off the entry text area
print_content_bottom();
# This is where the fun stuff is!
# Now we begin the area underneath the entry that holds the comments, link, and entry related buttons.
"""
<table width="100%">
</tr>
<td width="50%" align="left" valign="center">
<div class="entryComments">
""";
# First we print the comment links if the entry allows comments
if ($e.comments.enabled) {
$e.comments->print();
}
"""
</div>
</td>
<td align="center" valign="center">""";
"""
</td>
<td width="50%" align="right" valign="center">""";
# Then the entry related buttons
"""<div class="entryComments">
""";
# The easiest way to do this, which will work for all account types, is as follows, and will display actual buttons.
# If you'd like text instead of buttons, then remove the following line in blue, decomment the lines in pink,
# and edit as you see fit. Note that using the print_linkbar function will also add next and previous buttons to the
# Entry page (with comments), and I've reflected that in the pink lines below.
if($e.security != ""){ print $e.security_icon; }
$e->print_linkbar();
"""
</div>
</td>
</tr>
</table>
""";
# End the entry component and put a spacer after it so that entry components are seperated.
"""</tr></td></table>""";
print_system_box_bottom();
""" <div><img src="http://www.livejournal.com/palimg/component/clear.gif" width="3" height="3" alt="" border="0"></div> """;
} # end of Function print_entry
#######################################################################################################################
</code>
</lj-cut>
I hope you can help. I really liked my mood theme :-/