S2 Code - Changing the order of your current tags with flexible squares

Apr 05, 2006 09:37


This code will allow you to change the order of your meta tags and remove the google maps link from the location.
function Entry::print_metadata() { if (size $.metadata) { var string my_location = ""; var string my_mood = ""; var string my_music = ""; var string currents; foreach var string k ($.metadata) { var string text = $k; var string val = $.metadata{$k}; if ($k == "mood" and defined $.mood_icon) { var Image i = $.mood_icon; $val = " $val"; } elseif ($k == "location") { $val = striphtml($val); } var string start_current = """
"""; var string end_current = " $val
"; if ($k == "location") { $my_location = $my_location + $start_current + "New name for current location" + $end_current; } elseif ($k == "mood") { $my_mood = $my_mood + $start_current + $*text_meta_mood + $end_current; } elseif ($k == "music") { $my_music = $my_music + $start_current + $*text_meta_music + $end_current; } } print """
"""; print $my_location; print $my_mood; print $my_music; print "
"; } }

tech, lj

Previous post Next post
Up