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

HomeHomeDNN Open Source...DNN Open Source...Module ForumsModule ForumsXMLXMLLosing Output FormatingLosing Output Formating
Previous
 
Next
New Post
11/11/2012 7:38 PM
 

I am losing formating and my mind! I am tring to convert to a CSV format however I am losing the new line so everything comes through as a single record! 

The following style sheet works correctly in XMLSpy.

<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:output method="text"/>
<xsl:template match="/">
    <xsl:for-each select="Contacts/Contact">
   <xsl:value-of select="Email"/>
   <xsl:text>; </xsl:text>
   <xsl:value-of select="ContactID"/>
   <xsl:text>; </xsl:text>
   <xsl:value-of select="OrganizationID"/>
   <xsl:text>&#xA;</xsl:text>
   </xsl:for-each>
</xsl:template>
</xsl:stylesheet>

What can I do so that I do not lose the formating within the XML module?

The desired result is:

username1@domain.com; 55555; 66666
username2@domain.com; 77777; 88888
username3@domain.com; 99999; 11111

Can someone pleae tell me what I need to change before I jump off a cliff!

Thanks in advance!

Jason

 

 
New Post
11/12/2012 8:37 AM
 

Jason,

Which option did you set for output (advanced options). It will display in one line in HTML, but it should be fine if you set output to download, content type csv.

Stefan

 
New Post
11/12/2012 12:14 PM
 

Thanks for your reply. Unfortunately the content type is set to .csv! I've tried them all! Any other thoughts?

 
New Post
11/13/2012 5:39 PM
 
I took yet another look at this. Total time on this problem is 3 days. I am going to go out on a limb and say this functionality in the module is broken.

I would ask that someone try it and see if they have the same results.

to replicate:

Create style sheet (test.xsl) with the following:

xmlns:xsl="http://www.w3.org/1999/XSL/Transform">



"Email/text() | ContactID/text()
| OrganizationID/text()
"
>

;





Create sample data file test.xml with the following data:
---------------------------------------------------------------


user1@fakedomain.com
419290
431985


user2@fakedomain.com
742444
431840


user3@fakedomain.com
418791
431891


user4@fakedomain.com
419633
509638


user5@fakedomain.com
419343
431892



Configure these options within the module:

1. Data Source Typ = File (Use test.xml)
2. Select the rendering provider. = XSL Transformation
3. Ouput = as link to a download
4. Content Type = *.csv (text/comma-separated-values)

Lastly, download the file. Open in notepad. All results return as a single record/row. There should be a total of 5 lines / records if the transformation worked correctly within the module.



 
New Post
11/13/2012 5:53 PM
 
So the forum completely jacks up the formating of the style sheet and sample data. If anyone would like to help please let me know How I can get the sample style sheet and data to you!
 
Previous
 
Next
HomeHomeDNN Open Source...DNN Open Source...Module ForumsModule ForumsXMLXMLLosing Output FormatingLosing Output Formating


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