karma voting
karma voting
I have installed karma voting plugin in Serendipity 1.0. When I try to vote I get the following message "Your voting was invalid."
What am I doing wrong?
What am I doing wrong?
-
garvinhicking
- Core Developer
- Posts: 30022
- Joined: Tue Sep 16, 2003 9:45 pm
- Location: Cologne, Germany
- Contact:
Re: karma voting
Hi!
You must have javascript and cookies enabled to cast a vote. Do you have that?
Best regards,
Garvin
You must have javascript and cookies enabled to cast a vote. Do you have that?
Best regards,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
javascrit and cookies
Yes, both are set.
-
garvinhicking
- Core Developer
- Posts: 30022
- Joined: Tue Sep 16, 2003 9:45 pm
- Location: Cologne, Germany
- Contact:
Re: javascrit and cookies
Hi!
What'S the URL, then I could see if it works for me?
Best regards,
GArvin
What'S the URL, then I could see if it works for me?
Best regards,
GArvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
The url
http://stu.xopc29.org/serendipity/
By the way, I use Serendipity on 2 other blogs as well.
No karma voting for them though. All are for my research into literacy.
Thank you.
By the way, I use Serendipity on 2 other blogs as well.
Thank you.
-
garvinhicking
- Core Developer
- Posts: 30022
- Joined: Tue Sep 16, 2003 9:45 pm
- Location: Cologne, Germany
- Contact:
Re: The url
Hi!
Could you patch your serendipity_event_karma.php plugin file like this:
Search for:
change that to:
This should give an more detailed error message on what might be wrong. Which PHP version are you using?
Could you patch your serendipity_event_karma.php plugin file like this:
Search for:
Code: Select all
if (!isset($msg)) {
$msg = '<div class="serendipity_karmaVoting serendipity_karmaError"><a id="karma_vote' . $this->karmaId . '"></a>' . PLUGIN_KARMA_INVALID . '</div>';
}
Code: Select all
if (!isset($msg)) {
$msg = '<div class="serendipity_karmaVoting serendipity_karmaError"><a id="karma_vote' . $this->karmaId . '">' . $this->karmaVote . '</a>' . PLUGIN_KARMA_INVALID . '</div>';
}
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
This is what I get now
Sorry it took me so long to get back.
I changed the serendipity_event_karma.php plugin file in the manner you said ( I believe). Prior to that I changed to an older version of the plugin which worked at my other Serendipity (0.9) blogs. That did not work although karma voting works great at those blogs.
The error message at the botom of the post where it allows one to karma vote is
invalid2 Your voting was invalid
Ii use the same version of php at all blogs. It is 4.4.x (latest stable release) and PHP 5.x
Thanks for all your help
I changed the serendipity_event_karma.php plugin file in the manner you said ( I believe). Prior to that I changed to an older version of the plugin which worked at my other Serendipity (0.9) blogs. That did not work although karma voting works great at those blogs.
The error message at the botom of the post where it allows one to karma vote is
invalid2 Your voting was invalid
Ii use the same version of php at all blogs. It is 4.4.x (latest stable release) and PHP 5.x
Thanks for all your help
-
garvinhicking
- Core Developer
- Posts: 30022
- Joined: Tue Sep 16, 2003 9:45 pm
- Location: Cologne, Germany
- Contact:
Re: This is what I get now
Hi!
No problem for me.
Okay, we're getting close. A DB query is not properly executed.
Please find this:
and change it to:
This should return a SQL query when you cast a vote, and a return result. Can you tell me what gets displayed?
Regards,
Garvin
No problem for me.
Okay, we're getting close. A DB query is not properly executed.
Please find this:
Code: Select all
// Voting takes place here.
$q = 'SELECT *
FROM ' . $serendipity['dbPrefix'] . 'entries AS e
LEFT OUTER JOIN ' . $serendipity['dbPrefix'] . 'karma AS k
ON e.id = k.entryid
WHERE e.id = ' . serendipity_db_escape_string($this->karmaId) . ' LIMIT 1';
$row = serendipity_db_query($q, true);
Code: Select all
// Voting takes place here.
$q = 'SELECT *
FROM ' . $serendipity['dbPrefix'] . 'entries AS e
LEFT OUTER JOIN ' . $serendipity['dbPrefix'] . 'karma AS k
ON e.id = k.entryid
WHERE e.id = ' . serendipity_db_escape_string($this->karmaId) . ' LIMIT 1';
$row = serendipity_db_query($q, true);
die($q . " RETURNS: " . print_r($row, true) . "<br />\n");
Regards,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
I did it
This came up as the page:
SELECT * FROM serendipity_entries AS e LEFT OUTER JOIN serendipity_karma AS k ON e.id = k.entryid WHERE e.id = 58 LIMIT 1 RETURNS:
SELECT *
FROM serendipity_entries AS e
LEFT OUTER JOIN serendipity_karma AS k
ON e.id = k.entryid
WHERE e.id = 58 LIMIT 1
/ Table 'xopc29a_connect.serendipity_karma' doesn't exist
Thanks again
SELECT * FROM serendipity_entries AS e LEFT OUTER JOIN serendipity_karma AS k ON e.id = k.entryid WHERE e.id = 58 LIMIT 1 RETURNS:
SELECT *
FROM serendipity_entries AS e
LEFT OUTER JOIN serendipity_karma AS k
ON e.id = k.entryid
WHERE e.id = 58 LIMIT 1
/ Table 'xopc29a_connect.serendipity_karma' doesn't exist
Thanks again
-
garvinhicking
- Core Developer
- Posts: 30022
- Joined: Tue Sep 16, 2003 9:45 pm
- Location: Cologne, Germany
- Contact:
Re: I did it
Hi rx!
Ah, there we have the culprit. Your 'karma' table does not exist at all.
Which MySQL are you using? Try to uninstall the karma plugin and then install it again, this should try to rebuild the missing tables.
Regards,
Garvin
Ah, there we have the culprit. Your 'karma' table does not exist at all.
Which MySQL are you using? Try to uninstall the karma plugin and then install it again, this should try to rebuild the missing tables.
Regards,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
Reinstalled
I still get the same error.
-
garvinhicking
- Core Developer
- Posts: 30022
- Joined: Tue Sep 16, 2003 9:45 pm
- Location: Cologne, Germany
- Contact:
Re: Reinstalled
Hi!
Which MySQL version are you using?
Use phpMyAdmin to execute a query like this:
Best regards,
Garvin
Which MySQL version are you using?
Use phpMyAdmin to execute a query like this:
Code: Select all
CREATE TABLE serendipity_karma (
entryid int(11) default null,
points int(4) default null,
votes int(4) default null,
lastvote int(10) NULL,
visits int(11) default null
)
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
-
garvinhicking
- Core Developer
- Posts: 30022
- Joined: Tue Sep 16, 2003 9:45 pm
- Location: Cologne, Germany
- Contact:
Re: MySQL
Hi!
And what happens when you execute the querY?
Regards,
Garvin
And what happens when you execute the querY?
Regards,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
Here is what I get for Query.
Error
SQL query:
CREATE TABLE serendipity_karma(
entryid int( 11 ) default NULL ,
points int( 4 ) default NULL ,
votes int( 4 ) default NULL ,
lastvote int( 10 ) NULL ,
visits int( 11 ) default NULL
)
MySQL said: Documentation
#1142 - CREATE command denied to user 'xopc29a_stu2'@'localhost' for table 'serendipity_karma'
SQL query:
CREATE TABLE serendipity_karma(
entryid int( 11 ) default NULL ,
points int( 4 ) default NULL ,
votes int( 4 ) default NULL ,
lastvote int( 10 ) NULL ,
visits int( 11 ) default NULL
)
MySQL said: Documentation
#1142 - CREATE command denied to user 'xopc29a_stu2'@'localhost' for table 'serendipity_karma'