Karma Description Mod

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

Previous topic - Next topic

Grek.Kamchatka


pheadrus

Sorry guy  :-[ but as you see, your mod is one of the tops and your thread here at smf-forum is getting larger and larger, so trying (or searching with smf search function) is a time-killer action. I found the solution myself and wanted to share with others.

You said that you told it many times, but why not changing the package content  ???

PS:I can delete my post if you want or you can delete it; no problem for me


Grek.Kamchatka

Quote from: pheadrus on January 15, 2007, 06:36:18 AM
Sorry guy  :-[ but as you see, your mod is one of the tops and your thread here at smf-forum is getting larger and larger, so trying (or searching with smf search function) is a time-killer action. I found the solution myself and wanted to share with others.

You said that you told it many times, but why not changing the package content  ???

PS:I can delete my post if you want or you can delete it; no problem for me
Hi, pheadrus. I didn't wish you to offend. Very well that you have repeated this information, but iI can't change a content the mod, because a problem in a modinstaller (forum engine).

pheadrus

Understood  :-[

Thanx again for this great tool  :) My forum's users love it   ;D


ThK

Thx for the Mod. After applying the database-patch it seems to work quite well, except that an update clears the karma-log.

As I had to translate it anyway, I packaged the translation into a mod. Maybe, someone finds it usefull.

Cheers, ThK

chemb0t

#525
Quote from: eNoyx on January 02, 2007, 01:23:05 PM
Hi, first, thanks for this mod. It's a great tool to manage your users and reward/smite them.

I'm trying to install it, but this error appears when I try to see the Karma log anywhere (from the stats box, from the user's profile...)

/database error/
Unknown column 'lk.Description' in 'field list'
File: <root path to the forums; edited>/Sources/Viewkarma.php
Line: 309


Hi there, I am getting the same error except it points to line 91
LIMIT $context[start], $modSettings[karmamaxmembers]", __FILE__, __LINE__);

I heard there was a database-patch? Does anyone know if it would fix this problem?
Thanks in advance! Wonderful mod by the way! 

EDIT: Ah, nevermind! I solved the problem. Apparently the mod does not automatically make the "Description" and "link" fields in SMF_log_Karma so I had to do that manually. Both should be "text" type and no default should be set.

Svatov

The mod works well, but i have some questions. When i looked into the Karma_Description_Mod.xml  I found this code
<search position="after"><![CDATA[</table>
</td>
</tr>';

// Show the standard "Save Settings" profile button.
]]></search>
<add><![CDATA[
';
//Karma Description Mod (Notification)
if (!empty($modSettings['karmadescmod']) && !empty($modSettings['karmanotifier']))
echo '
<tr>
<td colspan="2"><label for="enable_notify">', $txt['enable_notify'], '</label>
<select name="default_options[enable_notify]" id="none_notifier">
<option value="0"', empty($context['member']['options']['enable_notify']) ? ' selected="selected"' : '', '>', $txt['enable_notify_none'], '</option>
<option value="1"', !empty($context['member']['options']['enable_notify']) && $context['member']['options']['enable_notify'] == 1 ? ' selected="selected"' : '', '>', $txt['enable_notify_popup'], '</option>
<option value="2"', !empty($context['member']['options']['enable_notify']) && $context['member']['options']['enable_notify'] !=1 ? ' selected="selected"' : '', '>', $txt['enable_notify_pm'], '</option>
</select>
</td>
</tr>';
echo '
]]></add>


But when i checked my  $themedir/Profile.template.php"   for inserted code  i didn't found it ...even like other themes for
<search position="after"><![CDATA[</table>
</td>
</tr>';

// Show the standard "Save Settings" profile button.
]]></search>


Tell me please What does this code make? and why i coudn't find it in  $themedir/Profile.template.php"
<search position="after"><![CDATA[</table>
</td>
</tr>';

// Show the standard "Save Settings" profile button.
]]></search>

But I have
<td><input type="text" name="secretAnswer" size="20" /><span class="smalltext" style="margin-left: 4ex;"><a href="', $scripturl, '?action=helpadmin;help=secret_why_blank" onclick="return reqWin(this.href);">', $txt['secret_why_blank'], '</a></span></td>
</tr>';
}
// Show the standard "Save Settings" profile button.

and i don't know where i should insert adding code.

eNoyx

#527
Hi everybody ^^ I've made a little improvement for this marvelous mod, but I'm getting a couple of errors in my Error Log for each user that appears in the topic.

I wanted the "Karma: xx" text (in the zone of the avatar and that stuff) to be linked to the user's Karma Log "Who changed my Karma". So, I basically copied the code in Profile.template.php to Display.template.php and made some changes; although I don't know PHP/MySQL at all, I got this to work o.o But the problem is that, as I said before, a couple of errors get registered for each user that replies in a topic. For example, in a topic with 3 replies, 3 pairs of the errors get registered. These errors are:

