hpricot usage

  • Thread starter Archana Madduru
  • Start date
A

Archana Madduru

can anybody tell me how to write to a xml document using hpricot? Is it
possible to do that? Here is my xml in which i want to change the
ordernumber everytime i run my script.

<Order DocumentType="786" Action="doofus" EnterpriseCode="sibs"
SellerOrganizationCode="VENDOR" BuyerOrganizationCode="hp"
OrderNo="CG1XYAA3" OrderType="Regular" Currency="USD"
OrderDate="20060408" VendorID="000002895">
<OrderLines>
<OrderLine OrderedQty="20" ReqDeliveryDate="20060428" >
<Item ItemID="4405540021115" UnitOfMeasure="EACH"/>
</OrderLine>
</OrderLines>
<Interface CorpPOStatus="ACTIVE"/>
</Order>
 
J

Jason Roelofs

hpricot really is just a parsing library for HTML or XML.

For writing out XML, you should look into libxml-ruby or even just
REXML if you don't want an external dependency.

Jason
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
474,202
Messages
2,571,057
Members
47,662
Latest member
sxarexu

Latest Threads

Top