Page 2 of 2
Posted: Wed Dec 05, 2007 1:14 pm
by battye
In quiz_cp.php
FIND
Code: Select all
for( $o = 0; $o < count($users); $o++ )
{
if( $userdata['user_id'] == intval($users[$o]) )
{
$quiz_moderator = ON;
}
}
if( $quiz_moderator != ON && $userdata['user_level'] != ADMIN )
{
message_die(GENERAL_ERROR, $lang['Quiz_cp_not_moderator']);
}
Firstly, try replacing it with:
Code: Select all
for( $o = 0; $o < count($users); $o++ )
{
if( $userdata['user_id'] == intval($users[$o]) )
{
$quiz_moderator = ON;
}
}
echo 'MOD STATUS: ' . $quiz_moderator;
if( $quiz_moderator != ON && $userdata['user_level'] != ADMIN )
{
message_die(GENERAL_ERROR, $lang['Quiz_cp_not_moderator']);
}
If it says MOD STATS: 1, replace it with this:
Code: Select all
for( $o = 0; $o < count($users); $o++ )
{
if( $userdata['user_id'] == intval($users[$o]) )
{
$quiz_moderator = ON;
}
}
if( $quiz_moderator != ON )
{
message_die(GENERAL_ERROR, $lang['Quiz_cp_not_moderator']);
}
Otherwise, I'll need to look into it some more. It looks like I didn't finish this moderator part too well, but if that's the case I'm surprised it has never been reported before
Posted: Thu Dec 06, 2007 2:07 am
by ABTOP
There is nothing showing.
Here's what I get at the very top of the page
Code: Select all
MOD STATUS:
Warning: Cannot modify header information - headers already sent by (output started at /home/newrus06/public_html/forum/quiz_cp.php:54) in /home/newrus06/public_html/forum/includes/page_header.php on line 943
Warning: Cannot modify header information - headers already sent by (output started at /home/newrus06/public_html/forum/quiz_cp.php:54) in /home/newrus06/public_html/forum/includes/page_header.php on line 947
Warning: Cannot modify header information - headers already sent by (output started at /home/newrus06/public_html/forum/quiz_cp.php:54) in /home/newrus06/public_html/forum/includes/page_header.php on line 949
It should produce either 1 or 2, right?
Why on earth is it giving me nothing?
Posted: Thu Dec 06, 2007 2:30 am
by battye
Hmm, that is a very good question.
I'm expecting the number 1... I'll have a look back through functions_quiz.php and use that code, that seemed to produce the right number.
Should have a reply for you in a few hours
Posted: Tue Dec 11, 2007 2:58 am
by ABTOP
So, do you think there is any hope for me?
Posted: Tue Dec 11, 2007 8:00 am
by battye
What happens if you try using the quiz.php/quiz_cp.php from v1.2.0 out of interest?
DL from
http://www.phpbb.com/community/viewtopic.php?t=362280
Posted: Tue Dec 11, 2007 8:42 am
by ABTOP
battye wrote:What happens if you try using the quiz.php/quiz_cp.php from v1.2.0 out of interest?...
1. I don't get the moderator's buttons for my quizzes.
2. if I play somebody else's quiz, I do get the moderator's button, although I'm not a moderator, and when I hit any of those I get "You are not a moderator" error.
I tried adding the line
Code: Select all
echo "MOD STATUS: " . $quiz_moderator;
in quiz_cp.php like before and I still get nothing for the status
Posted: Fri Dec 14, 2007 8:18 pm
by ABTOP
Have you given up?
Posted: Sun Dec 16, 2007 9:42 am
by battye
Unfortunately I have been quite busy. As soon as I find time for UQM I will make finding a solution to this a priority.
Re:
Posted: Thu Jan 17, 2008 6:48 am
by ABTOP
battye wrote:... As soon as I find time for UQM I will make finding a solution to this a priority.
http://youtube.com/watch?v=9mcZdDCOeuE
Re: Moderative status over authors' own quizzes
Posted: Thu Jan 17, 2008 6:50 am
by battye
Re: Moderative status over authors' own quizzes
Posted: Thu Jan 17, 2008 7:02 am
by ABTOP
So it should be working even without
this correction?
This may be a server configuration. Except it gives me the same problem on my localhost test server as on the main forum. Don't you have a test/development installation?
I have checked the installation many times, but I will install it from the original distribution again.
Re: Moderative status over authors' own quizzes
Posted: Thu Jan 17, 2008 7:07 am
by battye
Hmm, good point.
I used to have this installed about 2 or 3 years ago, I don't remember having any problems.
Could you post quiz_cp.php in this forum (within