Small tweaks

pull/2/head
Noah 2014-06-24 18:59:00 +00:00
parent 200befc65f
commit 7e0fc42700
2 changed files with 8 additions and 4 deletions

View File

@ -14,11 +14,11 @@
<div class="blog-author"> <div class="blog-author">
{% if post["avatar"] %} {% if post["avatar"] %}
<img src="/static/avatars/{{ post['avatar'] }}"> <img src="/static/avatars/{{ post['avatar'] }}" alt="{{ post['profile']['name'] }}">
{% elif post["photo"] %} {% elif post["photo"] %}
<img src="{{ post['photo_url'] }}/{{ post['photo'] }}"> <img src="{{ post['photo_url'] }}/{{ post['photo'] }}" alt="{{ post['profile']['name'] }}">
{% else %} {% else %}
<img src="/static/avatars/default.png"> <img src="/static/avatars/default.png" alt="{{ post['profile']['name'] }}">
{% endif %} {% endif %}
<br> <br>

View File

@ -98,6 +98,10 @@ function RophakoUpload() {
window.location = data.msg; window.location = data.msg;
} }
}, },
error: function() {
window.alert("Upload error!");
$("#upload-button").removeAttr("disabled");
},
}); });
}; };
@ -188,4 +192,4 @@ function RophakoUpload() {
$(document).ready(function() { $(document).ready(function() {
new RophakoUpload().ready(); new RophakoUpload().ready();
}); });