Opened 5 years ago
Closed 5 years ago
#8600 closed defect (bug) (fixed)
Default gravatar is not shown in messages templates
| Reported by: | konnektiv | Owned by: | imath |
|---|---|---|---|
| Priority: | normal | Milestone: | 10.0.0 |
| Component: | Templates | Version: | |
| Severity: | normal | Keywords: | needs-patch |
| Cc: |
Description
The default gravatar option is not correctly used in messages templates. This is due to the fact that the URL is encoded like this:
www.gravatar.com/avatar/xxxx?s=28&r=g&d=mm
when it should be:
www.gravatar.com/avatar/xxxx?s=28&r=g&d=mm
This happens everywhere where the user avatar is added as backbone data e.g. here:
If I add a call to html_entity_decode before the esc_url call this fixes the problem for me. However we fix this with a workaround in our project using js like this:
$(document).ajaxComplete(function () {
$('img.avatar').each(function () {
this.src = this.src.replace(/#038;/g, '');
})
});
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)
Thanks for your report @konnektiv 👍. Looking at it asap.