Rotator - Live XML

Data streamed live from http://feeds.feedburner.com/Telerik
  • 09:27
    Wed, Jan 21, 2015
    HubSpot Blog Cites Telerik.com as Example of Brilliant Website Design
  • 06:45
    Wed, Jan 21, 2015
    Telerik: A Progress Company Takes Home Three Awards at the “Forbes Business Awards 2014” in Bulgaria
  • 02:34
    Wed, Jan 21, 2015
    Top 10 Conferences for iOS Developers to Attend in 2015
  • 01:00
    Wed, Jan 21, 2015
    Using Google Spreadsheets as Data Source in Your Android App
  • 01:00
    Tue, Jan 20, 2015
    How to Use Expandable List Items in Windows Store Apps
  • 03:45
    Mon, Jan 19, 2015
    Using Google Spreadsheets as a Data Source in Your Windows Store App
  • 09:33
    Fri, Jan 16, 2015
    Announcing the Beta Release of the Telerik Mobile Cloud Testing Platform
  • 06:15
    Fri, Jan 16, 2015
    Weekly Dose of Telerik Support Resources 01/12/2015
  • 08:48
    Wed, Jan 14, 2015
    Answering Telerik Kendo UI Suite Q3 Webinar Questions
  • 03:56
    Tue, Jan 13, 2015
    Come See the New Test Studio Release and Learn What’s Coming up in 2015
    
Isolate this demo as a stand-alone application

RadRotator has support for live XML feeds.

You can make use of this feature very easily - all you need to do is use a XmlDataSource source and set it to the URL of the live feed. Finally, you might need to set the XmlDataSource's XPath span.__group0.This way you could easily deliver public news to your site using your own formatting and styling.
<%@ Page AutoEventWireup="true" Inherits="Telerik.Web.Examples.Rotator.Functionality.LiveXML.DefaultCS"CodeFile="DefaultCS.aspx.cs" Language="C#"  %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns='http://www.w3.org/1999/xhtml'>
<head runat="server">
    <title>Telerik ASP.NET Example</title>
    <link href="styles.css" rel="stylesheet" type="text/css" />
</head>
<body>
    <form id="form1" runat="server">
    <telerik:RadScriptManager runat="server" ID="RadScriptManager1" />
    <telerik:RadSkinManager ID="RadSkinManager1" runat="server" ShowChooser="true" />
    <div class="demo-container no-bg">
        <div class="backElement">
            <div class="titleText">
                Data streamed live from <a href="http://feeds.feedburner.com/Telerik">http://feeds.feedburner.com/Telerik</a><br />
            </div>
            <telerik:RadRotator ID="RadRotator1" Skin="Silk" RotatorType="AutomaticAdvance" ScrollDirection="Up"
                ScrollDuration="2000" runat="server" Width="493"
                ItemWidth="493" Height="192" ItemHeight="64" FrameDuration="1" InitialItemIndex="-1"
                CssClass="rotator">
                <ItemTemplate>
                    <div class="itemTemplate" style="background-image: url('images/<%# this.GetDayOfWeek(XPath("pubDate").ToString()) %>.png');">
                        <div class="dateTime">
                            <div class="time">
                                <%# (this.GetTimeOnly(XPath("pubDate").ToString())) %>
                            </div>
                            <div class="date">
                                <%# (this.GetDateOnly(XPath("pubDate").ToString()))%>
                            </div>
                        </div>
                        <div class="title">
                            <span>
                                <%# System.Web.HttpUtility.HtmlEncode(XPath("title").ToString())%>
                            </span>
                        </div>
                    </div>
                </ItemTemplate>
            </telerik:RadRotator>
            <asp:Label ID="lblMessage" Visible="false" CssClass="message" runat="server" />
        </div>
    </div>
    </form>
</body>
</html>

Find Assistance

Help Us Improve

Was this example helpful?