YM4R - convert variable to string error

Rails 2.3.8, ruby 1.9.2.0, rubygems 1.3.7, ym4r-0.6.1, ym4r_gm (http:// github.com/ewildgoose/ym4r_gm).

Help?

I keep getting the following error:

ActionView::TemplateError (can't convert Ym4r::GmPlugin::Variable to String (Ym4r::GmPlugin::Variable#to_str gives Ym4r::GmPlugin::Variable)) on line #3 of app/views/gpspoints/ show.html.erb:

1: src="Google Maps? file=api&v=2&key=ABQIAAAA3Nm6v1pCMGUPdARN6pwe_xTJQa0g3IQ9GZqIMmInSLzwtGDKaBS7wWc7Vg3TkBH6bFVCpYKd7154Yg"

2: <%= GMap.header %> 3: <%= @map.to_html %> 4: <%= @map.div(:width => 600, :height => 400) %>

I believe the @map.to_html call is failing.

I ran the code on the console and the @map.control_init(:large_map => true,:map_type => true) call returned "nil". I am new to RoR - - I do not know if the 'nil' behavior is to be expected. I was curious because the latter call appears to build the array for the @map.to_html call.

This is very frustrating; I have the midlet running and datastore complete in my N95 and the mySQL database under RoR ready . .. but, the whole point is to display the GPS from the phone on the map. Arrrghhhh!

If anyone has any thoughts, I would apprecate your guidance.

Beev

I had the same problem.

In mapping.rb of the plugin, add this function to class Variable

def to_str    @variable + ";" end

Appears to work fine after this fix.

Dave