This topic contains 2 replies, has 2 voices, and was last updated by JustinJon3s 4 years, 2 months ago.
Viewing 3 posts - 1 through 3 (of 3 total)
Viewing 3 posts - 1 through 3 (of 3 total)
The topic ‘Peepso Avatars’ is closed to new replies.
Home › Forums › Product Support Forums › Ajax Search Pro for WordPress Support › Peepso Avatars
This topic contains 2 replies, has 2 voices, and was last updated by JustinJon3s 4 years, 2 months ago.
Do you have a way for peepso avatars to show up in search results? The settings are selected as per the documentation.
Hi,
I assume you are reffering to User results? In that case, there was a very similar issue, and it turned out that there was something with PeepSo not hooking to the correct function or something like that. You can check the whole discussion here.
Anyways, we managed to come up with a small custom code snippet that seemingly worked at the time, you can try that as well. Try adding this custom code to the functions.php in your theme/child theme directory. Before editing, please make sure to have a full site back-up just in case!
add_filter('asp_results', 'asp_peepso_avatar_fix', 10, 1);
function asp_peepso_avatar_fix($results) {
foreach ($results as &$r) {
if ( $r->content_type == 'user' ) {
$hash = get_user_meta($r->id, 'peepso_avatar_hash', true);
if ( !empty($hash) ) {
$r->image = get_site_url() . '/wp-content/peepso/users/' . $r->id . '/' . $hash . '-avatar-full.jpg';
}
}
}
return $results;
}
Best,Thank you! That worked!
The topic ‘Peepso Avatars’ is closed to new replies.
Cookie | Duration | Description |
---|---|---|
cookielawinfo-checkbox-analytics | 11 months | This cookie is set by GDPR Cookie Consent plugin. The cookie is used to store the user consent for the cookies in the category "Analytics". |
cookielawinfo-checkbox-functional | 11 months | The cookie is set by GDPR cookie consent to record the user consent for the cookies in the category "Functional". |
cookielawinfo-checkbox-necessary | 11 months | This cookie is set by GDPR Cookie Consent plugin. The cookies is used to store the user consent for the cookies in the category "Necessary". |
cookielawinfo-checkbox-others | 11 months | This cookie is set by GDPR Cookie Consent plugin. The cookie is used to store the user consent for the cookies in the category "Other. |
cookielawinfo-checkbox-performance | 11 months | This cookie is set by GDPR Cookie Consent plugin. The cookie is used to store the user consent for the cookies in the category "Performance". |
viewed_cookie_policy | 11 months | The cookie is set by the GDPR Cookie Consent plugin and is used to store whether or not user has consented to the use of cookies. It does not store any personal data. |