Current URL Testing?
This is an open discussion with 3 replies, filed under Troubleshooting.
Search
do you have a param set up in your url string when you filter down to a single entry? i would imagine you would to achieve the filtering. using the var entry
to filter to a single post, you can try this to show/hide content based on page:
<xsl:choose> <xsl:when test="not($entry)"> <!-- don't show the content --> </xsl:when> <xsl:otherwise> <!-- show the content --> </xsl:otherwise> </xsl:choose>
I think that will work, but not 100% sure if the XSLT
processor will throw a fit if you don't have $entry
defined in your page, even though you're telling it when the $entry
is not defined.
that's just one approach, but i'm sure there are other options.
Works! Thanks!
not a problem =)
Create an account or sign in to comment.
I've got a data source set up that can filter by the title of an entry. Now when it's showing all of the entries I want to show one set of content for each entry but when it's filtering down to a single entry I want it to show some more content.
How would I achieve this? I seem to remember an if statement that allows you to test the URL but I can't remember it or find an example.