This topic is locked

Display logo in list view of different table

12/19/2014 8:14:37 AM
PHPRunner General questions
P
pelican author

Hi

Can anyone help please I am new to PHPrunner and Php.

I have a logo/avatar in my user table, and I would like to display it on a list view of user comments table at the side of the appropriate user name. But I cannot fine anything to help do this.
Many thanks

admin 12/19/2014

How's about setting 'View as' type of this field to 'Image'?

P
pelican author 12/19/2014



How's about setting 'View as' type of this field to 'Image'?


I have added a new field to the comments table and made this image, in property's gone to copy settings and set this to the user table and the avatar field. but nothing is displayed so i must be doing something wrong or missed something.
Thanks

admin 12/19/2014

You cannot copy settings from another table field.
If I understand your question right - modify SQL query of comments table to join image field from users/profile table. Then set 'View as' type of this image field to 'Image'. No coding is required.
Sample SQL query:

select id, comment, userid, users.image

from comments

inner join users on comemnts.userid=users.id