Builder::XmlMarkup and dashes

Has anyone hacked Builder::XmlMarkup to dasherize underscore tags by
default? I know I can use tag!, but I’d like to find a way for it to
translate underscores to dashes automatically. In other words:

xml.department_manager do
"fred
end

#=> fred

I tried hacking Builder::XmlBase.method_missing but got myself all
twisted up!

Thanks.

Steve

On 6/10/07, [email protected] [email protected] wrote:

Has anyone hacked Builder::XmlMarkup to dasherize underscore tags by
default? I know I can use tag!, but I’d like to find a way for it to
translate underscores to dashes automatically. In other words:

xml.department_manager do
"fred
end

xml.tag! ‘department-manger’, ‘fred’


Rick O.
http://lighthouseapp.com
http://weblog.techno-weenie.net
http://mephistoblog.com

Right, I know about ‘tag!’ but I was hoping to rig things such that
XmlMarkup always called ‘dasherize’ on element names.

Steve