solved: security icons/tags.

Jan 30, 2009 12:59

just a general flexible squares question. i'm wondering what code one would need to add to their css to show an unlocked image in the subject line of a public entry. thanks in advance.

eta: also, in my currents, my tags image isn't showing while my mood and music images are:


css:
/* -------------------------------
creator: boundary.livejournal.com
style: s2, flexible squares
layout: #02 - think green
>> please credit and don't steal.
------------------------------- */

/* -- main and page classes and ids -- */

body {
background-color: #EEEEEE;
background-image: url();
background-repeat: repeat;
background-attachment: scroll;
margin: 15px;
}

a, a:link, a:visited, a:active, .currents a:hover, div.comments a:hover {
color: #8B8B8B;
text-decoration: none;
}

a:hover {
color: #CCCCCC;
}

body, div, p, td, .currents a, div.comments a, div.comments a:link, div.comments a:visited {
font-family: georgia, serif;
font-size: 7pt;
font-weight: lighter;
color: #A7A39D;
}

img { max-width: 600px; }

code, kbd, pre, tt {
font-family: "Courier New", monospace;
display: block;
}

blockquote, code {
background: #F7F7F3;
margin: 20px 40px 20px 40px;
padding: 10px;
text-align: justify;
}

::-moz-selection {
background: #6CBF18;
color: #FFFFFF;
}

ol {
margin: 5px 10px 5px 10px;
padding: 5px;
list-style-type: decimal;
}

ul {
margin: 5px 10px 5px 10px;
padding: 5px;
list-style-type: square;
}

li {
padding: 0px;
}

#content {
width: 70%;
margin: auto auto;
min-width: 600px;
max-width: 900px;
}

#maincontent {
margin: auto auto;
padding: 0px;
}

/* -- header and footer -- */

#header {
background-color: #FDFDFD;
text-transform: lowercase;
padding: 20px 20px 0 20px;
margin: 15px 0 0 0;
font-weight: none;
font-size: 16px;
}

#footer {
background-color: #FDFDFD;
text-transform: lowercase;
font-size: 11pt;
color: #FFFFFF;
text-align: center;
padding: 10px;
margin: 20px 0 15px 0;
}

div#header a, div#header a:link, div#header a:visited,
div#footer a, div#footer a:link, div#footer a:visited {
color:#8B8B8B;
}

div#header a:hover, div#footer a:hover{
color: #CCCCCC;
}

ul.navheader {
padding: 0px;
margin: 0px;
}

ul.navheader li, ul.navfooter li {
padding: 10px;
list-style: none;
display: inline;
}

/* -- sidebar -- */

#sidebar {
background-color: #FDFDFD;
text-transform: lowercase;
padding: 10px;
margin: 0 0 20px 0;
}

.sbarbody2 {
padding: 0 20px 15px 20px;
text-align: justify;
}

/* -- main content -- */

.subcontent {
background-color: #FDFDFD;
padding: 20px;
margin: 0 0 20px 0;
}

.datesubject {
padding: 3px;
border-bottom: 1px dotted #dddddd;
}

.date, .date a, a.date {
float: right;
text-align: right;
font-weight: normal;
color: #cccccc !important;
font-size: 8pt;
text-transform: lowercase !important;
padding-top: 7px;
display: none;
}

.subject {
text-align: left;
font-weight: normal;
font-size: 9pt;
text-transform: lowercase;
font-family: "Georgia", sans-serif;
color: #8B8B8B;
}

.userpic, .userpicfriends {
background-color: #FDFDFD !important;
position: relative;
float: left;
margin: 0px 5px 0px 0px;
z-index: 15;
font-size: 7pt;
color: #cecece;
}

.userpic img, .userpicfriends img {
background-color: #FDFDFD !important;
width: 35px;
height: 35px;
padding: 0px;
margin: 0px;
}

.userpic font, .userpicfriends font {
font-size: 7pt;
color: #cecece;
}

.entry {
padding: 10px 4px 10px 4px;
text-align: justify;
}

.entry_text {
padding: 10px;
}

.currents {
text-align: left;
padding: 5px;
font-size: 9px;
text-transform: lowercase;
}

.comments {
text-align: right;
text-transform: lowercase;
padding-top: 10px;
color: #FDFDFD !important;
}

/* -- maincontent : entry, reply pages -- */

