Note that there are some explanatory texts on larger screens.

plurals
  1. POJVector Interactive Map not Rendering in Rails 3
    primarykey
    data
    text
    <p>I've been trying to use this really cool JVector Interactive map plugin with my Rails 3 app but I must be doing something wrong because the map is not rendering. I haven't used JQuery much with Rails so am kind of new at this. I created a controller called Maps and a view called Intro.html.erb, which included my html from this tutorial: <a href="http://developer.practicalecommerce.com/articles/2988-Create-an-Interactive-Map-with-jVectorMap" rel="nofollow">http://developer.practicalecommerce.com/articles/2988-Create-an-Interactive-Map-with-jVectorMap</a> </p> <p>I also split up my .js functions by putting them in application.js. Since that didn't work I found some other code that I tried to put in my Intro.html.erb file:</p> <pre><code>&lt;!DOCTYPE html&gt; &lt;html&gt; &lt;head&gt; &lt;title&gt;Test&lt;/title&gt; &lt;link rel="stylesheet" href="public/javascripts/jquery.vector-map.css" type="text/css" media="screen" /&gt; &lt;script src="public/javascripts/jquery.min.js"&gt;&lt;/script&gt; &lt;script src="public/javascripts/jquery.vector-map.js"&gt;&lt;/script&gt; &lt;script src="public/javascripts/world-en.js"&gt;&lt;/script&gt; &lt;script&gt; $(function(){ $('#map').vectorMap(); }); &lt;/script&gt; &lt;/head&gt; &lt;body&gt; &lt;div id="map" style="width: 600px; height: 400px;"&gt;&lt;/div&gt; &lt;/body&gt; &lt;/html&gt; </code></pre> <p>It's still not rendering. I'm trying to run this in my development environment and am pointing locally to the files. For example: <strong><em>public/javascripts/world-en.js"</em></strong></p> <p>Any help would be greatly appreciated.</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload