我正在循環查看節點的值。XSLT:如果節點= A,則設置B = 1否則B = 2
If Node = B, then B has one of two possible meanings.
--If Node = A has been previously found in the file, then the value for A
should be sent as 1.
--If Node = A has NOT been found in the file, the the value for A should
be sent as 2.
where file is the xml source to be transformed
我想不出如何做到這一點。如果我正在使用允許變量重新分配/更改的編程語言,那麼很容易。但是,使用XSLT變量設置一次。
感謝您的回答,並介紹選擇。但我想我沒有清楚地解釋我的問題。已發佈另一個問題: XSLT:對於每個節點轉換,如果A = 2和A = 1都找到了,那麼可以這樣做 – Larry 2010-03-19 15:41:47