SitePoint Sponsor

User Tag List

Results 1 to 3 of 3
  1. #1
    SitePoint Member
    Join Date
    Nov 2010
    Posts
    2
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    transfom xml using xsl

    hi all,

    please can u help me, it's urgent and i'm working on it about 5 days without result

    i have a xml file:
    Code:
    - <Menus>
    - <UsersMenu>
      <ID>1</ID> 
      <Text>Button1</Text> 
    - <UsersMenu>
      <ID>2</ID> 
      <Text>B1I1</Text> 
      <link>template.aspx</link> 
      <parent>1</parent> 
      </UsersMenu>
    - <UsersMenu>
      <ID>3</ID> 
      <Text>B1I2</Text> 
      <parent>1</parent> 
    - <UsersMenu>
      <ID>6</ID> 
      <Text>B1I2I1</Text> 
      <link>template.aspx</link> 
      <parent>3</parent> 
      </UsersMenu>
      </UsersMenu>
    - <UsersMenu>
      <ID>4</ID> 
      <Text>B1I3</Text> 
      <parent>1</parent> 
    - <UsersMenu>
      <ID>5</ID> 
      <Text>B1I3I1</Text> 
      <link>template.aspx</link> 
      <parent>4</parent> 
      </UsersMenu>
      </UsersMenu>
      </UsersMenu>
      </Menus>
    i want to pass it to xsl template to have this output:
    HTML Code:
    <div class="arrowlistmenu">
    
    <h3 class="menuheader expandable">Button1</h3>
    	<ul class="categoryitems">
    		<li><a href="template.aspx">B1I1</a></li>
    		<li><a href="template.aspx" class="subexpandable">B1I2</a>
    			<ul class="subcategoryitems" style="margin-left: 15px">
    				<li><a href="template.aspx">B1I2I1</a></li>
    			</ul>
    		</li>
    		<li><a href="template.aspx" class="subexpandable">B1I3</a>
    			<ul class="subcategoryitems" style="margin-left: 15px">
    				<li><a href="template.aspx">B1I3I1</a></li>
    			</ul>
    		</li>
    	</ul>
    
    <h3 class="menuheader expandable">Button2</h3>
    	<ul class="categoryitems">
    		<li><a href="template.aspx" >B2I1</a></li>
    	</ul>
    </div>
    please can u help to write the XSL Template

    Thanks

  2. #2
    SitePoint Enthusiast
    Join Date
    Oct 2010
    Posts
    32
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    much better to try dynamic language to create automate xml file.

  3. #3
    SitePoint Member
    Join Date
    Nov 2010
    Posts
    2
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I created the xml file dynamicaly within .net, my issue is to create the XSL file to have the HTML that i want


Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •