Help - Search - Members - Calendar
Full Version: How Do I Add A Picture Tag To The Post Meta?
Movable Type Community Forum > Using Movable Type > Additional Features
flyworld3
I'd like to add a "Featured" symbol near the post meta...how would I go about doing that?
OtherNiceMan
Against all or just some?
flyworld3
QUOTE (OtherNiceMan @ Dec 12 2008, 01:21 PM) *
Against all or just some?


Some, depending on what entry it is.
OtherNiceMan
give your featured articles the tag @featured and add the following code to the Entry Metadata where you want the graphic to appear (replace image name etc with your own).

CODE
<mt:EntryIfTagged tag="@featured">
<img src="featured.png" height="16" width="16" alt="featured">
</mt:EntryIfTagged>
flyworld3
QUOTE (OtherNiceMan @ Dec 13 2008, 03:24 AM) *
give your featured articles the tag @featured and add the following code to the Entry Metadata where you want the graphic to appear (replace image name etc with your own).

CODE
<mt:EntryIfTagged tag="@featured">
<img src="featured.png" height="16" width="16" alt="featured">
</mt:EntryIfTagged>


Can I a href it and add a link to the thing as well?
OtherNiceMan
yes, you can add anything you like between the EntryIfTagged tags and it will only be added if the Tag matches. I use it to insert additional JavaScript and widgets based on the tags users give the entries.
flyworld3
QUOTE (OtherNiceMan @ Dec 14 2008, 01:58 AM) *
yes, you can add anything you like between the EntryIfTagged tags and it will only be added if the Tag matches. I use it to insert additional JavaScript and widgets based on the tags users give the entries.


I can't embed a link into the .png image... exactly what is the code needed to add a link inside it?
OtherNiceMan
Same code as any other image link

CODE
<mt:EntryIfTagged tag="@featured">
<a href="http://www.domin.com/link"><img src="featured.png" height="16" width="16" alt="featured"></a>
</mt:EntryIfTagged>
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2009 Invision Power Services, Inc.