Bug fixed, Profile picture

This commit is contained in:
dignajar 2015-12-01 22:32:55 -03:00
parent 940539c7f1
commit 97d4829a1d
2 changed files with 8 additions and 3 deletions

View File

@ -251,7 +251,7 @@ class HTML {
allcomplete: function(response) {
bar.css("width", "100%").text("100%");
progressbar.addClass("uk-hidden");
$("#jsprofilePicture").attr("src", "'.HTML_PATH_UPLOADS_PROFILES.$username.'.jpg?"+new Date().getTime());
$("#jsprofilePicture").html("<img class=\"uk-border-rounded\" src=\"'.HTML_PATH_UPLOADS_PROFILES.$username.'.jpg\">");
},
notallowed: function(file, settings) {
@ -269,4 +269,4 @@ class HTML {
echo $html;
}
}
}

View File

@ -97,13 +97,18 @@ HTML::formClose();
echo '</div>';
echo '<div class="uk-width-3-10" style="margin-top: 50px; text-align: center;">';
echo '<div id="jsprofilePicture">';
if(file_exists(PATH_UPLOADS_PROFILES.$_user['username'].'.jpg')) {
echo '<img id="jsprofilePicture" class="uk-border-rounded" src="'.HTML_PATH_UPLOADS_PROFILES.$_user['username'].'.jpg" alt="'.$L->g('Profile picture').'">';
echo '<img class="uk-border-rounded" src="'.HTML_PATH_UPLOADS_PROFILES.$_user['username'].'.jpg" alt="">';
}
else {
echo '<div class="uk-block uk-border-rounded uk-block-muted uk-block-large">'.$L->g('Profile picture').'</div>';
}
echo '</div>';
HTML::profileUploader($_user['username']);
echo '</div>';
echo '</div>';