Karma Description Mod

Started by Grek.Kamchatka, September 11, 2005, 11:48:26 PM

Previous topic - Next topic

gerrymore

SleePy, if you want your code tested on my test site, I'll certainly give it a try for you. (RC1 upgraded to RC2)
SMF RC1, Tiny Portal 0.75, Coppermine 1.3.3, Flashchat.

URPG

Hi there!

I am looking for a way to show karma in a bar diagram. More karma = longer bar
could look like those access stats but i got no idea how to integrate that into SMF. Can you add this potion to your mod?

Grek.Kamchatka

Hi all! I just made a new version of my mod. It's work only with 11RC2>> with default theme. But, i want to add some new functions in it. Can you wait for some time?

URPG


Grek.Kamchatka

KDM ver. 1.9.3 now available. No new functions, just compatibility with RC2 and latest reliese candidate.

URPG, what bars?

gerrymore

Hundreds of errors coming up on the RC2 version (20 pages in 5 minutes). They are showing on most templates in the error log. One below:

8: Use of undefined constant karma_stat - assumed 'karma_stat'
File: /././././smf/Themes/default/Post.template.php (eval?)
Line: 517
SMF RC1, Tiny Portal 0.75, Coppermine 1.3.3, Flashchat.

URPG

Just turn one page back to <11> and you will see ;)

I was talking about replacing / optionaly replacing the karma display from numbers into karma-bars even gave an example how to do it in php (not my example, an example, i could not do it)

Grek.Kamchatka

Hi, gerrymore. First of all, my mod don't do anything with this file (Post.template.php) and  i haven't this error on fresh install of my forum. But you can find

karma_stat

and replace it with this

'karma_stat'

SleePy

Quote from: gerrymore on January 14, 2006, 03:14:47 PM
SleePy, if you want your code tested on my test site, I'll certainly give it a try for you. (RC1 upgraded to RC2)

yea just 2 days ago i upgraded my main site and well the fixed version of the karma description mod i had worked prefect. only 1 minor error but i think that is the package manger error. because everything i installed though package manger seems to act like it was double installed...  :o
Jeremy D ~ Site Team / SMF Developer ~ GitHub Profile ~ Join us on IRC @ Libera.chat/#smf ~ Support the SMF Support team!

Chronic667

Hi, i'm having a problem installing this mod, and getting it to work.

I'm using SMF version 1.1 RC2 but when i come to enable it, i get a warning on "BoardIndex.template.php". I am using the RC2 default theme so i've no clue why that is happening.

If i install the mod anyway and then change apply the changes myself to BoardIndex.template.php. Things seem fine until i click on a Karma link such as the one in my profile. I then get this error on my local smf forum (used for testing upgrades and mods).

QuoteUnknown column 'lk.link' in 'field list'
File: c:\phpdev\www\public\smf2\Sources\Viewkarma.php
Line: 175

I also get this error when testing the mod on my live forum which was upgraded from 1.0.5 beta 3 public > RC1 > RC2.

Can anyone help me fix this problem?

ivogomes

I'm using it on RC2 and had to change the boardindex.template.php by hand because the package has a few extra spaces...

Everything is working fine!
SMF Portuguese Translator
SMF 2.0 (100% translated)

http://www.ivogomes.com
http://www.portaldascuriosidades.com

gerrymore

Quote from: Grek_Kamchatka on January 17, 2006, 07:17:27 PM
Hi, gerrymore. First of all, my mod don't do anything with this file (Post.template.php) and  i haven't this error on fresh install of my forum. But you can find

karma_stat

and replace it with this

'karma_stat'


I have this already in index.english.php

'karma_stat'


These are 30 seconds worth of errors. This was on a clean install, with no mods. boardindex.template failed during the install, but changed by hand. Hope this helps you find this bug.


http://www.*****.co.uk/smf/index.php?action=admin
Apply Filter: Only show the errors with the same message
8: Use of undefined constant karma_stat - assumed 'karma_stat'
File: /./././././smf/Themes/default/Admin.template.php (eval?)
Line: 517

http://www.*****.co.uk/smf/index.php
Apply Filter: Only show the errors with the same message
8: Use of undefined constant karma_stat - assumed 'karma_stat'
File: /./././././smf/Themes/default/BoardIndex.template.php (eval?)
Line: 517

http://www.*****.co.uk/smf/index.php
Apply Filter: Only show the errors with the same message
8: Use of undefined constant karma_stat - assumed 'karma_stat'
File: /./././././smf/Themes/default/BoardIndex.template.php (eval?)
Line: 517

http://www.*****.co.uk/smf/index.php
Apply Filter: Only show the errors with the same message
8: Use of undefined constant karma_stat - assumed 'karma_stat'
File: /./././././smf/Themes/default/Display.template.php (eval?)
Line: 517

http://www.*****.co.uk/smf/index.php
Apply Filter: Only show the errors with the same message
8: Use of undefined constant karma_stat - assumed 'karma_stat'
File: /./././././smf/Themes/default/Display.template.php (eval?)
Line: 517

http://www.*****.co.uk/smf/index.php
Apply Filter: Only show the errors with the same message
8: Use of undefined constant karma_stat - assumed 'karma_stat'
File: /./././././smf/Themes/default/MessageIndex.template.php (eval?)
Line: 517

http://www.*****.co.uk/smf/index.php
Apply Filter: Only show the errors with the same message
8: Use of undefined constant karma_stat - assumed 'karma_stat'
File: /./././././smf/Themes/default/BoardIndex.template.php (eval?)
Line: 517

