Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. XML / XSL
  4. How to edit the single value in xml using xsl

How to edit the single value in xml using xsl

Scheduled Pinned Locked Moved XML / XSL
xmlhtmlregextutorialquestion
1 Posts 1 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • T Offline
    T Offline
    ThangamSundar
    wrote on last edited by
    #1

    Hai, my xml format: <?xml version="1.0" encoding="ISO-8859-1"?> <?xml-stylesheet type="text/xsl" href="PersonalDetails.xsl"?> <!-- Edited by XMLSpy® --> <PersonalDetails> <Record> <Name input="false"> <value>Saraswathi</value> </Name> <Address input="true"> <value>KML</value> </Address> <Age input="false"> <value>56</value> </Age> <Sex input="false"> <value>F</value> </Sex> <DOB input="false"> <value>24-07-1952</value> </DOB> </Record> <Record> <Name input="false"> <value>Latha</value> </Name> <Address input="false"> <value>KML</value> </Address> <Age input="false"> <value>28</value> </Age> <Sex input="false"> <value>F</value> </Sex> <DOB input="true"> <value>24-07-1980</value> </DOB> </Record> <Record> <Name input="false"> <value>hari</value> </Name> <Address input="false"> <value>KML</value> </Address> <Age input="false"> <value>58</value> </Age> <Sex input="true"> <value>M</value> </Sex> <DOB input="false"> <value>24-07-1950</value> </DOB> </Record> </PersonalDetails> And my xsl of that xml is: <?xml version="1.0" encoding="ISO-8859-1"?> <!-- Edited by XMLSpy® --> <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"> <xsl:output method='html' version='1.0' encoding='UTF-8' indent='yes'/> <xsl:template match="/"> <html> <body> <h2>Personal Details</h2> <table border="1"> <tr bgcolor="#9acd32"> <th align="left">Name</th> <th align="left">Address</th> <th align="left">Age</th> <th align="left">Sex</th> <th align="left">DOB</th> </tr> <xsl:for-each select="PersonalDetails/Record"> <xsl:sort select="Name"/> <tr> <td> <input type="text"> <xsl:attribute name="id"> <xsl:value-of select="Name"/> </xsl:attribute> <xsl:

    1 Reply Last reply
    0
    Reply
    • Reply as topic
    Log in to reply
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes


    • Login

    • Don't have an account? Register

    • Login or register to search.
    • First post
      Last post
    0
    • Categories
    • Recent
    • Tags
    • Popular
    • World
    • Users
    • Groups