xref: /aosp_15_r20/external/apache-xml/test/tests/contrib/xsltc/schemasoft/selectHREF.xsl (revision 1212f9a0ffdc28482b8821715d2222bf16dc14e2)
1<?xml version="1.0"?>
2
3<!-- Extracts href attributes
4
5
6
7Copyright J.M. Vanel 2000 - under GNU public licence
8
9xt testHREF.xml selectHREF.xslt > selectHREF.txt
10
11 -->
12
13
14
15<xsl:stylesheet xmlns:xsl='http://www.w3.org/1999/XSL/Transform'
16
17                version="1.0" >
18
19
20
21<xsl:output method="text"/>
22
23
24
25<xsl:template match ="*" >
26
27  <xsl:apply-templates select="*|@*" />
28
29 </xsl:template>
30
31
32
33 <xsl:template match ="@href|@HREF" >
34
35   href=<xsl:value-of select='.' />
36
37 </xsl:template>
38
39
40
41 <!-- Suppress element text content : -->
42
43 <xsl:template match ="text()" ></xsl:template>
44
45
46
47 <xsl:template match ="/" >
48
49  <xsl:apply-templates/>
50
51 </xsl:template>
52
53  <!--
54   * Licensed to the Apache Software Foundation (ASF) under one
55   * or more contributor license agreements. See the NOTICE file
56   * distributed with this work for additional information
57   * regarding copyright ownership. The ASF licenses this file
58   * to you under the Apache License, Version 2.0 (the  "License");
59   * you may not use this file except in compliance with the License.
60   * You may obtain a copy of the License at
61   *
62   *     http://www.apache.org/licenses/LICENSE-2.0
63   *
64   * Unless required by applicable law or agreed to in writing, software
65   * distributed under the License is distributed on an "AS IS" BASIS,
66   * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
67   * See the License for the specific language governing permissions and
68   * limitations under the License.
69  -->
70
71</xsl:stylesheet>
72