8: Undefined index: show_karmastat
File: [ ... ]/Themes/default/Display.template.php (main sub template - eval?)
Line: 319

8: Undefined index: owner
File: [ ... ]/Themes/default/Display.template.php (main sub template - eval?)
Line: 317


The code I've made is:

Code (Display.template.php) Select


// Is karma display enabled?  Total or +/-? linked to user's log
      
  if ($modSettings['karmaMode'] == '1')
        {
if (!empty($modSettings['karmadescmod']) && !empty($modSettings['karmalinks']))
        {    if ($context['show_karmastat'])
     echo ' ';
                                if (!empty($modSettings['karmaisowner']) && ($context['owner']==1)) echo '
                                        <a href="'. $scripturl . '?action=ownkarma;u=' . $message['member']['id'] . '" title="Mi Log de Karma"><b>', $modSettings['karmaLabel'], '</b></a> ', $message['member']['karma']['good'] - $message['member']['karma']['bad'], '<br /> ';
                                elseif (empty($modSettings['karmaisowner'])) echo'
                                        <a href="'. $scripturl . '?action=ownkarma;u=' . $message['member']['id'] . '" title="Mi Log de Karma"><b>', $modSettings['karmaLabel'], '</b></a> ', $message['member']['karma']['good'] - $message['member']['karma']['bad'], '<br /> ';
                                elseif ($context['user']['is_admin']) echo '
                                        <a href="'. $scripturl . '?action=ownkarma;u=' . $message['member']['id'] . '" title="Mi Log de Karma"><b>', $modSettings['karmaLabel'], '</b></a> ', $message['member']['karma']['good'] - $message['member']['karma']['bad'], '<br /> ';

                                else {  echo ' ', $modSettings['karmaLabel'], ' ', $message['member']['karma']['good'] - $message['member']['karma']['bad'], '<br />';
                                      }
                                }
         }
                               
        elseif ($modSettings['karmaMode'] == '2')
{

if (!empty($modSettings['karmadescmod']) && !empty($modSettings['karmalinks']))
        {    if ($context['show_karmastat'])
     echo ' ';
                                if (!empty($modSettings['karmaisowner']) && ($context['owner']==1)) echo '
                                        <a href="'. $scripturl . '?action=ownkarma;u=' . $context['member']['id'] . '" title="Mi Log de Karma"><b>', $modSettings['karmaLabel'], ' </b></a>: +', $context['member']['karma']['good'], '/-', $context['member']['karma']['bad'], '<br /> ';
                                elseif (empty($modSettings['karmaisowner'])) echo'
                                        <a href="'. $scripturl . '?action=ownkarma;u=' . $context['member']['id'] . '" title="Mi Log de Karma"><b>', $modSettings['karmaLabel'], ' </b></a>: +', $context['member']['karma']['good'], '/-', $context['member']['karma']['bad'], '<br /> ';
                                elseif ($context['user']['is_admin']) echo '
                                        <a href="'. $scripturl . '?action=ownkarma;u=' . $context['member']['id'] . '" title="Mi Log de Karma"><b>', $modSettings['karmaLabel'], ' </b></a>: +', $context['member']['karma']['good'], '/-', $context['member']['karma']['bad'], '<br /> '; 
                                else { echo ' ', $modSettings['karmaLabel'], ' +', $message['member']['karma']['good'], '/-', $message['member']['karma']['bad'], '<br />';
                                      }
        }
                                }


By the way, theorically, it only has to link the user's karma log. I mean, a user only sees linkedto his karma in his posts, not other ones'.

I suppose I have to add a few lines to "define the index?"

PopsicleStickChick

Is there a way to not have banned users show up in the log?  I am referring to the top 5 lists at the bottom of the karma log.  Thanks!
www.grubesismyleader.com

An Internet forum dedicated to a former board operator at a Dallas sports talk radio station

HPRS Brian

Package Installer Problem: parse error
So I manually installed it, which took about an hour.

Everything worked fine (after I added the } to one of the files) until I tried it out.  When adding a description to an applause, I clicked the "continue" button, it logged the applause, then didn't redirect anywhere.  It just stayed at the "Enter description" screen.  If you enter another description and click continue again, it scolds you, so that works fine.

I tore apart the code, tried forcing it to redirect back out.. even to the forum index, nothing happened.  I even put a die() command in there, and it still didn't work.

I've had it, I give up on this damned mod.  What a great mod it would've been, too...  I'll just wait for a stable release to come out, I guess.  What a friggin shame.  That's a few hours of my life gone I'll never be able to get back.

chemb0t

Hi there, I seem to have encountered another error.

