Advanced search  

News:

cpg1.5.48 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter a recently discovered vulnerability. It is important that all users who run version cpg1.5.46 or older update to this latest version as soon as possible.
[more]

Pages: 1 [2] 3   Go Down

Author Topic: CopperRank - The First Ranking System For Coppermine.  (Read 81554 times)

0 Members and 1 Guest are viewing this topic.

just_some_guy

  • Supporter
  • Coppermine addict
  • ****
  • Offline Offline
  • Posts: 539
  • I am currently on holiday, back in a few weeks. :D
Re: CopperRank - The First Ranking System For Coppermine.
« Reply #20 on: May 19, 2008, 09:45:02 pm »

Switch debug mode on and post the proper error please.

Thanks,
Logged
Tambien, Hablo Espaņol      PHP - Achieve Anything
"The Internet is becoming the town square for the global village of tomorrow. " - Bill Gates
Windows 7 Forums

Halfhidden

  • Guest
Re: CopperRank - The First Ranking System For Coppermine.
« Reply #21 on: May 19, 2008, 09:50:49 pm »

Here it is:
While executing query "INSERT INTO cpg14x_config (name, value) VALUES ("rank1", "Newbie"), ("rank2", "Member"), ("rank_image1", "<img src=""plugins/CopperRank/images/rank1.jpg"" />"), ("rank_image2", "<img src=""plugins/CopperRank/images/rank2.jpg"" />"),("rank_image3", "<img src=""plugins/CopperRank/images/rank3.jpg"" />"), ("rank_image4", "<img src=""plugins/CopperRank/images/rank4.jpg"" />"), ("rank_image5", "<img src=""plugins/CopperRank/images/rank5.jpg"" />");" on 0

mySQL error: Duplicate entry 'rank1' for key 1

Hope this helps?
Logged

just_some_guy

  • Supporter
  • Coppermine addict
  • ****
  • Offline Offline
  • Posts: 539
  • I am currently on holiday, back in a few weeks. :D
Re: CopperRank - The First Ranking System For Coppermine.
« Reply #22 on: May 19, 2008, 09:54:18 pm »

Delete all the News Bulletin rows from the cpg14x_config table: rank1, rank2 etc. and rank_image1, rank_image2 .... etc., rank_value1, rank_value2 etc...

Logged
Tambien, Hablo Espaņol      PHP - Achieve Anything
"The Internet is becoming the town square for the global village of tomorrow. " - Bill Gates
Windows 7 Forums

Halfhidden

  • Guest
Re: CopperRank - The First Ranking System For Coppermine.
« Reply #23 on: May 19, 2008, 10:26:50 pm »

Yep that did the trick...Thanks for your help and speedy reply :) I really appreciate it. I got the plugin installed and yet have to edit the profile.php file, that should be ok. Sorry for the delay in answering but my ftp client maxed out on connections and the server booted me off for a short while.
I'll have a go at re installing multi anycontent and try to track down the rough line. But I'm happy to accommodate the shout box elsewhere anyway.
Again, thanks
Regards,
Steff
Logged

just_some_guy

  • Supporter
  • Coppermine addict
  • ****
  • Offline Offline
  • Posts: 539
  • I am currently on holiday, back in a few weeks. :D
Re: CopperRank - The First Ranking System For Coppermine.
« Reply #24 on: May 19, 2008, 10:33:24 pm »

Glad to hear its fixed, sorry about that.
Logged
Tambien, Hablo Espaņol      PHP - Achieve Anything
"The Internet is becoming the town square for the global village of tomorrow. " - Bill Gates
Windows 7 Forums

Halfhidden

  • Guest
Re: CopperRank - The First Ranking System For Coppermine.
« Reply #25 on: May 19, 2008, 10:48:22 pm »

Ah! I'v got a new problem with the profile.php
I got this error: Parse error: syntax error, unexpected $end in /home/picturez/public_html/profile.php on line 620

here is the last couple of lines on the config.php file

} elseif ($rank > $over) {
    echo "{$CONFIG['rank5']}";
    echo "{$CONFIG['rank_image5']}";
   
} else {
    echo "No Rank?";
}
echo '</td>';
echo '</tr>';

endtable();
echo '<div align="center">CopperRank by <a href="http://www.mysimtractor.com"> just_some_guy </a></div>';
?>


Have I pasted this wrong?
I'm having a thick week I think... I really apologise for this, but it promises to be such a good plugin for the site. I don't normally have such problems.
Regards,
Steff
Logged

just_some_guy

  • Supporter
  • Coppermine addict
  • ****
  • Offline Offline
  • Posts: 539
  • I am currently on holiday, back in a few weeks. :D
Re: CopperRank - The First Ranking System For Coppermine.
« Reply #26 on: May 19, 2008, 10:53:20 pm »

If you followed the instructions correctly then this error should not occur, re upload the original profile.php and try again, i cant tell what the problem is because you only posted a small section of the code. If the error still occurs i will check it out in more detail as im not sure if there has been any changes to profile.php in recent versions.
Logged
Tambien, Hablo Espaņol      PHP - Achieve Anything
"The Internet is becoming the town square for the global village of tomorrow. " - Bill Gates
Windows 7 Forums

Nibbler

  • Guest
Re: CopperRank - The First Ranking System For Coppermine.
« Reply #27 on: May 19, 2008, 10:57:07 pm »

I'd like to suggest that you change the way you are counting files here:

