Jump to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Featured Replies

  • Newbies

Hi mine name is Marc. I have a problem here which goes like this.

I created 3 XML files which looks like this....(Example of first, second and third file).

---1st---

<dataseries>

<location WMO="1" latitude="0.1833" longitude="94.4667">

<date y="1962">

<month m="1128">

<time time1="2254">

<info vessel="49KO" cruise="00703" station="0007" pairs=" 20" datatype="1" />

<profile id="SD21009_10">

<point depth="0000" temperature="28300" p_temp="1" salinity="33480" p_sal="2" />

<point depth="0010" temperature="28490" p_temp="2" salinity="33510" p_sal="2" />

<point depth="0019" temperature="28330" p_temp="2" salinity="33960" p_sal="2" />

<point depth="0029" temperature="28160" p_temp="2" salinity="34270" p_sal="2" />

<point depth="0048" temperature="27960" p_temp="2" salinity="34720" p_sal="2" />

<point depth="0073" temperature="27790" p_temp="2" salinity="34720" p_sal="2" />

<point depth="0097" temperature="26790" p_temp="2" salinity="34990" p_sal="2" />

<point depth="0121" temperature="19910" p_temp="2" salinity="35190" p_sal="2" />

<point depth="0146" temperature="15370" p_temp="2" salinity="35060" p_sal="2" />

<point depth="0195" temperature="13110" p_temp="2" salinity="34970" p_sal="2" />

<point depth="0244" temperature="12150" p_temp="2" salinity="35030" p_sal="2" />

<point depth="0299" temperature="11350" p_temp="2" salinity="35070" p_sal="2" />

<point depth="0398" temperature="10790" p_temp="2" salinity="35190" p_sal="2" />

<point depth="0498" temperature="09990" p_temp="2" salinity="35010" p_sal="2" />

<point depth="0598" temperature="09040" p_temp="2" salinity="34990" p_sal="2" />

<point depth="0798" temperature="08030" p_temp="2" salinity="34990" p_sal="2" />

<point depth="0998" temperature="06270" p_temp="2" salinity="34970" p_sal="2" />

<point depth="1198" temperature="05430" p_temp="2" salinity="34790" p_sal="7" />

<point depth="1426" temperature="04010" p_temp="2" salinity="34780" p_sal="2" />

<point depth="2120" temperature="02650" p_temp="2" salinity="34760" p_sal="2" />

</profile>

</time>

</month>

</date>

</location>

</dataseries>

---2nd---

<dataseries>

<location WMO="1" latitude="0.0667" longitude="95">

<date y="1964">

<month m="0403">

<time time1="0500">

<info vessel="09DM" cruise="00053" station="0019" pairs=" 27" datatype="1" />

<profile id="SD21009_11">

<point depth="0000" temperature="29720" p_temp="2" salinity="33135" p_sal="3" />

<point depth="0025" temperature="29420" p_temp="2" salinity="33378" p_sal="3" />

<point depth="0050" temperature="27680" p_temp="2" salinity="33782" p_sal="3" />

<point depth="0070" temperature="23160" p_temp="2" salinity="35238" p_sal="3" />

<point depth="0080" temperature="22620" p_temp="2" salinity="35272" p_sal="3" />

<point depth="0100" temperature="21530" p_temp="2" salinity="35291" p_sal="3" />

<point depth="0125" temperature="19770" p_temp="2" salinity="35197" p_sal="3" />

<point depth="0150" temperature="17070" p_temp="2" salinity="35146" p_sal="3" />

<point depth="0200" temperature="13480" p_temp="2" salinity="35098" p_sal="3" />

<point depth="0250" temperature="12660" p_temp="2" salinity="35076" p_sal="3" />

<point depth="0300" temperature="11720" p_temp="2" salinity="35054" p_sal="3" />

<point depth="0400" temperature="11140" p_temp="2" salinity="35042" p_sal="3" />

<point depth="0500" temperature="09650" p_temp="2" salinity="34984" p_sal="3" />

<point depth="0600" temperature="09050" p_temp="2" salinity="35004" p_sal="3" />

<point depth="0700" temperature="08690" p_temp="2" salinity="35004" p_sal="3" />

<point depth="0800" temperature="08150" p_temp="2" salinity="34989" p_sal="3" />

<point depth="0900" temperature="07370" p_temp="2" salinity="34955" p_sal="3" />

<point depth="1000" temperature="06610" p_temp="2" salinity="34937" p_sal="3" />

<point depth="1100" temperature="05860" p_temp="2" salinity="34900" p_sal="3" />

<point depth="1200" temperature="05320" p_temp="2" salinity="34884" p_sal="3" />

