Products

Solutions

Resources

Partners

Community

Blog

About

QA

Ideas Test

New Community Website

Ordinarily, you'd be at the right spot, but we've recently launched a brand new community website... For the community, by the community.

Yay... Take Me to the Community!

Welcome to the DNN Community Forums, your preferred source of online community support for all things related to DNN.
In order to participate you must be a registered DNNizen

HomeHomeDNN Open Source...DNN Open Source...Module ForumsModule ForumsForm and ListForm and ListXSL created by filterXSL created by filter
Previous
 
Next
New Post
7/16/2010 12:31 PM
 
I'm working on an XSL sheet and can't get it to work how I want.  The generated XSL has a for-each loop that prints the field label and field value for every field in the table.  The generated code also has an if statement that checks to make sure the field isn't an image, title and html column before it prints it.

I would like to also add to the if statement logic to not skip the audit fields:

  • Created by
  • Created at
  • Changed by
  • Changed at
I've tried all the combinations I can think of.  Here is the syntax for skipping image type fields.

($NameOfValueColumn!=$imgColumn or not($imgColumn))
What is the XSL syntax for skipping the created by fields?  Any suggestions?

fyi - The created by fields only show up if your logged into to edit the module.  I just want the display to look the same no matter if your logged in or not.

Thanks for your help.
Scott
 
New Post
7/19/2010 8:48 AM
 

Ok.  I came up with my solution.  Instead of attacking the issue with column type I went at it with column title.  See bold below.  

<xsl:for-each select="//udt:Fields">
<xsl:variable name="ColumnTitle" select="udt:FieldTitle"/>
<xsl:variable name="NameOfValueColumn" select="udt:ValueColumn"/>
<xsl:variable name="CurrentValue" select="//udt:Data[udt:UserDefinedRowId=$id]/*[name()=$NameOfValueColumn]"/>
<xsl:if test ="$CurrentValue and $CurrentValue!='' and ($NameOfValueColumn!=$imgColumn or not($imgColumn)) and ($NameOfValueColumn!=$titleColumn or not($titleColumn)) and ($NameOfValueColumn!=$htmlColumn or not($htmlColumn))and (substring($ColumnTitle,1,7)!='Created by') and (substring($ColumnTitle,1,7)!='Created at') and (udt:Visible='true' or udt:Visible='True')" >
<tr class="Normal">
<td>
<xsl:value-of select ="udt:FieldTitle"/>:&#160;&#160;&#160;
</td>
<td>
<xsl:value-of select="$CurrentValue" disable-output-escaping="yes"/>
</td>
</tr>
</xsl:if>
</xsl:for-each>

 
Previous
 
Next
HomeHomeDNN Open Source...DNN Open Source...Module ForumsModule ForumsForm and ListForm and ListXSL created by filterXSL created by filter


These Forums are dedicated to discussion of DNN Platform and Evoq Solutions.

For the benefit of the community and to protect the integrity of the ecosystem, please observe the following posting guidelines:

  1. No Advertising. This includes promotion of commercial and non-commercial products or services which are not directly related to DNN.
  2. No vendor trolling / poaching. If someone posts about a vendor issue, allow the vendor or other customers to respond. Any post that looks like trolling / poaching will be removed.
  3. Discussion or promotion of DNN Platform product releases under a different brand name are strictly prohibited.
  4. No Flaming or Trolling.
  5. No Profanity, Racism, or Prejudice.
  6. Site Moderators have the final word on approving / removing a thread or post or comment.
  7. English language posting only, please.
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out