QuoteDatabase Error
Duplicate entry '57-1' for key 1
File: /homepages/31/d94457059/htdocs/TG/forum/Sources/Karma.php
Line: 429

I know that this was brought up before but no one seems to have found a solution yet. Any ideas? I would greatly appreciate it!

Also the Java Pop-up notification seems to be giving my users "internal server errors" when they choose it from the drop down menu and the error continues to stay as long as they are logged in. I had to comment it out to get things back to normal. Is anyone else getting this problem?

Thanks in advance!

jdvarner

getting this when i click on

who changed my karma or whose karma have i changed.

An Error Has Occurred!
Unable to load the 'main' template. 


Also get this error when i try to leave karma?

Parse error: parse error, unexpected '}' in /home/content/j/d/v/jdvarner/html/Sources/Karma.php on line 797

what can i do to fix?

diegolyanky

What about this error ?

Unknown column 'link' in 'field list'
File: /home/diego/public_html/Sources/Karma.php
Line: 391

Any suggestions ?

Best Regards ! ;)
SMF ... SimpleMachines ... Simple, but complete if you want it ;)

snork13

Quote from: diegolyanky on February 01, 2007, 09:32:52 PM
What about this error ?

Unknown column 'link' in 'field list'
File: /home/diego/public_html/Sources/Karma.php
Line: 391

Any suggestions ?

Best Regards ! ;)

check the query, what are lines 391+/-
Mods
Please DO NOT PM me with requests for individual support, but post your questions and concerns in the appropriate section of the forum where other users can benefit from them as well. Thank you.
I have been super busy as of late. Working on updates to all my modifications for 2.0.1

diegolyanky

What query  ?


Line 389 -- (action, ID_TARGET, Description, link, ID_EXECUTOR, logTime)
Line 390 --                        VALUES ($dir, $_REQUEST[uid], '$_POST[Description]', '$link', $ID_MEMBER, ". time()." )
Line 391 -- ", __FILE__, __LINE__);                       


I installed trought the MODS manager, and ...  :'(

I love this MOD !! ... I upgraded to 1.1.1 just for use it !! ...

Please Grek ! .. .HELP ME !!!!  :'(
SMF ... SimpleMachines ... Simple, but complete if you want it ;)

Grek.Kamchatka

diegolyanky,  i think you haven't а "link" field in your database.

diegolyanky

Hi Grek ! ... Long time without talking ...

What about Spanish Learning ? ;)

So ?

What can I do ?

Regards !!
SMF ... SimpleMachines ... Simple, but complete if you want it ;)

jagatai

I  installed that karma but I have these error(could u help me ,please):

Parse error: syntax error, unexpected '}' in /home/kahkaha/public_html/forum/Sources/Karma.php on line 797(it is error when click on the karma button)

$txt['maintain_karmalog'] = 'Delete the  recording list for explain  of   karma' ;(it is error on the top of the website when language of website is Turkish )

Unknown column 'Description' in 'field list'
File: /home/kahkaha/public_html/forum/Sources/Karma.php
line: 391 (after you write  reason of karma)

Unknown column 'lk.Description' in 'field list'
File: /home/kahkaha/public_html/forum/Sources/Viewkarma.php
line: 202(it is error when I want to see who changed my karma)

Unknown column 'lk.Description' in 'field list'
File: /home/kahkaha/public_html/forum/Sources/Viewkarma.php
line: 309(it is error when I want to see users list which I changed their karma)

SMF: 1.1.1   MOD:2.2


do you have  this  version of mod  to 1.1.1  which doesn't have any problem ?

look up

the members of my forum really like this mod.

is there a way to change the number of characters entered in the "Reason for changing the karma of this user" field?  currently, it appears that only 62 characters can be entered.

jagatai

Quote from: jagatai on February 02, 2007, 06:42:08 AM
I  installed that karma but I have these error(could u help me ,please):

Parse error: syntax error, unexpected '}' in /home/kahkaha/public_html/forum/Sources/Karma.php on line 797(it is error when click on the karma button)

$txt['maintain_karmalog'] = 'Delete the  recording list for explain  of   karma' ;(it is error on the top of the website when language of website is Turkish )

Unknown column 'Description' in 'field list'
File: /home/kahkaha/public_html/forum/Sources/Karma.php
line: 391 (after you write  reason of karma)

Unknown column 'lk.Description' in 'field list'
File: /home/kahkaha/public_html/forum/Sources/Viewkarma.php
line: 202(it is error when I want to see who changed my karma)

Unknown column 'lk.Description' in 'field list'
File: /home/kahkaha/public_html/forum/Sources/Viewkarma.php
line: 309(it is error when I want to see users list which I changed their karma)

SMF: 1.1.1   MOD:2.2


do you have  this  version of mod  to 1.1.1  which doesn't have any problem ?


please help me?

Advertisement: