views:

29

answers:

1

In an Rails app I want to modify the DOM of a web page using javascript

Can I save the resulting HTML (of the whole page) after each modification to a database?

Thanks.

A: 

With jQuery you could use var html = $(document).html(); Then post the html with $.ajax() to the controller where you choose to save it.

Keyo
Thank you Keyo! (waiting a few minutes to award the answer)
Victor P