0

I'm trying to write a map story using odyssey.js from cartoDb. My webapp is built using django and has markdown-deux installed. I've created a visualisation in cartoDb.

I've used the share link to get the vizjson link but when I add it to the markdown in the post it is not showing.

It should be noted that I've had to do some shuffling to get the css and django to play nicely but the basemap is working fine.

0

I've checked that there are several Javascript errors with your visualization referring to googleapis. I'm attaching an image about it:

enter image description here

1
  • That's just relating to the basemap. Currently not causing the problem. On further investigation I think it is because the quotation marks (") around the vizjson string are rendering as " instead of ". I can't work out how to escape them. – Oliver Burdekin Feb 24 '15 at 13:16
0

I got it (by reading the docs). The aim was to use the same blog app to produce normal articles and also "map story" articles. The mapstory check box in admin means all the correct js and css files are loaded to use Odyssey.js in the view_map template.

Odyssey.js was autoescaping characters so all I need to add was this:

<script type="text/template" id="md_template">
    {% autoescape off %}
        {{post.body_text}}
    {% endautoescape %} 
</script>

markdown-duex django plugin I use for normal articles isn't necessary as Odyssey.js has it's own markdown-esque template (I think)

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.