我想要獲取XML節點的屬性值,並將其設置爲使用JQuery的變量。這可能嗎?將xml節點的屬性設置爲變量
<DataContainer>
<Customers>
<Customer customerId="7366" customerName="Boardwalk Audi" url=""
address="5930 West Plano Pkwy" city="Plano" state="Texas"
zipCode="75093" latitude="33.0160690000000000"
longitude="-96.8268970000000000">
<Customers>
<DataContainer>
我想設置的7366在客戶屬性,像下面以備後用一個變量:
$customerId = customer id from xml node attribute;
這可能嗎?讓我知道你是否需要更多的澄清。謝謝!
感謝您編輯Canavar。我總是忘記了4空格縮進,使可讀代碼塊。 – RyanPitts 2010-09-14 21:43:42