Skip to content
This repository has been archived by the owner on Nov 30, 2017. It is now read-only.

Commit

Permalink
Merge pull request #95 from skowi/fix/product-comments-javascript
Browse files Browse the repository at this point in the history
Moved FOSCommentBundle JavaScripts before </body> tag
  • Loading branch information
Paweł Jędrzejewski committed Jan 2, 2013
2 parents 80258bf + 1d27d7b commit e386c40
Showing 1 changed file with 12 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,18 @@

<hr />
<div class="well">
{% include 'FOSCommentBundle:Thread:async.html.twig' with {'id': product.commentThreadId} %}
<div id="fos_comment_thread"></div>
</div>
<hr />
{% endblock %}

{% block javascripts %}
{{ parent() }}
<script type="text/javascript">
var fos_comment_thread_id = '{{ product.CommentThreadId }}';
var fos_comment_thread_api_base_url = '{{ path('fos_comment_get_threads') }}';
</script>
{% javascripts '@FOSCommentBundle/Resources/assets/js/comments.js' %}
<script async="" type="text/javascript" src="{{ asset_url }}"></script>
{% endjavascripts %}
{% endblock %}

0 comments on commit e386c40

Please sign in to comment.