.skiplinks {
background-color: #FDFDFD;
text-transform: lowercase;
font-size: 11.5pt;
color: #FFFFFF;
text-align: center;
padding: 10px;
margin: 20px 0 0 0;
}

.datesubjectcomment {
background-color: #FDFDFD;
padding: 5px;
margin-top: 20px;
}

.userpiccomment {
position: relative;
background-color: #FDFDFD;
top: -30px;
left: 0px;
padding: 5px;
margin: 10px 10px -20px 10px;
z-index: 15;
float: left;
}

.box {
padding: 20px;
clear: left;
background-color: #FDFDFD;
}

.box center {
padding: 40px;
font-family: georgia;
text-transform: lowercase;
letter-spacing: 0px;
font-size: 17pt;
text-align: center;
background-color: #FDFDFD;
position: relative;
color: #606060;
border-top: 0px dotted #F1F1F1;
font-style: italic;
}

input, textarea {
background-color: #FDFDFD;
color: #8b8b8b;
font-family: "lucinda grande", tahoma;
}

textarea.textbox {
width: 100% !important;
}

.reply{
position: relative;
margin: 20px 30px 10px 30px;
padding: 25px 10px 10px 10px;
text-align: left;
font-family: "lucinda grande", tahoma;
font-size: 7pt;
line-height: 125%;
background-color: #FDFDFD;
color: #8b8b8b;
}

.replytosubject {
font-family: tahoma;
color: #b4b4b4;
font-size: 14px;
text-transform: lowercase;
}

.commentreply {
position: relative;
margin: 10px;
font-size: 10pt;
font-family: "lucinda grande", tahoma;
color: #8b8b8b;
}

.commentbox {
padding: 10px;
margin: 10px;
background: #F7F7F3;
text-align: justify;
}

.datesubjectcomment a:link, .datesubjectcomment a:visited {
color: #b4b4b4;
}

.datesubjectcomment a:hover {
color: #a9a9a9;
}

.commentboxpartial {
border-color: transparent;
border-width: 1px;
border-style: solid;
padding: 10px;
margin: 10px;
background-color: #606060;
}

.commentinfo {
background-color: #FDFDFD;
margin-top: 10px;
width: 100%;
}

/* -- maincontent : year, archive pages -- */

ul.year {
background-color: #FDFDFD;
text-align: center;
font-size: 18pt;
margin: 0 0 20px 0;
padding: 20px;
}

ul.year li {
display: inline;
}

table.yeartable {
margin-left: auto;
margin-right: auto;
width: 100%;
background-color: #FDFDFD;
text-align: center;
}

td.yearmonth {
border: 0px;
padding: 3px;
font-size: 16pt;
color: #606060 !important;
text-transform: lowercase;
margin: 10px;
}

td.yearmonth a {
font-size: 8.5pt !important;
font-style: italic;
color: #808080 !important;
text-transform: lowercase;
margin: 10px;
}

table.yeartable td.yearday {
border: 0px;
padding: 3px;
font-size: 12pt;
font-style: italic;
color: #606060 !important;
text-transform: lowercase;
text-align: center;
margin: 10px;
}

table.yeartable td.yeardate {
border: 0px;
background-color: #F7F7F3;
padding: 3px;
font-size: 10pt;
font-style: italic;
color: #606060 !important;
text-transform: lowercase;
text-align: center;
margin: 10px;
}

/* -- tags page -- */

h2 {
background-color: #FDFDFD;
padding: 20px 0 0 20px;
margin: 0px;
font-size: 14pt;
font-weight: lighter;
text-transform: lowercase;
color: #8B8B8B;
}

.ljtaglist {
background-color: #FDFDFD;
padding: 20px;
margin: 0 0 20px 0;
}

ul.ljtaglist {
}

ul.ljtaglist li {
border-bottom: 1px dotted #cecece;
margin-left: 15px;
padding: 5px;
}

/* -- main content : image overrides -- */

