forum.coppermine-gallery.net

Support => cpg1.5.x Support => cpg1.5 plugins => Topic started by: chasfh on September 05, 2011, 08:35:45 pm

Title: Plugin request
Post by: chasfh on September 05, 2011, 08:35:45 pm
Not sure if I'm in the right place, but I need a plugin to allow users to set and display an avatar on gallery comments. It needs to automatically include the uploaded avatar picture..
I already have the bbcodes plugin, which you can use to insert an image in a comment, but it would really help if the image was automatically inserted for the user.

Any chance anyone can help with this please?
Title: Re: Plugin request
Post by: Αndré on September 05, 2011, 08:40:13 pm
Do you want to pay for this plugin? If so, we can move it to the freelancer board.
Title: Re: Plugin request
Post by: chasfh on September 06, 2011, 02:16:20 am
I'd actually be more interested if someone could point me in the right direction for doing it myself. I have installed the forum plugin, and that uses avatars for the posts, which are also recorded on the database.
The question I have, is where do I start? I'm fairly comfortable with php and a little javascript, but I can't work out exactly which files I need to edit, and how to get that avatar to show next to the comments. It seems like it should be easy.
Are there any good tutorials on editing the files and the structure of the gallery files?
Title: Re: Plugin request
Post by: Αndré on September 06, 2011, 10:09:09 am
It's not recommended to edit core files. Instead you should use the plugin or theme engine to add the avatar image.

The easiest way is probably the following. Copy the whole function theme_html_comments from the sample theme to your theme's theme.php file and add it to the content of $profile_lnk.
Title: Re: Plugin request
Post by: chasfh on September 06, 2011, 03:08:53 pm
Okay, thanks, a good place to start.
Can't seem to get the page to grab the avatar that's stored in the table though. Probably me being a muppet, as it will load if I reference it directly, but not if I use the user id to get the right one for each user...

I'm sure I'll figure it out though, thanks for the pointers!