blogs to left menu
This commit is contained in:
@@ -330,10 +330,12 @@
|
||||
</p>
|
||||
{% endif %}
|
||||
{% block ad %}
|
||||
<a href="https://pryglrowing.com">
|
||||
<img src="/static/img/prygl.jpg">
|
||||
<p style="text-align: center">Prygl Rowing Camps</p>
|
||||
</a>
|
||||
<div id="id_blogs">
|
||||
</div>
|
||||
<a href="https://pryglrowing.com">
|
||||
<img src="/static/img/prygl.jpg">
|
||||
<p style="text-align: center">Prygl Rowing Camps</p>
|
||||
</a>
|
||||
{% endblock %}
|
||||
</ad>
|
||||
|
||||
@@ -432,3 +434,25 @@
|
||||
});
|
||||
});
|
||||
</script>
|
||||
<script type='text/javascript'
|
||||
src='https://ajax.googleapis.com/ajax/libs/jquery/2.1.4/jquery.min.js'>
|
||||
</script>
|
||||
|
||||
<script>
|
||||
$( document ).ready(function() {
|
||||
console.log('loading script');
|
||||
$.getJSON(window.location.protocol + '//'+window.location.host + '/getblogs/', function(data) {
|
||||
var html = '';
|
||||
|
||||
$.each(data, function(key, blog) {
|
||||
console.log(blog.title);
|
||||
html += '<div class="site-announcement-box"><div class="site-announcement-white">';
|
||||
html += '<a style="text-decoration: none; color: white;" href="'+blog.link+'">';
|
||||
html += blog.title;
|
||||
html += '</a>';
|
||||
html += '</div></div>';
|
||||
});
|
||||
$("#id_blogs").html(html);
|
||||
});
|
||||
});
|
||||
</script>
|
||||
|
||||
Reference in New Issue
Block a user