From: Michael Neumann Date: 2004-07-15T21:55:38+09:00 Subject: Re: problems with xslt4r Ralf M�ller wrote: > Hi, > > I'd like to use 'xslt4r', because i cannot install libxml2 + libxslt for > libxslt (ruby). > But i get theses errors when invoking xpath from 'xmlscan': > > ram@lilith:~/src/xml$irb > irb(main):001:0> require 'xpath' > /usr/local/lib/ruby/site_ruby/1.8/xpath.rb:10: warning: Object#type is > deprecated; use Object#class This is only a warning. It's easy to fix. Every occurence of type (not as local variable) should be replaced by self.class. > => true > irb(main):002:0> > > and if i try to apply the sheet on the test-data: > > ram@lilith:~/src/tar/xslt4r-0.0.2/test$ls > data.xml stylesheet.xsl stylesheet2.xsl test.xml test_style.xsl > ram@lilith:~/src/tar/xslt4r-0.0.2/test$ruby -rxslt test_style.xsl test.xml > /usr/local/lib/ruby/site_ruby/1.8/xpath.rb:10: warning: Object#type is > deprecated; use Object#class > test_style.xsl:1: parse error aha.... you're trying to run a XSLT file as Ruby code :-) try this: ruby xslt.rb test_style.xsl test.xml > is this version of xslt4r to old? it's quite old and uncomplete! > Anyway, does anyone know an easy way to apply stylesheets with ruby without > having libxml, libxslt(C-Lib) installed? Regards, Michael