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

HomeHomeOur CommunityOur CommunityGeneral Discuss...General Discuss...Can I dispaly this info with DNN?Can I dispaly this info with DNN?
Previous
 
Next
New Post
2/5/2009 10:32 AM
 

Is there something "DNN" specific which can parse this info?
I have an intranet URL (http://intranet/alerts.do) which displays information in this format: 
 <?xml version="1.0" encoding="iso-8859-1" ?>
<Alerts>

 <Item>

  <IM></IM>

  <Priority></Priority>

  <DateSent></DateSent>

  <Subject></Subject>

  <Body></Body>

</Item>

</Alerts>

 
New Post
2/5/2009 12:37 PM
 

Yes, the XML/XSL module can handle any xml data island.  You will need a custom xsl transformation file, though.  Since the link is an intranet, I can't see the example, but if the structure is exactly like the one you offer, it should be easy to create a custom xsl for it.

 
New Post
2/6/2009 10:08 AM
 

I concede and need a bit of help now.
I have added an instance of XML/XSL to a page.

In settings I have added the XML source URL (which is dymanic, content changes) http://intranet.simpsons.net/IntranetWeb/getEpaArcAlerts.do
My post above defines the structure of the XML file. 

I created a very simple style sheet then set this as the default xsl source.
Click on apply and nothing happens.   This is my first time trying something like this and could use the help.  Any ideas?  Below is my xsl file.


<
?xml version='1.0'?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:template match="/">
<html>
<head>
<title>This is a test.</title>
</head>
<body>
<xsl:for-each select="Alerts/Item">
<p>Priority: <xsl:value-of select="Priority"/> Date: <xsl:value-of select="DateSent"/></p>
<b><xsl:value-of select="Subject"/></b>
<xsl:value-of select="Body"/>
</xsl:for-each>
</body>
</html>
</xsl:template>
</xsl:stylesheet>


 
New Post
2/6/2009 3:19 PM
 

The XML module will render XSL transform to the DNN page.  DNN already dynamically creates the overall page with HTML and BODY tags -- you do not want to include those again in your transform as you are not supposed to nest multiple HTML or BODY tags.

Remove those (and the HEAD tag section) from your XSL and try it again.

-mamlin


esmamlin atxgeek.me
 
New Post
2/7/2009 7:53 AM
 

Using your structure, here's a quick example.  Let's say you have this data:

 <Item>
  <IM>2009-001</IM>
  <Priority>3</Priority>
  <DateSent>2009-01-09T04:00:48Z-0600</DateSent>
  <Subject>Print Queue Stalled - cmtrb01</Subject>
  <Body>Print Queue Audit reports printer cmtrb01 has 20 entries queued over threshold. Condition indicates printer may be jammed
  or network connection lost.</Body>
</Item>
 <Item>
  <IM>2009-002</IM>
  <Priority>1</Priority>
  <DateSent>2009-01-09T04:23:00Z-0600</DateSent>
  <Subject>Server Down - Alpha</Subject>
  <Body>Alpha server faulted and restarted.</Body>
</Item>
 <Item>
  <IM>2009-003</IM>
  <Priority>2</Priority>
  <DateSent>2009-01-09T05:34:10Z-0600</DateSent>
  <Subject>Disk Space Below Threshold - dskpart02</Subject>
  <Body>dskpart02 disk below threshold.  Needs manual audit, and corrective action.</Body>
</Item>
</Alerts>

A simple XSL example:

<?xml version='1.0'?>
<xsl:stylesheet version="1.0"
    xmlns:xsl="http://www.w3.org/1999/XSL/Transform" >
<xsl:template match="/">
<xsl:apply-templates select="Alerts/Item"/>
</xsl:template>
<xsl:template match="Alerts/Item">
Date: <xsl:value-of select="DateSent"/><br/>
Priority: <xsl:value-of select="Priority"/><br/>
Subject: <xsl:value-of select="Subject"/><br/>
Body: <xsl:value-of select="Body"/><br/>
========================================<br/>
</xsl:template>
</xsl:stylesheet>

Yields this view:

Date: 2009-01-09T04:00:48Z-0600
Priority: 3
Subject: Print Queue Stalled - cmtrb01
Body: Print Queue Audit reports printer cmtrb01 has 20 entries queued over threshold. Condition indicates printer may be jammed or network connection lost.
========================================
Date: 2009-01-09T04:23:00Z-0600
Priority: 1
Subject: Server Down - Alpha
Body: Alpha server faulted and restarted.
========================================
Date: 2009-01-09T05:34:10Z-0600
Priority: 2
Subject: Disk Space Below Threshold - dskpart02
Body: dskpart02 disk below threshold. Needs manual audit, and corrective action.
========================================
 

There are a lot of other possibilities, which require more knowledge of XSL.

 
Previous
 
Next
HomeHomeOur CommunityOur CommunityGeneral Discuss...General Discuss...Can I dispaly this info with DNN?Can I dispaly this info with DNN?


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