Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

Support for assigning a node's content to an attribute. #9

technicalpickles opened this Issue Jul 4, 2010 · 2 comments


None yet
3 participants

technicalpickles commented Jul 4, 2010

I was working on a wrapper for backpack's API, and they return XML like:

<note id='1132' title='My world!' created_at='2007-07-03 19:15:55'>
  It's a pretty place

A limitation of happymapper's API is that it doesn't let you easily get at "It's a pretty place". So, I slung together some code to let you:

module Backpack
  class Note
    include HappyMapper
    content :body

I went with the term 'content' to match LibXML::XML::Node's naming.

Check it out: http://github.com/technicalpickles/happymapper/tree/content


jnunemaker commented Jul 4, 2010


Hells yes!

This issue was closed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment