<%= link_to('my_link') do %> <div>OPEN STREETMAP CONTENT</div><% end %>
You can put a div inside of the <a> generated by link_to and this will work for you but putting block elements inside of <a> is not really good practice. Instead you could try <span> instead of <div> On Friday, August 15, 2014 1:46:31 AM UTC-6, Melb01 wrote: > > Hi, > I am using openlayers gem to show a openstreetmap as div in a a rails app > how can I make this div as a link to an other page in the rails app using > link_to tag > > > regards > -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-talk+unsubscr...@googlegroups.com. To post to this group, send email to rubyonrails-talk@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/9a2863d8-5118-45e7-96c4-f16532ece901%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.