Coding-Spot

You are not connected. Please login or register

 
 

[HELP] Avatar Before the Lastpost

Message (Page 1 of 1)


 
Advance Member

Posted on Fri May 03, 2013 2:18 pm

 
Is it possible to ad avatars in the in the Last post im a invision user?


Like this one



View user profile



 
Senior Member

Posted on Fri May 03, 2013 2:31 pm

 
i dont know if for invision

but if you use phpBB2, this :D
thanks to mr.mark :D:

Create new Javascript on JS Management, check to homepage only then add this:
Code:
    $(document).on('ready',function(){$('.forumline tr .row3.over').prepend('<div class="avatar-index"><div>');$('.forumline tr .row3.over .avatar-index').each(function(){var profileUser=$(this).parent().children('span').children('span').children('strong').children('a').attr('href');$(this).html('<a href="'+profileUser+'" class="avatar-index-enlace"><img src="http://illiweb.com/fa/invision/pp-blank-thumb.png" alt="No Avatar" /></a>');$(this).children('a').load(profileUser+' .forumline .row1.gensmall[align="center"]:eq(0) img:eq(0)')})});

Add this to your CSS:
Code:
    .avatar-index{
    float:left;
    }
    .avatar-index img{
    border:1px solid grey;
    margin: 5px;
    padding:1px;
    height:45px;
    width:45px;
    }

tadaaaa :D:



View user profile



 
Advance Member

Posted on Fri May 03, 2013 3:47 pm

 
hope mark can do for Invision :))



View user profile



 
Administrator
Administrator

Posted on Fri May 03, 2013 4:23 pm

 
Can you provide your forum url? Thanks :D:.



View user profile http://coding-spot.darkbb.com



 
Advance Member

Posted on Fri May 03, 2013 6:50 pm

 
here: http://speedoflight.fanbb.net/



View user profile



 
Administrator
Administrator

Posted on Fri May 03, 2013 7:15 pm

 
Invision is also hard for customization. xD.

Btw, Add this to your JS Management: (Homepage only)
Code:
$(document).ready(function () {
  $('.borderwrap table.ipbtable tbody tr td.row1 span').each(function(e) {
      var l = this.getElementsByTagName('strong')[0].firstChild.href;
      $(this).prepend('<span class="mark-invision-avatar" id="mark-invision-avatar'+e+'"></span>');
      $('#mark-invision-avatar'+e).load(l+' #profile-advanced-right img:eq(0)');
    });
});

And add this to your CSS:
Code:
.mark-invision-avatar {
  float: left;
}
.mark-invision-avatar img {
    border:1px solid grey;
    margin: 5px;
    padding:1px;
    height:45px;
    width:45px;
}

Tadaaaa :D:



View user profile http://coding-spot.darkbb.com



 
Advance Member

Posted on Sat May 04, 2013 1:33 am

 
It works but it shows only in the first category but the others none



View user profile



 
Administrator
Administrator

Posted on Sat May 04, 2013 1:37 am

 
Works fine on my test forum.
Can you activate my account that i created on your forum? So i can check it. Thanks! :):



View user profile http://coding-spot.darkbb.com



 
Advance Member

Posted on Sat May 04, 2013 1:41 am

 
oh you can activate it by email ^^

and when im in the homepage the toolbar disappear



View user profile



 
Administrator
Administrator

Posted on Sat May 04, 2013 1:48 am

 
I use a dummy email because i thought it didn't require activation, and my dummy email was hacked, i can't open it :(:.



View user profile http://coding-spot.darkbb.com



 
Advance Member

Posted on Sat May 04, 2013 1:49 am

 
i change it now ^^...No need activation hihi



View user profile



 
Administrator
Administrator

Posted on Sat May 04, 2013 2:07 am

 
What do you mean by you change it? :o:



View user profile http://coding-spot.darkbb.com



 
Advance Member

Posted on Sat May 04, 2013 2:09 am

 
the registration process no need to activation



View user profile



 
Administrator
Administrator

Posted on Sat May 04, 2013 2:27 am

 
Ok, can you put the codes again, so i can check it :):.



View user profile http://coding-spot.darkbb.com



 
Advance Member

Posted on Sat May 04, 2013 3:04 am

 
Code:
$(document).ready(function () {
  $('.borderwrap table.ipbtable tbody tr td.row1 span').each(function(e) {
      var l = this.getElementsByTagName('strong')[0].firstChild.href;
      $(this).prepend('<span class="mark-invision-avatar" id="mark-invision-avatar'+e+'"></span>');
      $('#mark-invision-avatar'+e).load(l+' #profile-advanced-right img:eq(0)');
    });
});

Code:
.mark-invision-avatar {
  float: left;
}
.mark-invision-avatar img {
    border:1px solid grey;
    margin: 5px;
    padding:1px;
    height:45px;
    width:45px;
}



View user profile



 
Administrator
Administrator

Posted on Sat May 04, 2013 3:06 am

 
No, i mean put the codes on your forum :):.

EDIT: Ok, try this one, replace the Javascript with this one:
Code:
$(document).ready(function () {
  $('.borderwrap table.ipbtable.index-box tbody tr td.row1 span').each(function(e) {
      var l = this.getElementsByTagName('strong')[0].firstChild.href;
      $(this).prepend('<span class="mark-invision-avatar" id="mark-invision-avatar'+e+'"></span>');
      $('#mark-invision-avatar'+e).load(l+' #profile-advanced-right img:eq(0)');
    });
});

:):



View user profile http://coding-spot.darkbb.com



 
Advance Member

Posted on Sat May 04, 2013 3:19 am

 
Still the first category only... and the toolbar disappear in the home page



View user profile



 
Administrator
Administrator

Posted on Sat May 04, 2013 3:22 am

 
Ok. To make this one work, you need first to create a topic on those forum that aren't posted yet.
This one: http://speedoflight.fanbb.net/f31-fan-account
and
This one: http://speedoflight.fanbb.net/f16-superior-subs

The toolbar will work also if you put some topics on those 2 forums. :):



View user profile http://coding-spot.darkbb.com



 
Advance Member

Posted on Sat May 04, 2013 3:40 am

 
it works !!! ^^ Thank you so much!!!!!!



View user profile



 
Administrator
Administrator

Posted on Sat May 04, 2013 3:43 am

 
Since the problem is solved, i'll locked this and move to archive section. :D:
~ Locked and Moved



View user profile http://coding-spot.darkbb.com


#21

Sponsored content


 

Posted Today at 11:49 am

 





Message (Page 1 of 1)

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

In total there is 0 user online :: 0 Registered, 0 Hidden and 0 Guests

Users browsing this forum: None