I've tried to change my date format according to the explanation given in a previous entry, but I just can't figure out why it won't work. I've started using layers just today so I thought you could help.
This is my layer code. I would like the date format as %%dd%% %%mm%% %%yy%% and the time to be hidden.
layerinfo "type" = "theme";
layerinfo "name" = "erster versuch";
function print_entry(Page p, Entry e, Color bgcolor, Color fgcolor)
{
"""
""";
$e->print_linkbar();
# Userpic
var string userpic = "";
if ($*show_entry_userpic)
{
if ($p.view == "friends" or $p.view == "entry" or $p.view == "reply")
{
if (defined $e.userpic)
{
$userpic = $userpic + """
if ($e.poster.username != $e.journal.username)
{
$userpic = $userpic + " in $e.journal.name";
}
$userpic = $userpic + "\">";
}
}
elseif ($p.journal_type == "C" and $p.view == "recent")
{
if (defined $e.userpic)
{
$userpic = $userpic + """
""";
}
}
else
{
if (defined $e.userpic)
{
$userpic = $userpic + """
""";
}
}
}
print """
""";
if (($p.view == "recent" and $p.journal_type != "C" ) or $p.view == "day")
{
print """$userpic""";
}
else
{
if ($p.view == "recent" and $p.journal_type == "C" )
{
"""
""";
}
else
{
"""
""";
}
print """$userpic""";
# Poster
if ($p.view == "friends" or $p.view == "entry" or $p.view == "reply")
{
var UserLite linkto;
$linkto = $e.poster;
#print "$e.poster.username";
"""
base_url() + "\">";
"$linkto.username";
}
elseif ($p.journal_type == "C" and $p.view == "recent")
{
var UserLite linkto;
$linkto = $e.poster;
#print "$e.poster.username";
"""
base_url() + "\">";
"$linkto.username";
}
if (($p.view == "friends" or $p.view == "entry" or $p.view == "reply") and $e.poster.username != $e.journal.username)
{
var UserLite linkto;
$linkto = $e.journal;
"""
[
base_url() + "\">";
"$linkto.username]";
}
if ($p.view == "recent" and $p.journal_type == "C")
{
print "
";
}
if ($p.view != "recent" and $p.view != "day")
{
print """
""";
}
}
# Date, time, subject
var string time = "";
$time = $time + """ @ """;
$time = $time + $e.time->time_format("long");
var string date = "";
$date = $date + $e.time->date_format("short");
"""
""";
print $e.time->date_format("%%dd%% %%mm%% %%yy%%");
"""
""";
if ($e.security != "")
{
$e.security_icon->print();
}
if ($p.view != "entry") {
print $e->formatted_subject({"class"=>"subj-link"});" ";
}
else { print "$e.subject "; }
"""
""";
"""
""";
$e->print_text();
print "
";
# Currents
var string currents ="";
$e->print_metadata();
# Comments
"""
""";
}
date format,
entries
if ($p.view != "entry" or $p.view != "reply")
{
$e.comments->print();
}
elseif ($e.comments.enabled)
{
$e.comments->print_postlink();
}
else
{
" ";
}
"""