The forum of the forums
Would you like to react to this message? Create an account in a few clicks or log in to continue.

Recent topics appearance v.2

5 posters

Go down

In progress Recent topics appearance v.2

Post by Anzo October 15th 2014, 9:36 pm

Hello.

A while back, Ange gave me a code to customize the Latest Topics appearance, the topic is archived here: https://help.forumotion.com/t136001-recent-topics-appearance

I have a problem though that I only noticed now with members, and many have reported it as well. Whenever someone changes his/her Avatar (using either external URL or forumotion's upload) the image appears broken, just like here:

Recent topics appearance v.2 81xcApi

Is there any method to fix the images? Because whenever someone changes his/her avatar they experience this.

I tried clearing my browser's catch but It didn't work.

Thanks in advance.
Anzo
Anzo
Forumember

Posts : 365
Reputation : 8
Language : English/Arabic
Location : Baghdad - Iraq

http://www.duelacademy.net/forum

Back to top Go down

In progress Re: Recent topics appearance v.2

Post by _Twisted_Mods_ October 15th 2014, 9:42 pm

you will probably have to wait on ange for this sense she wrote the code she would know better then anyone
_Twisted_Mods_
_Twisted_Mods_
Helper
Helper

Male Posts : 2108
Reputation : 336
Language : English
Location : Ms

http://liquidcode.forumotion.com

Back to top Go down

In progress Re: Recent topics appearance v.2

Post by TheCrow October 15th 2014, 10:57 pm

Anzo wrote:Hello.

A while back, Ange gave me a code to customize the Latest Topics appearance, the topic is archived here: https://help.forumotion.com/t136001-recent-topics-appearance

I have a problem though that I only noticed now with members, and many have reported it as well. Whenever someone changes his/her Avatar (using either external URL or forumotion's upload) the image appears broken, just like here:

Recent topics appearance v.2 81xcApi

Is there any method to fix the images? Because whenever someone changes his/her avatar they experience this.

I tried clearing my browser's catch but It didn't work.

Thanks in advance.
Hello Anzo,

The recent topic avatars are a little bit complicated. I have something similar to my forum also and when someone changes his/her avatar image the image at the recent topic widget stays the same for like 24hours and then it changes. Except if i clear the cookies completely with codes and staff. With that after my login to the forum and as soon as i view one of the post provided in the recent topic widget, the avatars appear correctly. Maybe you are facing the same thing but with the difference of the broken image.
TheCrow
TheCrow
Manager
Manager

Male Posts : 6896
Reputation : 794
Language : Greek, English

https://forumote.forumotion.com

Back to top Go down

In progress Re: Recent topics appearance v.2

Post by Ange Tuteur October 15th 2014, 11:25 pm

Hello Anzo,

Your avatars appear as :
Recent topics appearance v.2 Captu183
Probably because you hide profiles from Guests. ^^

What type profile are you using : Advanced or Simple ?

Thanks
Ange Tuteur
Ange Tuteur
Forumaster

Male Posts : 13246
Reputation : 3000
Language : English & 日本語
Location : Pennsylvania

https://fmdesign.forumotion.com

Back to top Go down

In progress Re: Recent topics appearance v.2

Post by Anzo October 15th 2014, 11:32 pm

Avatars aren't hidden for guests though, I logged out to check and It's the same thing. Also, our profiles are the Advanced Type.
Anzo
Anzo
Forumember

Posts : 365
Reputation : 8
Language : English/Arabic
Location : Baghdad - Iraq

http://www.duelacademy.net/forum

Back to top Go down

In progress Re: Recent topics appearance v.2

Post by SLGray October 15th 2014, 11:34 pm

Clear your browser's cache.


Recent topics appearance v.2 Slgray10

When your topic has been solved, ensure you mark the topic solved.
Never post your email in public.
SLGray
SLGray
Administrator
Administrator

Male Posts : 51453
Reputation : 3519
Language : English
Location : United States

https://forumsclub.com/gc/128-link-directory/

Back to top Go down

In progress Re: Recent topics appearance v.2

Post by Ange Tuteur October 15th 2014, 11:37 pm

Anzo wrote:Avatars aren't hidden for guests though, I logged out to check and It's the same thing. Also, our profiles are the Advanced Type.
That's because they're cached for you. Wink

It could be a problem with where the images are hosted. What is the link of the broken images ?
Ange Tuteur
Ange Tuteur
Forumaster

Male Posts : 13246
Reputation : 3000
Language : English & 日本語
Location : Pennsylvania

https://fmdesign.forumotion.com

Back to top Go down

In progress Re: Recent topics appearance v.2

Post by Anzo October 15th 2014, 11:49 pm

I tried both ways. Whether it's an external link or directly uploaded from the profiles it's the same issue. Also @SLGray I've cleared my browser's catch before I opened this topic, nothing changed.
Anzo
Anzo
Forumember

Posts : 365
Reputation : 8
Language : English/Arabic
Location : Baghdad - Iraq

http://www.duelacademy.net/forum

Back to top Go down

In progress Re: Recent topics appearance v.2

Post by Ange Tuteur October 15th 2014, 11:54 pm

Try replace your script by :
Code:
$(function(){
 
      if(!window.localStorage) return;
 
      // Avatar por defecto
        var default_avatar= 'http://2img.net/i/fa/invision/pp-blank-thumb.png';
 
      // Tiempo de cache, aqui 24 h * 60 m * 60 s * 1000 ms entonces un día
        var caching_time= 24*60*60*1000;
 
      // Tiempo de cache de un error, ici 60 s * 1000 ms entonces un minuto
        var caching_error= 60*1000;
 
      var set_avatar= function(id) {
            $('.mini_ava2.member'+id).html('<img src="'+get_avatar(id)+'" />');
        };
 
      var get_avatar= function(id) {
            if(localStorage.getItem('t_ava'+id) < +new Date - caching_time || (localStorage.getItem('d_ava'+id)==default_avatar && localStorage.getItem('t_ava'+id) < +new Date - caching_error))
            {
                localStorage.setItem('d_ava'+id, default_avatar);
                $.get('/u'+id, function (d){
                    localStorage.setItem('t_ava'+id,+new Date);
                    localStorage.setItem('d_ava'+id, $('#profile-advanced-right .module:first div img:first,.forumline td.row1.gensmall:first > img, .frm-set.profile-view.left dd img,dl.left-box.details:first dd img, .row1 b .gen:first img, .real_avatar img',d).first().attr('src')||default_avatar);
                    set_avatar(id);
                });
            }
            return localStorage.getItem('d_ava'+id);
        };
 
      var to_replace= {};
 
  $('.topicRow').each(function(){
            to_replace[$(this).find('a[href^="/u"]').attr('href').substr(2)]= 1;
            $(this).find('a[href^="/u"]').before('<span class="mini_ava2 member'+$(this).find('a[href^="/u"]').attr('href').substr(2)+'"></span>');
        });
 
      for(i in to_replace)
        {
            set_avatar(i);
        };
 
  });

and then clear your cache so you can see if there are any changes.
Ange Tuteur
Ange Tuteur
Forumaster

Male Posts : 13246
Reputation : 3000
Language : English & 日本語
Location : Pennsylvania

https://fmdesign.forumotion.com

Back to top Go down

In progress Re: Recent topics appearance v.2

Post by Anzo October 16th 2014, 12:15 am

No changes. It actually looks way different now even.

Now the Images are only located before the 2nd line not before the entire area as It used to be.
Anzo
Anzo
Forumember

Posts : 365
Reputation : 8
Language : English/Arabic
Location : Baghdad - Iraq

http://www.duelacademy.net/forum

Back to top Go down

In progress Re: Recent topics appearance v.2

Post by TheCrow October 16th 2014, 12:19 am

Anzo wrote:No changes. It actually looks way different now even.

Now the Images are only located before the 2nd line not before the entire area as It used to be.

Ηello Anzo,

Forumotion experiences some problems with images. Now on my forum as well most of the images are displayed with the cracked icon also. Lets hope is not something important and it will be fixed soon!
TheCrow
TheCrow
Manager
Manager

Male Posts : 6896
Reputation : 794
Language : Greek, English

https://forumote.forumotion.com

Back to top Go down

In progress Re: Recent topics appearance v.2

Post by Anzo October 16th 2014, 12:21 am

Oh, so It's not from my forum's side?
Anzo
Anzo
Forumember

Posts : 365
Reputation : 8
Language : English/Arabic
Location : Baghdad - Iraq

http://www.duelacademy.net/forum

Back to top Go down

In progress Re: Recent topics appearance v.2

Post by TheCrow October 16th 2014, 12:22 am

I don't think so! Lets hope its this and nothing serious has happened!
TheCrow
TheCrow
Manager
Manager

Male Posts : 6896
Reputation : 794
Language : Greek, English

https://forumote.forumotion.com

Back to top Go down

In progress Re: Recent topics appearance v.2

Post by Anzo October 16th 2014, 12:26 am

I hope so.

I'll put back the old script, in case you check the forum @Ange
Anzo
Anzo
Forumember

Posts : 365
Reputation : 8
Language : English/Arabic
Location : Baghdad - Iraq

http://www.duelacademy.net/forum

Back to top Go down

In progress Re: Recent topics appearance v.2

Post by Ange Tuteur October 16th 2014, 4:47 am

It's okay to put the old script back. Wink

I noticed that some images are taking their time to load. Could be me though.
Ange Tuteur
Ange Tuteur
Forumaster

Male Posts : 13246
Reputation : 3000
Language : English & 日本語
Location : Pennsylvania

https://fmdesign.forumotion.com

Back to top Go down

Back to top

- Similar topics

 
Permissions in this forum:
You cannot reply to topics in this forum