<point depth="1300" temperature="05030" p_temp="2" salinity="34874" p_sal="3" />

<point depth="1500" temperature="04240" p_temp="2" salinity="34846" p_sal="3" />

<point depth="2000" temperature="02630" p_temp="2" salinity="34781" p_sal="3" />

<point depth="2500" temperature="02100" p_temp="2" salinity="34758" p_sal="3" />

<point depth="3000" temperature="01650" p_temp="2" salinity="34752" p_sal="3" />

<point depth="3500" temperature="01390" p_temp="2" salinity="34735" p_sal="3" />

<point depth="4000" temperature="01130" p_temp="2" salinity="34727" p_sal="3" />

</profile>

</time>

</month>

</date>

</location>

</dataseries>

---3rd---

<dataseries>

<location WMO="1" latitude="0" longitude="95">

<date y="1962">

<month m="0808">

<time time1="0830">

<info vessel="09DM" cruise="00029" station="0030" pairs=" 22" datatype="1" />

<profile id="SD21009_12">

<point depth="0000" temperature="29350" p_temp="2" salinity="34109" p_sal="3" />

<point depth="0025" temperature="29100" p_temp="2" salinity="34108" p_sal="3" />

<point depth="0049" temperature="29110" p_temp="2" salinity="34105" p_sal="3" />

<point depth="0074" temperature="29060" p_temp="2" salinity="34152" p_sal="3" />

<point depth="0099" temperature="24910" p_temp="2" salinity="34981" p_sal="3" />

<point depth="0124" temperature="16670" p_temp="2" salinity="35123" p_sal="3" />

<point depth="0149" temperature="12890" p_temp="2" salinity="35082" p_sal="3" />

<point depth="0198" temperature="12210" p_temp="2" salinity="35067" p_sal="3" />

<point depth="0248" temperature="11350" p_temp="2" salinity="35042" p_sal="3" />

<point depth="0297" temperature="11130" p_temp="2" salinity="35030" p_sal="3" />

<point depth="0396" temperature="10710" p_temp="2" salinity="35018" p_sal="3" />

<point depth="0495" temperature="10140" p_temp="2" salinity="34995" p_sal="3" />

<point depth="0691" temperature="08510" p_temp="2" salinity="34999" p_sal="3" />

<point depth="0883" temperature="07820" p_temp="2" salinity="34959" p_sal="3" />

<point depth="1072" temperature="05920" p_temp="2" salinity="34895" p_sal="3" />

<point depth="1262" temperature="05330" p_temp="2" salinity="34873" p_sal="3" />

<point depth="1452" temperature="04480" p_temp="2" salinity="34846" p_sal="3" />

<point depth="1940" temperature="02750" p_temp="2" salinity="34780" p_sal="3" />

<point depth="2428" temperature="02170" p_temp="2" salinity="34754" p_sal="3" />

<point depth="2916" temperature="01730" p_temp="2" salinity="34738" p_sal="3" />

<point depth="3405" temperature="01500" p_temp="2" salinity="34729" p_sal="3" />

<point depth="3893" temperature="01170" p_temp="2" salinity="34719" p_sal="3" />

</profile>

</time>

</month>

</date>

</location>

</dataseries>

The both XML files i have contains Points. First file have 20 points, second file have 27 points and for example the third file i have 22 points.

Mine problem is that I want to display the position of every first point in each file. Which is to say the first XML file is 1 since it start from the first. Then the second XML file is 21 since the last point of first XML file is 20. Lastly the last XML file is 48 since the first and second points of both files add up to 47. What do you write in the XSL file to enable this function to work? Need urgently.

Then i created a XSL file which display some of the data like date,month, time and etc.

This is mine XSL file.

<?xml version="1.0"?>

<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">

<xsl:output omit-xml-declaration="yes" />

<xsl:param name="Danum" select='"1"'>

</xsl:param>

<xsl:template match="/">

<xsl:if test="not(point[@salinity='-9999'])">

<xsl:value-of select="dataseries/location/date/@y"/>

<xsl:text>,</xsl:text>

<xsl:number value="dataseries/location/date/month/@m" grouping-separator="," grouping-size="2"/>

<xsl:text>,</xsl:text>

<xsl:value-of select="dataseries/location/date/month/time/@time1"/>

<xsl:text>,</xsl:text>

<xsl:value-of select="dataseries/location/@latitude"/>

<xsl:text>,</xsl:text>

<xsl:value-of select="dataseries/location/@longitude"/>

<xsl:text>,</xsl:text>

<xsl:value-of select="count(//point)"/><br/>

</xsl:if>

</xsl:template>

</xsl:stylesheet>

Thanks.

Create an account or sign in to comment

Important Information

By using this site, you agree to our Terms of Use.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.