Xuups
Get an account!     Login

Utilities

Main menu

Who's Online

29 user(s) are online (3 user(s) are browsing Forum)

Members: 0
Guests: 29

more...

Get Xoops

Support Xuups Project


Browsing this Thread:   1 Anonymous Users





Author avatar in smartsection
Moderator
Joined:
2008/6/2 19:00
Group:
Webmasters
Registered Users
Posts: 48
Offline
Hello,


How I can add avatar of author in article page inn smartsection module ?


Posted on: 2008/11/23 23:41
Transfer the post to other applications Transfer


Re: Author avatar in smartsection
Moderator
Joined:
2008/4/7 0:30
From Portugal
Group:
Webmasters
Registered Users
Posts: 303
Offline
Hi Mowaffak,
Thanks for posting your doubt here, Let´s see if I can help you 'bro'!

Open item.php and apply this at line 96:
// Populating the smarty variables with informations related to the selected item
$item $itemObj->toArray($item_page_id);
$item['who_when'] = $itemObj->getWhoAndWhen();

//Hack by trabis
$thisUser = new XoopsUser($itemObj->uid());
if (
is_object($thisUser)) {
    
$item['avatar'] = $thisUser->getVar('user_avatar');
}
//End of hack


Then you can modify the template smartsection_item.html and add:
<{if $item.avatar}>
<
img src="<{$xoops_url}>/uploads/<{$item.avatar}>" alt="" />
<{/if}>


I did not test this but I hope it works.
See ya!

Posted on: 2008/11/24 13:53
_________________
TDM
Transfer the post to other applications Transfer


Re: Author avatar in smartsection
Moderator
Joined:
2008/6/2 19:00
Group:
Webmasters
Registered Users
Posts: 48
Offline

Posted on: 2008/11/24 17:47
_________________
www.arabxoops.com
Transfer the post to other applications Transfer


Re: Author avatar in smartsection
Just popping in
Joined:
2014/10/13 7:17
From USA
Group:
Registered Users
Posts: 1
Offline
It is redirecting, I did not manage to do it 100% yet.

Posted on: 2014/10/13 7:27
Transfer the post to other applications Transfer






You can view topic.
You cannot start a new topic.
You cannot reply to posts.
You cannot edit your posts.
You cannot delete your posts.
You cannot add new polls.
You cannot vote in polls.
You cannot attach files to posts.
You cannot post without approval.

[Advanced Search]


 

Login

Username:

Password:

Remember me



Lost Password?

Register now!

Ajax Search


Advanced Search

Newest Posts