Gravatar is retina ready

Gravatars are still broken in XF and elsewhere. I had to disable it on a few sites since they still serve up stale Gravatars, unless you call it with a unique URL.

I see my Gravatar here is months out of date now...still...the Automattic team needs to fix this.

I'm leaving a complaint on that very blog post, in fact...
 
Gravatars are still broken in XF and elsewhere. I had to disable it on a few sites since they still serve up stale Gravatars, unless you call it with a unique URL.

I see my Gravatar here is months out of date now...still...the Automattic team needs to fix this.

I'm leaving a complaint on that very blog post, in fact...
i didnt see any comment
 
It goes into a moderation queue. And since it was a complaint of sorts, I bet it never will get published.
Are Gravatar adverse to any form of constructive criticism?

I don't have them enabled on my forum, but that is more a personal preference, I didn't know there was a technical glitch with the system.
 
I don't have them enabled on my forum, but that is more a personal preference, I didn't know there was a technical glitch with the system.
The avatars are cached and does not update unless you call it from a different URL, so it never updates. I got so many complaints from my users about their gravatars not updating, and somehow I was being blamed, so I just removed the functionality all together.
 
The avatars are cached and does not update unless you call it from a different URL, so it never updates.
That's not exactly a good behavior on their part, I agree. I did modify my one XF installation to add a random code to create a new URL each time, but like Mike said in the other thread, that is wasteful on resources. And XF has no way of guessing when you change your Gravatar.

Are Gravatar adverse to any form of constructive criticism?
I need to look back--I think I actually got a reply, but have been so busy that I never had time to follow up.

I just wish they'd fix it. My Gravatar here is woefully out of date...proof it's still broken. (I have an Acura now, so... :D )
 
Yep, got a reply (it just took a bit of time--no biggie), and I was given instructions to contact support. So, I've contacted one of their "Happiness Engineers" to get some...ummm...happiness. ;)
 
I mucked around with this a bit... it doesn't seem to be terribly difficult to support. Although it does require a file edit on XenForo_Model_Avatar... Just need to double the sizes in the "protected static $_sizes" method like so:

PHP:
 protected static $_sizes = array(
'l' => 384,
'm' => 192,
's' => 96,
);

You can't extend that without using late static binding (which was only added to PHP 5.3.0, and since XF's minimum system requirements are 5.2.4, there's no way they could change the code to support it without upping the minimum system requirements for PHP).

And then add a little CSS (I added it to my EXTRA.css template):

Code:
.avatar .img.s { background-size: 48px;}
.avatar .img.m { background-size: 96px;  }
.avatar .img.l { background-size: 192px; }
.visitorPanel .avatar img,
.memberCard .avatar img {zoom: 0.5};

I haven't extensively tested it, but do far, I haven't run into any noticeable issues.

Essentially you are doubling the vertical and horizontal size of the avatars, but then scaling them back down 50%.

If you wanted to get tricky, you could apply the changes only based on the user agent (something that supports retina displays).

The first image is the default way XF shows avatars (1:1 pixel ratio)... the second image is how it shows after the above change on an iPhone (you can zoom even further before it starts pixelating)...

IMG_0684.webp


IMG_0685.webp
 
php 5.5 is already in development

They should up the requirement in the next release to php 5.4

I understand the need for some legacy support, but that is also the problem with other forum developments. They hold onto the past for to long and thus other contents pass them.

It's one of the draw backs of forums. Even WordPress is moving forward... WordPress 4 (could change to 3.x, but most likely v4) will accept php 5.4 as a default.
 
I mucked around with this a bit... it doesn't seem to be terribly difficult to support. Although it does require a file edit on XenForo_Model_Avatar... Just need to double the sizes in the "protected static $_sizes" method like so:

PHP:
 protected static $_sizes = array(
'l' => 384,
'm' => 192,
's' => 96,
);
There should be no , after 96
 
I mucked around with this a bit... it doesn't seem to be terribly difficult to support. Although it does require a file edit on XenForo_Model_Avatar... Just need to double the sizes in the "protected static $_sizes" method like so:
This does not apply to avatars already uploaded?
The existing avatars show appears in the top left 1/4 when you click on the member cards.
 
It turns out the above CSS works on everything except Firefox (it doesn't support zoom, but IE, Safari, Chrome and Opera all do). Which really sucks. :)
I swear if it's not one thing, it's something else... I redid the main XenForo UI sprite to be twice the size for retina displays... Since Firefox doesn't support zoom, I decided I would just embed the PNG within a SVG since you cant apply scaling to the embedded image... So it worked well in Firefox (no need to use CSS zoom). Unfortunately there's a bug in WebKit (so Safari and Chrome) that doesn't allow SVG to display an embedded image if the SVG is part of a web page (works fine when viewing the image alone in Chrome/Safari). lol... dumbest crap ever...

There should be no , after 96
Actually doesn't matter either way. :)
 
I swear if it's not one thing, it's something else... I redid the main XenForo UI sprite to be twice the size for retina displays... Since Firefox doesn't support zoom, I decided I would just embed the PNG within a SVG since you cant apply scaling to the embedded image... So it worked well in Firefox (no need to use CSS zoom). Unfortunately there's a bug in WebKit (so Safari and Chrome) that doesn't allow SVG to display an embedded image if the SVG is part of a web page (works fine when viewing the image alone in Chrome/Safari). lol... dumbest crap ever...

Actually doesn't matter either way. :)
As a developer/designer, I am in favor of the world adapting ONE browser. All these browsers try to be cute and add things that the others don't have or tweak something in a special way, it really bothers me. Maybe not one browser but some sort of better "Common Ground" between browsers because the so called Web Standard for Browsers are a joke, it is a hassle to get something to work in IE then have it break in Chrome, or firefox and vice versa.
 
Top Bottom