img[src="http://p-stat.livejournal.com/img/icon_protected.gif"]{
width: 0;
height: 0;
padding: 16px 16px 0px 0px;
background: url(http://i39.tinypic.com/28c21q9.jpg);
}

img[src="http://p-stat.livejournal.com/img/icon_private.gif"]{
width: 0;
height: 0;
padding: 16px 16px 0px 0px;
background: url(http://i39.tinypic.com/28c21q9.jpg);
}

img[src="http://p-stat.livejournal.com/img/icon_groups.gif"]{
width: 0;
height: 0;
padding: 16px 16px 0px 0px;
background: url(http://i33.tinypic.com/51c1m8.jpg);
}

.currentlocation {
padding-left: 20px;
height: 18px;
background: url('http://i43.tinypic.com/rbb8yv.gif') 1px 1px no-repeat;
}

.currentmood {
padding-left: 20px;
height: 18px;
background: url('http://i44.tinypic.com/14cv7t3.jpg') 1px 1px no-repeat;
}

.currentmusic {
padding-left: 20px;
height: 18px;
background: url('http://i43.tinypic.com/ohtoj6.jpg') 1px 1px no-repeat;
}

.currentgroups {
padding-left: 20px;
height: 18px;
background: url('http://i43.tinypic.com/x9kir.jpg') 1px 1px no-repeat;
}

.ljuser img {
width: 0;
height: 0;
background-repeat: no-repeat;
background-color:transparent;
/* so that IE users will still see an image */
background-image: url();
padding: 2px 2px 0px 2px;
}

span.ljuser img[src="http://p-stat.livejournal.com/img/userinfo.gif"] {
background-color:transparent;
background-image: url();
padding: 2px 2px 0 2px;
}

span.ljuser img[src="http://p-stat.livejournal.com/img/community.gif"] {
background-color:transparent;
background-image: url();
padding: 2px 2px 0 2px;
}

span.ljuser img[src="http://p-stat.livejournal.com/img/syndicated.gif"] {
background-color:transparent;
background-image: url();
padding: 2px 2px 0 2px;
}

span.ljuser img[src="http://p-stat.livejournal.com/img/newsinfo.gif"] {
background-color:transparent;
background-image: url();
padding: 2px 2px 0 2px;
}

span.ljuser img[src="http://p-stat.livejournal.com/img/openid-profile.gif"] {
background-color:transparent;
background-image: url();
padding: 2px 2px 0 2px;
}

span.ljuser img[src="http://p-stat.livejournal.com/img/sponcomm.gif"] {
background-color:transparent;
background-image: url();
padding: 2px 2px 0 2px;
}

div.commentbox img[src="http://p-stat.livejournal.com/img/btn_del.gif"] {
background-color:transparent;
background-image: url();
width: 0px;
height: 0px;
padding: 0px 0px 2px 2px;
background-repeat: no-repeat;
background-position: left middle;
border-width: 0px;
}

div.commentbox img[src="http://p-stat.livejournal.com/img/btn_scr.gif"] {
background-color:transparent;
background-image: url();
width: 0px;
height: 0px;
padding: 0px 0px 16px 16px;
background-repeat: no-repeat;
background-position: left middle;
border-width: 0px;
}

div.commentbox img[src="http://p-stat.livejournal.com/img/btn_unscr.gif"] {
background-color:transparent;
background-image: url();
width: 0px;
height: 0px;
padding: 0px 0px 16px 16px;
background-repeat: no-repeat;
background-position: left middle;
border-width: 0px;
}

div.commentbox img[src="http://p-stat.livejournal.com/img/btn_freeze.gif"] {
background-color:transparent;
background-image: url();
width: 0px;
height: 0px;
padding: 0px 0px 16px 16px;
background-repeat: no-repeat;
background-position: left middle;
border-width: 0px;
}

div.commentbox img[src="http://p-stat.livejournal.com/img/btn_unfreeze.gif"] {
background-color:transparent;
background-image: url();
width: 0px;
height: 0px;
padding: 0px 0px 16px 16px;
background-repeat: no-repeat;
background-position: left middle;
border-width: 0px;
}

div.commentbox img[src="http://p-stat.livejournal.com/img/btn_track.gif"] {
background-color:transparent;
background-image: url();
width: 0px;
height: 0px;
padding: 0px 0px 16px 16px;
background-repeat: no-repeat;
background-position: left middle;
border-width: 0px;
}

div.commentbox img[src="http://p-stat.livejournal.com/img/btn_untrack.gif"] {
background-color:transparent;
background-image: url();
width: 0px;
height: 0px;
padding: 0px 0px 16px 16px;
background-repeat: no-repeat;
background-position: left middle;
border-width: 0px;
}

/* -- misc classes and functions -- */

span.ljuser a b {
padding: 2px;
font-weight: lighter;
}

/* -- hiding elements -- */

.title, .subtitle, .clear, .clearfoot, .separator, div.ContextualPopup,
.currentmood img, .defaultuserpic, .sbartitle, .sbarlist,
.sbarcalendar, .sbarcontent, .currents strong, li.viewing {
display: none !important;
}

theme layer:
layerinfo "type" = "theme";
layerinfo "name" = "metadata";
set tags_aware = true;

function Entry::print_metadata()
{
var string tags_sep = ", "; # text for tags separator, ", " for "tag, tag, tag"

var string show_tags_link = "none"; # set to "edit" if you want the tags label to act as an 'edit tags' link
# set to "page" if you want the tags label to link to the poster's journal's tag page
# set to "manage" to link to the Tags Management page
# set to "none" to delinkify the tags label completely

var bool show_loc_link = false; # set to false to delinkify location (no Google Maps link)
# set to true to display the Google Map link

var bool show_groups_link = false; # set to false to delinkify the group (no custom friends group link)
# set to true to display the friends group link

var string alignment = "left"; # set the side of the mood icon (left or right of the currents)

# here, set mood, music, location and tags into the order you want them to be displayed in
# any metadata you want to hide journalwide, delete it from this list
var string[] metaorder = ["mood", "music", "tags", "location"];

# optional:
# here, put in the URLs to the pics you want to use instead of the currents' labels
# if you leave it blank, the current's text label will be used instead
var string{} metapics = { "mood" => "http://i44.tinypic.com/14cv7t3.jpg",
"music" => "http://i43.tinypic.com/ohtoj6.jpg",
"location" => "http://i43.tinypic.com/rbb8yv.gif",
"tags" => "http://i43.tinypic.com/x9kir.jpg" };

var string currents = """
"""; # here all metadata will be added to print it out in the end
var string currents_close = """
"""; # html for closing of currents container

var Link edit_tags = $this->get_link("edit_tags"); # helper var to see if remote user can edit tags

if ((size $.metadata > 0) or ((size $.tags > 0) and ($*tags_aware))) {

# display mood and moodicon?
var bool display_mood = false;
foreach var string moodtest ($metaorder) {
if ($moodtest == "mood") { $display_mood = true; }
}

# table and mood icon
if (defined $.mood_icon and $display_mood == true) {
$currents = ($alignment == "left") ?
$currents + """
$.metadata{""" :
$currents + """
""";
}

# step through metadata in the order the user wants
foreach var string k ($metaorder) {

var string text; # the actual value of the metadata
var string label; # the label of the metadata as set in the wizard or set-statements

# handling tags metadata
if (($k == "tags") and (size $.tags > 0) and $*tags_aware) {

# label as image or text
$label = clean_url($metapics{$k}) != "" ? """$*text_tags""" : $*text_tags;

# optional linkage around tags label
if (($show_tags_link == "edit") and ($edit_tags.url != "")) { # Edit Tags Page link
$label = """""" + $label + """""";
}
elseif ($show_tags_link == "page") { # Visible Tags Page link
$label = """base_url() + """/tag/ ">""" + $label + """""";
}
elseif ($show_tags_link == "manage" and viewer_is_owner()) { # Tags Management Page link
$label = """tag_manage_url() + """ ">""" + $label + """""";
}

# build tag list
var bool addsep = false;
foreach var Tag t ($.tags) {
if ($addsep) {
$text = $text + $tags_sep + """""";
}
else {
$text = $text + """""";
$addsep = true;
}
}
}

# handling all other metadata
elseif (($k != "tags") and ($.metadata{$k} != "")) {

# metadata value
$text = $.metadata{$k};

# label as image or text
$label = clean_url($metapics{$k}) != "" ? "\""" : lang_metadata_title($k);

# strip location link
if (not ($show_loc_link) and ($k == "location") and ($.metadata{"location"} != "")) {
$text = striphtml($text);
}

# strip groups link
if (not ($show_groups_link) and ($k == "groups") and ($.metadata{"groups"} != "")) {
$text = striphtml($text);
}
}

# skipping empty quotes (= hidden metadata)
else {
continue;
}

# assemble the individual currents
$currents = $currents + """
$label $text
""";

}

# table and mood icon
if ($display_mood == true and defined $.mood_icon) {
$currents = ($alignment == "left") ?
$currents + """
""" :
$currents + """
$.metadata{
""";
}

# close currents container
$currents = $currents + $currents_close;

# print currents
println "$currents";
}
}

metadata, solved, entry security icons

Previous post Next post
Up