IfNew Element
The IfNew element returns TRUE if the item is considered new (usually meaning it was created before midnight the day before). This element renders the item's body if it was created today (the number of days is a registry setting, for which the default value is 1).
Syntax
<IfNew
Name = "Text">
</IfNew>
Attributes
Name | Description |
---|---|
Name | Optional Text. Specifies the name of a field. The default value is Created. |
Related Elements
Parent Elements | Child Elements |
---|---|
DisplayPattern, ViewBody | HTML, ImagesPath |
Example
The following example displays a particular logo if the display pattern of the field is new.
<DisplayPattern>
<IfNew>
<HTML>
<![CDATA[ <IMG SRC=" ]]>
</HTML>
<ImagesPath />
<HTML>
<![CDATA[ newlink.gif" alt=" ]]>
</HTML>
<HTML>
New
</HTML>
<HTML>
<![CDATA["> ]]>
</HTML>
</IfNew>
</DisplayPattern>