Skip to content

Instantly share code, notes, and snippets.

@coderforhire
Created June 26, 2012 19:21
Show Gist options
  • Save coderforhire/2998203 to your computer and use it in GitHub Desktop.
Save coderforhire/2998203 to your computer and use it in GitHub Desktop.
xml.instruct!
xml.movies do
@sports.each do |sport|
xml.sport sport
end
@entertainments.each do |entertainment|
xml.entertainments entertainment
end
end
@rking
Copy link

rking commented Jun 26, 2012

xml.movies do                                                                   
  @sports.each do |sport|                                                       
    xml.sport sport                                                             
  end                                                                           

  xml.entertainments do                                                         
    @entertainments.each do |entertainment|                                     
      xml.entertainment entertainment                                           
    end                                                                               
  end                                                                           
end 

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