PDA

View Full Version : Show user profile avatar



dneven
15-11-2016, 12:55 PM
When my users register on my site they can upload an avatar. Is it possible when clicking on standings and then the clicking on user predictions, when show his predictions to show also his avatar pic? May be by adding some string code somewhere ?

kostas
16-11-2016, 09:57 AM
Hello,

To show the avatar in the user prediction page you will have to add your code into the following pages,

<joomla directory>/components/com_multileague/models/playerhistory.php (add here the code to retrieve the image if necessary ,you could inject a part of code into the getUserHistory function or simply you could use the function from your custom avatar extension to retrieve the avatar , based by user_id)

<joomla directory>/components/com_multileague/views/playerhistory/view.html.php (add here the code for the call of the function to retrieve the avatar , if you altered the code of the function getUserHistory skip that part)

<joomla directory/components/com_multileague/views/playerhistory/tmpl/default.php (add to the desired place the code to print the avatar)


note! we do not know what solution you have installed to give the ability to users to add avatar so we could not give precise instractions.

Hope this information will help you,
Best Regards.

dneven
17-11-2016, 02:15 PM
Im' using default registration form of joomla 3.6.0 which include avatar in registration form. I don't know what exactly is the code to inject