{% block mediagoblin_head%}
<style type = "text/css">
- tr > a { text-decoration:none; font-weight: bold; }
+ table a { text-decoration:none; font-weight: bold; text-transform:capitalize; }
+ #blogs_list {border-collapse:separate; border-spacing: 40px 0px ;}
</style>
{% endblock %}
{% block mediagoblin_content %}
-
+{% set blog_create_url = request.urlgen('mediagoblin.media_types.blog.create',
+ user=request.user.username) %}
{% if blogs %}
- <table>
- {% for blog in blogs %}
- {% set others_blog_url = request.urlgen('mediagoblin.media_types.blog.blog_post_listing',
- blog_slug=blog.slug, user=user.username) %}
- {% if not request.user or request.user.username != user.username%}
- <tr><a href="{{ others_blog_url }}">{{ blog.title }}</a></tr>
- {% else %}
- {% set my_blog_url = request.urlgen('mediagoblin.media_types.blog.blog-dashboard',
- blog_slug=blog.slug, user=request.user.username) %}
- <tr><a href="{{ my_blog_url }}">{{ blog.title }}</a></tr>
- {% endif %}
- <br>
+ <h2>My Blogs</h2>
+ <table id="blogs_list">
+ {% for blog in blogs %}
+ {% set others_blog_url = request.urlgen('mediagoblin.media_types.blog.blog_post_listing',
+ blog_slug=blog.slug, user=user.username) %}
+ {% set my_blog_url = request.urlgen('mediagoblin.media_types.blog.blog-dashboard',
+ blog_slug=blog.slug, user=request.user.username) %}
+ <tr>
+ {% if not request.user or request.user.username != user.username%}
+ <td><a href="{{ others_blog_url }}">{{ blog.title }}</a></td>
+ {% else %}
+ <td><a href="{{ my_blog_url }}">{{ blog.title }}</a></td>
+ {% endif %}
+ <td> </td>
+ <td><a class="button_action" href="{{ others_blog_url }}">{% trans %}View{% endtrans %}</a></td>
+ </tr>
+ {% endfor %}
</table>
- {% endfor %}
{% else %}
{% if request.user and request.user.username==user.username %}
<p>You have not created any blog yet.</p>
- {% set blog_create_url = request.urlgen('mediagoblin.media_types.blog.create',
- user=request.user.username) %}
- <a class="button_action" href="{{ blog_create_url }}">{% trans %}Create a Blog{% endtrans %}</a>
- {% else %}
+ {% else %}
<p>No blog has been created by <strong>{{ user.username }}</strong>yet.</p>
{% endif %}
{% endif %}
+ <br/>
+ <br/>
+ <br/>
+ {% if blogs.__len__() <max_blog_count and request.user and request.user.username==user.username %}
+ <a class="button_action" href="{{ blog_create_url }}">{% trans %}Create a Blog{% endtrans %}</a>
+ {% endif %}
{% endblock mediagoblin_content %}