Code: [Select]
$result = mysql_query("SELECT * FROM {$CONFIG['TABLE_PICTURES']} WHERE owner_id = $uid ");
$rank = mysql_num_rows($result);

to

Code: [Select]
$result = cpg_db_query("SELECT COUNT(*) FROM {$CONFIG['TABLE_PICTURES']} WHERE owner_id = $uid ");
list($rank) = mysql_fetch_row($result);

That will give you better bridge compatibility and is much more efficient.
Logged

Halfhidden

  • Guest
Re: CopperRank - The First Ranking System For Coppermine.
« Reply #28 on: May 19, 2008, 11:02:07 pm »

Yes I uploaded the backup copy of the file and the gallery returned to normal (as expected). I have other mods, but none have edited profile.php that I remember. The error line 620 is the last line in the profile.php file ( ?> ) I have tried a couple of times since and get the same result.
Sorry to be a pain.

Regards,
Steff
Logged

Nibbler

  • Guest
Re: CopperRank - The First Ranking System For Coppermine.
« Reply #29 on: May 19, 2008, 11:07:16 pm »

@Halfhidden: Attach the complete file.

@just_some_guy: Also, you should probably fix this:

Code: [Select]
if (file_exists("plugins/meta_data/langs/{$CONFIG['lang']}.php")) {
  require "plugins/meta_data/langs/{$CONFIG['lang']}.php";
} else {require "plugins/CopperRank/langs/english.php";}
Logged

Halfhidden

  • Guest
Re: CopperRank - The First Ranking System For Coppermine.
« Reply #30 on: May 19, 2008, 11:14:10 pm »

Here is the complete edited profile.php
Thanks for your help.

Regards,
Steff


Logged

just_some_guy

  • Supporter
  • Coppermine addict
  • ****
  • Offline Offline
  • Posts: 539
  • I am currently on holiday, back in a few weeks. :D
Re: CopperRank - The First Ranking System For Coppermine.
« Reply #31 on: May 19, 2008, 11:14:43 pm »

@Nibbler - Thanks for the bug reports, i have uploaded a new version.

@Halfhidden - I just installed the plugin to my cpg1418 test bed and it works as expected.

Replace the contents of profile.php with the attahed file.

Logged
Tambien, Hablo Espaņol      PHP - Achieve Anything
"The Internet is becoming the town square for the global village of tomorrow. " - Bill Gates
Windows 7 Forums

Halfhidden

  • Guest
Re: CopperRank - The First Ranking System For Coppermine.
« Reply #32 on: May 19, 2008, 11:21:01 pm »

@just_some_guy: That worked, thanks Had I done something wrong? I do have my moments and have been known to be as thick as two short planks.

@Nibbler: thanks for your help once again.

Regards,
Steff

Logged

Nibbler

  • Guest
Re: CopperRank - The First Ranking System For Coppermine.
« Reply #33 on: May 19, 2008, 11:30:44 pm »

You'd cut off the end of the file. The new code replaces just the endtable() but you removed everything from the endtable() to the end of the file. You need to mod the file anyway since just_some_guy's copy doesn't have the modpack stuff in that you are using.
Logged

Halfhidden

  • Guest
Re: CopperRank - The First Ranking System For Coppermine.
« Reply #34 on: May 19, 2008, 11:36:24 pm »

Aah!
I'm not normally that messy! Sorry guys.... I certainly don't want to increase your workload on unnecessary posts. I'll do my best to check over what I've done a couple of times before I post next time.

I really do appriciate all your help.

Regards,
Steff
Logged

MadMaxx

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 23
Re: CopperRank - The First Ranking System For Coppermine.
« Reply #35 on: July 08, 2008, 03:00:19 am »

thanks just_some_guy, works great  :)

may i suggest you had 2 special ranks not determined by uploads, like one for the site owner/admin and one for the moderators for example.

would make it even better  ;D
Logged

banghatta

  • Coppermine newbie
  • Offline Offline
  • Posts: 6
Re: CopperRank - The First Ranking System For Coppermine.
« Reply #36 on: July 19, 2008, 10:51:35 am »

I've installed copperrank V.2. Modify profile.php. but nothing happen.
The ranking not shown at member profile. How to enable copperank plugin?

I use CPG 1.4.18 bridge with Phpbb3.
here my website:  www.bniper.net


Logged

stardust

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 44
Re: CopperRank - The First Ranking System For Coppermine.
« Reply #37 on: July 20, 2008, 06:49:33 am »

Great plugin. I'm wondering is there a way to rank users on # of comments they have posted instead of # of images uploaded? (for galleries who don't give access for all users to upload images)
Logged

Nibbler

  • Guest
Re: CopperRank - The First Ranking System For Coppermine.
« Reply #38 on: July 20, 2008, 02:06:48 pm »

Just change

Code: [Select]
$result = cpg_db_query("SELECT COUNT(*) FROM {$CONFIG['TABLE_PICTURES']} WHERE owner_id = $uid ");
to

Code: [Select]
$result = cpg_db_query("SELECT COUNT(*) FROM {$CONFIG['TABLE_COMMENTS']} WHERE author_id = $uid ");
Logged

.JRauck

  • Coppermine newbie
  • Offline Offline
  • Posts: 6
Re: CopperRank - The First Ranking System For Coppermine.
« Reply #39 on: August 28, 2008, 07:37:04 am »

I got a noobie question on installing it. What do I do if I already have the same name of a file such as the init.inc?
Logged
Pages: 1 [2] 3   Go Up
 

Page created in 0.023 seconds with 20 queries.