From: Andrew Tongen Date: 2006-10-28T01:43:07+09:00 Subject: adding soap element attributes Hi, I have a question that I hope will be simple for someone to answer. I am using soap4r to write a simple library to consume web services from an application. The application does not include a WSDL document, so I have to write everything by hand. The application requires attributes in certain elements of the soap request, and I am having a little trouble figuring out how to do this. So far, a portion of my test code looks like this: driver = SOAP::RPC::Driver.new(endpoint, 'urn:namespace') driver.add_method_as('get_account', 'GetAccountRequest', 'account') get_account = driver.get_account('user@example.com') which produces this: user@example.com but I need the soap request to look like this: user@example.com with the by="name" attribute in the account element. I've been experimenting with SOAP::Mapping::Registry to achieve this, but I am not sure how it would be done, or even if this is the correct approach to take. If anyone can offer any assistance, it would be appreciated. Thanks, Andrew -- Posted via http://www.ruby-forum.com/.