Skip to Content Skip to Menu

Plugin Last views - image path

  • ddr2004
  • ddr2004
  • OFFLINE
  • Posts: 1
  • Thanks: 0
  • Karma: 0
18 years 3 months ago #19204 by ddr2004
Plugin Last views - image path was created by ddr2004
Hi,

Just wanna thanks first DJTrail for his plugin ;)


I have just a little problem >

When I select an avatar from CB gallery. It doesn't appear in Last view ;(

but the picture tnnophoto.jpg :pinch:

+++
thanks for your help
+++

Fan of Japan : www.horizonjapon.com

Fan of Webdesign : www.whoisddr.com

Fan of Joomla > Open Source Matters

Please Log in or Create an account to join the conversation.

  • trail
  • trail
  • OFFLINE
  • Posts: 232
  • Thanks: 21
  • Karma: 813
18 years 2 months ago #20173 by trail
Replied by trail on topic Re:Plugin Last views - image path
As far as i know there are no thumbnails of the gallery icons, showing the normal icons would give unpredicted results, hence it shows tnnophoto if no thumb is found, wich takes care of gallery photos in a predictable manner.

I never used the gallery on any of my sites, so i didn't think it was that important when i started this project.

I'll have to take a look and see what i can do to show a full size gallery image instead of tnnophoto for you.

DJ Trail.
CB Co-Founder & Test-Lead.
Plugins: My Age , Starsign Matchmaking Horoscope , My Visitor , My Highscores , My ProfileID ,
My Components: Import & Invite Karma Casino (Use Test / Test)
My Modules: Many :)

Please Log in or Create an account to join the conversation.

  • mischa
  • mischa
  • OFFLINE
  • Posts: 15
  • Thanks: 0
  • Karma: 7
18 years 2 months ago #20199 by mischa
Replied by mischa on topic Re:Plugin Last views - image path
Hi there Trail,


I can (and will) take a look at this tonight when I'm at home. I have mentioned this "issue" earlier here .

Rightnow I'm busy with adjusting/bug-fixing/adding feature's into GroupJive and this component had to problem too. Therefor I fixed it already so I post (maybe tonight) a little code-hack into this forum for the last views plugin for the people who wants to enable this...


Will be continued...:)


Greetz,


Mischa.

Projectmember of the BirthDays Module Project

Please Log in or Create an account to join the conversation.

  • mischa
  • mischa
  • OFFLINE
  • Posts: 15
  • Thanks: 0
  • Karma: 7
18 years 2 months ago #20215 by mischa
Replied by mischa on topic "Fixed": Plugin Last views - image path
Hi there again....


A little earlier then predicted (got home from work earlier :-)) but here I am again...


I "fixed" this "issue" rightnow. I just added some lines to the lastviews.php. Like Trail already mentioned beware of the sizes you make the gallery-images to "force" the output to be predictable. As far as I saw the default gallery-images are of a size of 48x48. I would advise not to use any bigger picture...


The lines I changed are 167-180. Note: I hacked this into v0.2.5prestab of the lastviews plugin. After hacking I discovered that we are arrived some versions later...:unsure: The lines will be the same I guess, but the linenumbers can be different... I will put the old and new code below...


From:
[code:1]
if ($lastview->avatar && $lastview->banned != '1' && $lastview->avatarapproved !='0') {
$testimage = "/images/comprofiler/tn$lastview->avatar";

if (file_exists($mosConfig_absolute_path.$testimage)) {
$image = $mosConfig_live_site.$testimage;
} else {
$testimage = "/components/com_comprofiler/plugin/language/$mosConfig_lang/images/tnnophoto.jpg";

if (file_exists($mosConfig_absolute_path.$testimage)) {
$image = $mosConfig_live_site.$testimage;
} else {
$image = "$mosConfig_live_site/components/com_comprofiler/plugin/language/default_language/images/tnnophoto.jpg";
}
}
[/code:1]

To:
[code:1]
if ($lastview->avatar && $lastview->banned != '1' && $lastview->avatarapproved !='0') {
$testimage = "/images/comprofiler/tn$lastview->avatar";
$galleryimage = "/images/comprofiler/$lastview->avatar";

if (file_exists($mosConfig_absolute_path.$testimage)) {
$image = $mosConfig_live_site.$testimage;
} else {
$testimage = "/components/com_comprofiler/plugin/language/$mosConfig_lang/images/tnnophoto.jpg";

if (file_exists($mosConfig_absolute_path.$testimage)) {
$image = $mosConfig_live_site.$testimage;

} else {
$image = "$mosConfig_live_site/components/com_comprofiler/plugin/language/default_language/images/tnnophoto.jpg";
}
}

if (file_exists($mosConfig_absolute_path.$galleryimage)) {
$image = $mosConfig_live_site.$galleryimage;
} else {
$galleryimage = "/components/com_comprofiler/plugin/language/$mosConfig_lang/images/tnnophoto.jpg";

if (file_exists($mosConfig_absolute_path.$galleryimage)) {
$image = $mosConfig_live_site.$galleryimage;

} else {
$image = "$mosConfig_live_site/components/com_comprofiler/plugin/language/default_language/images/tnnophoto.jpg";
}
}
[/code:1]



With this code included the lastviews.php also shows avatars for users that have gallery-images selected as their avatar...



I hope this is what ppl want...:P :P




Greetz,


Mischa.



Off-Topic:
I now see the reason of just looking at else's ppl's code... At some time you're beginning to understand it and see the logic of it all..... ;-) Rightnow I'm really starting to like it:ohmy: :laugh: :woohoo:

Post edited by: mischa, at: 2006/09/04 17:21

Projectmember of the BirthDays Module Project

Please Log in or Create an account to join the conversation.

  • trail
  • trail
  • OFFLINE
  • Posts: 232
  • Thanks: 21
  • Karma: 813
18 years 2 months ago #21115 by trail
Replied by trail on topic Re:"Fixed": Plugin Last views - image path
thanks, your modification will be seriously considered for the next version :)

DJ Trail.
CB Co-Founder & Test-Lead.
Plugins: My Age , Starsign Matchmaking Horoscope , My Visitor , My Highscores , My ProfileID ,
My Components: Import & Invite Karma Casino (Use Test / Test)
My Modules: Many :)

Please Log in or Create an account to join the conversation.

  • bertzki
  • bertzki
  • OFFLINE
  • Posts: 1
  • Thanks: 0
  • Karma: 0
17 years 1 month ago #46614 by bertzki
Replied by bertzki on topic Re:"Fixed": Plugin Last views - image path
hi trail how can i show their uploaded avatar

Please Log in or Create an account to join the conversation.

Moderators: beatnantkrileon
Powered by Kunena Forum