http://www.*****.co.uk/smf/index.php
Apply Filter: Only show the errors with the same message
8: Use of undefined constant karma_stat - assumed 'karma_stat'
File: /./././././smf/Themes/default/MessageIndex.template.php (eval?)
Line: 517

http://www.*****.co.uk/smf/index.php
Apply Filter: Only show the errors with the same message
8: Use of undefined constant karma_stat - assumed 'karma_stat'
File: /./././././smf/Themes/default/BoardIndex.template.php (eval?)
Line: 517

http://www.*****.co.uk/smf/index.php?action=viewkarma
Apply Filter: Only show the errors with the same message
8: Use of undefined constant karma_stat - assumed 'karma_stat'
File: /./././././smf/Themes/default/Viewkarma.template.php (eval?)
Line: 517

http://www.*****.co.uk/smf/index.php
Apply Filter: Only show the errors with the same message
8: Use of undefined constant karma_stat - assumed 'karma_stat'
File: /./././././smf/Themes/default/BoardIndex.template.php (eval?)
Line: 517

http://www.*****.co.uk/smf/index.php?action=viewErrorLog;desc
Apply Filter: Only show the errors with the same message
8: Use of undefined constant karma_stat - assumed 'karma_stat'
File: /./././././smf/Themes/default/Errors.template.php (eval?)
Line: 517


SMF RC1, Tiny Portal 0.75, Coppermine 1.3.3, Flashchat.

Grek.Kamchatka

What mod version do you use?

Chronic667

um, wern't sure who you were asking there, but i use 1.9.3

gerrymore

SMF RC1, Tiny Portal 0.75, Coppermine 1.3.3, Flashchat.

spicyjoe

hey, i got an error:

1. Execute Modification ./Sources/Admin.php Test successful
2. Execute Modification ./Sources/Karma.php Test successful
3. Execute Modification ./Sources/ModSettings.php Test successful
4. Execute Modification ./Sources/BoardIndex.php Test successful
5. Execute Modification ./Sources/Profile.php Test successful
6. Execute Modification ./Sources/ManagePermissions.php Test successful
7. Execute Modification ./Themes/default/Admin.template.php Test successful
8. Execute Modification ./Themes/default/BoardIndex.template.php Test failed
9. Execute Modification ./Themes/default/Profile.template.php Test successful
10. Execute Modification ./Themes/default/languages/Admin.english.php Test successful
11. Execute Modification ./Themes/default/languages/ModSettings.english.php Test successful
12. Execute Modification ./Themes/default/languages/Who.english.php Test successful
13. Execute Modification ./Themes/default/languages/Help.english.php Test successful
14. Execute Modification ./Themes/default/languages/index.english.php Test successful
15. Execute Modification ./Themes/default/languages/ManagePermissions.english.php Test successful
16. Execute Modification ./Themes/default/languages/Errors.english.php Test successful
17. Execute Modification ./Themes/default/languages/Profile.english.php Test successful
18. Execute Modification ./index.php Test successful
19. Execute Code db_change.php
20. Extract File ./Sources/Viewkarma.php
21. Extract File ./Themes/default/Viewkarma.template.php
22. Extract File ./Themes/default/DescriptionKarma.template.php


it says 8.   Execute Modification   ./Themes/default/BoardIndex.template.php Test failed... :( anyone can help?

L0relei

The question has been asked many times in this topic...
Change the BoardIndex.template.php by hand.
Just Lo` It

spicyjoe

#177
oh! wahahah! but then how do i see what code to add or replace? i dunno how to work with SMF mods since i was using IPB and phpBB last time... :(... anyone can help? thanks

Grek.Kamchatka

spicyjoeб see Karma_Description_Mod.xml

spicyjoe

<?xml version="1.0"?>
<!DOCTYPE modification SYSTEM "http://www.simplemachines.org/xml/modification">
<modification xmlns="http://www.simplemachines.org/xml/modification" xmlns:smf="http://www.simplemachines.org/">
<id>IvanV.PetrovichAkaGrek:KarmaDescriptionMod</id>
<version>1.9.3</version>
<file name="$sourcedir/Admin.php">
<operation>
<search position="replace"><![CDATA[// Clear out the karma actions.
db_query("
DELETE FROM {$db_prefix}log_karma", __FILE__, __LINE__);
]]></search>
<add><![CDATA[/* Clear out the karma actions.
db_query("
DELETE FROM {$db_prefix}log_karma", __FILE__, __LINE__); */

]]></add>
</operation>
<operation>
<search position="before"><![CDATA[</body></html>';
obExit(false);
}


ok i took one part of the code... i understand abit but not all.... i know this part:

]]></search>
<add><![CDATA[/* Clear out the karma actions.
db_query("
DELETE FROM {$db_prefix}log_karma", __FILE__, __LINE__); */

]]></add>
</operation>
<operation>
<search position="before"><![CDATA[</body></html>';
obExit(false);
}


that code means i have to search for the code add it but on top or bottom or replace it?

then what this code for?:

<?xml version="1.0"?>
<!DOCTYPE modification SYSTEM "http://www.simplemachines.org/xml/modification">
<modification xmlns="http://www.simplemachines.org/xml/modification" xmlns:smf="http://www.simplemachines.org/">
<id>IvanV.PetrovichAkaGrek:KarmaDescriptionMod</id>
<version>1.9.3</version>
<file name="$sourcedir/Admin.php">
<operation>
<search position="replace"><![CDATA[// Clear out the karma actions.
db_query("
DELETE FROM {$db_prefix}log_karma", __FILE__, __LINE__);

Advertisement: