Small width layout Medium width layout Maximum width layout Small text Medium text Large text
     Search
Downloads Downloads Directory Directory Forums Forums Forge Forge Blogs Blogs        Marketplace Marketplace Careers Program Careers
Community › Forums Register  |  

The best choice for your web site host, email hosting, and domain registration.
  Need Help?  
Professional technical support for DotNetNuke is available from DotNetNuke Corporation.
 


  Ads  
Active Modules -- Active Forums for DotNetNuke
 


  Sponsors  

Meet Our Sponsors

Mad Development is a full service interactive agency focusing on the merge of design, technology, e-commerce, and affiliate marketing by providing total website solutions.
AspDotNetStoreFront - E-Commerce by Design - The Leading ASP.NET shopping cart platform for developers!
Click here to go to dev.live.com for Windows Live developer resources
SteadyRain
DataSprings - Great Ideas. Always Flowing.
R2integrated - formerly bi4ce
 


DotNetNuke Forums
 
  Forum  DotNetNuke® Pro...  News Module [Le...  HTML tags not effective?
Previous Previous
 
Next Next
New Post 6/23/2008 8:56 PM
User is offline jgurley
45 posts
10th Ranked


HTML tags not effective? 

I have an XSL style sheet generating HTML tags as it parses my rss (rdf) feed.  I'm trying to put values in a table, but my RSS window just looks like this:

<html><head></head><body> <table><tbody> <tr><th>Date</th><th>Time</th><th>Tide</th><th>Height</th><th>Time</th><th>Event</th></tr> <tr> </tr><tr><td>2008-06-22</td> <td>3:53 PM PDT</td> <td> Hig</td> <td>5.50 feet </td> <td>8</td> <td>Sunset</td> </tr><tr><td>2008-06-22</td> <td>9:01 PM PDT</td> <td> Low</td> <td>3.14 feet </td> </tr><tr><td>2008-06-23</td> <td>2:30 AM PDT</td> <td> Hig</td> <td>6.13 feet </td> <td>5</td> <td>Sunrise</td> </tr><tr><td>2008-06-23</td> <td>9:36 AM PDT</td> <td> Low</td> <td>-0.35 feet </td> </tr><tr><td>2008-06-23</td> <td>4:27 PM PDT</td> <td> Hig</td> <td>5.67 feet </td> <td>8</td> <td>Sunset</td> </tr><tr><td>2008-06-23</td> <td>9:55 PM PDT</td> <td> Low</td> <td>2.93 feet </td> </tr><tr><td>2008-06-24</td> <td>3:19 AM PDT</td> <td> Hig</td> <td>5.68 feet </td> <td>5</td> <td>Sunrise</td> </tr><tr><td>2008-06-24</td> <td>10:13 AM PDT</td> <td> Low</td> <td>0.08 feet </td> </tr><tr><td>2008-06-24</td> <td>5:03 PM PDT</td> <td> Hig</td> <td>5.91 feet </td> <td>8</td> <td>Sunset</td> </tr><tr><td>2008-06-24</td> <td>10:57 PM PDT</td> <td> Low</td> <td>2.58 feet </td> </tr><tr><td>2008-06-25</td> <td>4:18 AM PDT</td> <td> Hig</td> <td>5.17 feet </td> <td>5</td> <td>Sunrise</td> </tr><tr><td>2008-06-25</td> <td>10:51 AM PDT</td> <td> Low</td> <td>0.62 feet </td> </tr><tr><td>2008-06-25</td> <td>5:40 PM PDT</td> <td> Hig</td> <td>6.19 feet </td> <td>8</td> <td>Sunset</td> </tr><tr><td>2008-06-26</td> <td>12:03 AM PDT</td> <td> Low</td> <td>2.04 feet </td> </tr><tr><td>2008-06-26</td> <td>5:31 AM PDT</td> <td> Hig</td> <td>4.68 feet </td> <td>5</td> <td>Sunrise</td> </tr><tr><td>2008-06-26</td> <td>11:34 AM PDT</td> <td> Low</td> <td>1.24 feet </td> </tr><tr><td>2008-06-26</td> <td>6:19 PM PDT</td> <td> Hig</td> <td>6.52 feet </td> <td>8</td> <td>Sunset</td> </tr><tr><td>2008-06-27</td> <td>1:11 AM PDT</td> <td> Low</td> <td>1.32 feet </td> </tr></tbody></table></body></html>

Can I get the News module to respond the way I'm seeking?


 
New Post 6/24/2008 8:28 AM
User is offline iwonder
409 posts
8th Ranked


Re: HTML tags not effective? 

Post your xsl code, I can't tell what's wrong without seeing it.  Include the newsfeed link you are using, if that's applicable.

 
New Post 6/24/2008 11:55 AM
User is offline jgurley
45 posts
10th Ranked


Re: HTML tags not effective? 

RSS URL:

http://www.tides.info/?command=rss&location=Brookings%2c+Chetco+Cove%2c+Oregon

XSL Code:

<?xml version='1.0'?>
<xsl:stylesheet
  version="1.0" exclude-result-prefixes="rdf rss l dc admin content xsl"
                xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
                xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
                  xmlns:rss="http://purl.org/rss/1.0/"
                xmlns:dc="http://purl.org/dc/elements/1.1/"
                  xmlns:admin="http://webns.net/mvcb/"
                  xmlns:l="http://purl.org/rss/1.0/modules/link/"
                  xmlns:content="http://purl.org/rss/1.0/modules/content/">
<!-- phil 'iwonder' guerra - xsl simple rdf translation file. -->
    <xsl:output omit-xml-declaration="yes"/>
   
    <xsl:template match="/rdf:RDF">
    &lt;html&gt;&lt;head&gt;&lt;/head&gt;&lt;body&gt;
    &lt;table&gt;&lt;tbody&gt;
        &lt;tr&gt;&lt;th&gt;Date&lt;/th&gt;&lt;th&gt;Time&lt;/th&gt;&lt;th&gt;Tide&lt;/th&gt;&lt;th&gt;Height&lt;/th&gt;&lt;th&gt;Time&lt;/th&gt;&lt;th&gt;Event&lt;/th&gt;&lt;/tr&gt;
        &lt;tr&gt;
       <xsl:for-each select="rss:item">
           <xsl:variable name="desc" select="rss:description"/>
           <xsl:if test="substring($desc,1,2)='20'">
               <xsl:variable name="date" select="substring-before($desc,' ')"/>
                  
               <xsl:if test="contains($desc,'Tide')">
                   &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;<xsl:value-of select="$date" disable-output-escaping="yes"/>&lt;/td&gt;
                   &lt;td&gt;<xsl:value-of select="substring-before(substring-after($desc,'at '),': ')" disable-output-escaping="yes"/>&lt;/td&gt;
                   &lt;td&gt;<xsl:value-of select="substring(substring-after($desc,'feet '),1,4)" disable-output-escaping="yes"/>&lt;/td&gt;
                   &lt;td&gt;<xsl:value-of select="substring-before(substring-after($desc,'T: '),'feet')" disable-output-escaping="yes"/> feet &lt;/td&gt;
                </xsl:if>
               
                <xsl:if test="(contains($desc,'Sun'))">
                    &lt;td&gt;<xsl:value-of select="substring-before(substring-after($desc,'at '),':')" disable-output-escaping="yes"/>&lt;/td&gt;
                    &lt;td&gt;<xsl:value-of select="substring-after($desc,'T: ')" disable-output-escaping="yes"/>&lt;/td&gt;
                   
                </xsl:if>
               
            </xsl:if>
       </xsl:for-each>
       &lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/body&gt;&lt;/html&gt;
    </xsl:template>
</xsl:stylesheet>

 
New Post 6/24/2008 1:35 PM
User is offline iwonder
409 posts
8th Ranked


Re: HTML tags not effective? 

From what I can tell, you are actually coding literal characters.  Try just using straight HTML tags in the xsl, it is allowed.  I changed those literals to the HTML tags and it works.  Though, you'll have a lot of work to do with the actual layout, it doesn't display very well.

See if that helps.

 
New Post 6/24/2008 1:45 PM
User is offline jgurley
45 posts
10th Ranked


Re: HTML tags not effective? 

I tried the actual HTML first, and I kept getting errors with my </tr> tags.  Maybe I have to put them somewhere besides the beginning of a line.  I'll try again.

I'm sure the layout is poor, as I hadn't been able to "see" it yet.  If you're really feeling helpful, you can help me with the syntax of "previous-sibling" so I can detect the date change.  I would have never discovered the <xsl:for-each select="rss:item"> if it hadn't been for your example.  Why "rss:" is at the beginning is a mystery I'll accept.

<xsl:if test="$date ! = substring-before(preceding-sibling::rss:item[1]/description,' ')"> seems like the natural extrapolation, but it rejects it.

 
Previous Previous
 
Next Next
  Forum  DotNetNuke® Pro...  News Module [Le...  HTML tags not effective?
 


Forum Policy

These Discussion Forums are dedicated to the discussion of the DotNetNuke Web Application Framework.

For the benefit of the community and to protect the integrity of the project, 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 DotNetNuke.
2. Discussion or promotion of DotNetNuke product releases under a different brand name are strictly prohibited.
3. No Flaming or Trolling.
4. No Profanity, Racism, or Prejudice.
5. Site Moderators have the final word on approving/removing a thread or post or comment.
6. English language posting only, please.

 


BataviaSoft DotNetNuke Solutions
BataviaSoft offers custom DotNetNuke solutions especially for the European and the South East Asian market.
www.bataviasoft.com
Viva Portals, L.L.C.
Expert module development and graphic design.
www.continure.com
DNN Photo Gallery
DNN Photo Gallery is a truly unique photo management module released January 1st 2006. With DNN Photo Gallery you can REALLY integrate images into your existing portal and make them look like they were designed for your site.
DNN Photo Gallery

DotNetNuke Corporation   Terms Of Use  Privacy Statement
DotNetNuke®, DNN®, and the DotNetNuke logo are trademarks of DotNetNuke Corporation
Hosted by MaximumASP