Asp Forum
Home
|
Login
|
Register
|
Search
Forums
>
comp.lang.ruby
reformat with Hpricot?
Phlip
8/23/2007 7:55:00 AM
Rubies:
Here's how to indent with REXML:
doc = Document.new('<yo><dude /><yo>')
indent_spaces = 2
doc.write($stdout, indent_space)
That produces:
<yo>
<dude />
<yo>
How can Hpricot "pretty print" like that??
--
Phlip
http://www.oreillynet.com/onlamp/blog/2007/08/assert_hpri...
1 Answer
Philip Gatt
9/4/2007 12:46:00 AM
0
Very interesting question. I don't know the answer, but I'll *bump*
this post for ya!
On Aug 23, 2007, at 7:05 AM, Phlip wrote:
> Rubies:
>
> Here's how to indent with REXML:
>
> doc = Document.new('<yo><dude /><yo>')
> indent_spaces = 2
> doc.write($stdout, indent_space)
>
> That produces:
>
> <yo>
> <dude />
> <yo>
>
> How can Hpricot "pretty print" like that??
>
> --
> Phlip
>
http://www.oreillynet.com/onlamp/blog/2007/08/assert_hpri...
>
Servizio di avviso nuovi messaggi
Ricevi direttamente nella tua mail i nuovi messaggi per
reformat with Hpricot?
Inserendo la tua e-mail nella casella sotto, riceverai un avviso tramite posta elettronica ogni volta che il motore di ricerca troverà un nuovo messaggio per te
Il servizio è completamente GRATUITO!
x
Login to ForumsZone
Login with Google
Login with E-Mail & Password