Tags

, ,

From Dave’s blog, I changed a little bit. First, I upload all the anythingslider into a slider library that can be easily managed.

image
Below is the XSLT I used.
<Xsl>
<xsl:stylesheet xmlns:x="http://www.w3.org/2001/XMLSchema&quot; xmlns:d="http://schemas.microsoft.com/sharepoint/dsp&quot; version="1.0" exclude-result-prefixes="xsl msxsl ddwrt" xmlns:ddwrt="http://schemas.microsoft.com/WebParts/v2/DataView/runtime&quot; xmlns:asp="http://schemas.microsoft.com/ASPNET/20&quot; xmlns:__designer="http://schemas.microsoft.com/WebParts/v2/DataView/designer&quot; xmlns:xsl="http://www.w3.org/1999/XSL/Transform&quot; xmlns:msxsl="urn:schemas-microsoft-com:xslt" xmlns:SharePoint="Microsoft.SharePoint.WebControls" xmlns:ddwrt2="urn:frontpage:internal">
<xsl:output method="html" indent="no"/>
<xsl:decimal-format NaN=""/>
<xsl:param name="dvt_apos">&apos;</xsl:param>
<xsl:variable name="dvt_1_automode">0</xsl:variable>
<xsl:template match="/" xmlns:x="http://www.w3.org/2001/XMLSchema&quot; xmlns:d="http://schemas.microsoft.com/sharepoint/dsp&quot; xmlns:asp="http://schemas.microsoft.com/ASPNET/20&quot; xmlns:__designer="http://schemas.microsoft.com/WebParts/v2/DataView/designer&quot; xmlns:SharePoint="Microsoft.SharePoint.WebControls">
<xsl:call-template name="dvt_1"/>
</xsl:template>
<xsl:template name="dvt_1">
<xsl:variable name="Rows" select="/dsQueryResponse/Rows/Row" />
<link rel="stylesheet" href="/slider/page.css" type="text/css" media="screen" />
<link rel="stylesheet" href="/slider/anythingslider.css" type="text/css" media="screen" />
<script type="text/javascript" src="/slider/jquery.easing.1.2.js"></script> <script src="/slider/jquery.anythingslider.js" type="text/javascript" charset="utf-8"></script> <script type="text/javascript">
function formatText(index, panel) {
return index + &quot;&quot;;
}
$(function () {
$(&apos;.anythingSlider&apos;).anythingSlider({
easing: &quot;easeInOutExpo&quot;,
autoPlay: true,
delay: 3000,
startStopped: false,
animationTime: 600,
hashTags: true,
buildNavigation: true,
pauseOnHover: true,
startText: &quot;Go&quot;,
stopText: &quot;Stop&quot;,
navigationFormatter: formatText
});
$(&quot;#slide-jump&quot;).click(function(){
$(&apos;.anythingSlider&apos;).anythingSlider(6);
});
});
</script>
<div class="anythingSlider">
<div class="wrapper">
<ul>
<xsl:call-template name="dvt_1.body">
<xsl:with-param name="Rows" select="$Rows" />
</xsl:call-template>
</ul>
</div>
</div>
</xsl:template>
<xsl:template name="dvt_1.body">
<xsl:param name="Rows" />
<xsl:for-each select="$Rows">
<xsl:call-template name="dvt_1.rowview" />
</xsl:for-each>
</xsl:template>
<xsl:template name="dvt_1.rowview">
<li>
<div class="textSlide">
<!– display the item title and a link to the item –>
<h3><a href="/{@FileDirRef}/DispForm.aspx?ID={@ID}" title="{@Title}"><xsl:value-of select="@Title" /></a></h3>
<!– display the body of the item –>
<xsl:value-of select="@Body" disable-output-escaping="yes" />
</div>
</li></xsl:template>
</xsl:stylesheet>
</Xsl>

To have data view across multiple lists (same fields). Just click Configure Data Source, add lists you want.

In the Data Source Details task pane, in the Details Panel, select the fields you want and Click Insert Selected Fields as, and then click Multiple Item View to insert the selected data into the Data View.

You can see more details on this tutorial.

Advertisements