Forum: Ruby on Rails render partial for ym4r gmarker info_window in rjs

Announcement (2017-05-07): is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see and for other Rails- und Ruby-related community platforms.
gsterndale (Guest)
on 2008-11-21 09:10
(Received via mailing list)
Hi All,

I'm trying to add a marker with an info_window on my map in a rjs
request using a partial.

---- new.js.rjs ----
marker =[, @bar.lng], :info_window => render
(:partial => "/foo/bar", :object => @bar))
page << @map.record_global_init(marker.declare('new_bar')) # declare
js variable
page << @map.overlay_init(marker)
page << @map.record_init("new_bar.openInfoWindowHtml(\"#
----end new.js.rjs ----

----end _bar.html.erb----

The above works fine. However if I add a new line or other html to my
partial the marker and  info_window do not appear.


----end _bar.html.erb----

All the examples I could find use very simple text for the info_window

Any help would be greatly appreciated. Thanks.
This topic is locked and can not be replied to.