First, obtain a Yahoo! App ID. Second, cut and paste this code into your HTML file or rails view (this code should work in Firefox and IE). You will need to edit the javascript where it says "YOUR_APP_ID_HERE" and replace that with the Yahoo! App ID you obtained. Third, you can call this javascript as follows:
<script type="text/javascript"> var cityName="Moscow"; var cityLat="55.7667"; var cityLong="37.6667"; </script> <A HREF="javascript:doSubmit();">Get a map</A>Of course, you'll need to substitute the appropriate city name, longitude and latitude in for the sample values above.
Now, when you point your browser at your HTML page or rails view, there should be a link labeled "Get a map"; clicking this button will take you to a map of your city.
Note that if the longitude and latitude are rounded off (e.g. 55.7 instead of 55.7667) the map may show a slightly wrong location; that is okay.