[2.0.20] Topic Permissions

All new MODs released in our MOD Database will be announced in here. All support for released MODs needs to take place in here. No new MODs will be accepted into the MOD Database for phpBB2
Forum rules
READ: phpBB.com Board-Wide Rules and Regulations

On February 1, 2009 this forum will be set to read only as part of retiring of phpBB2.

Rating:

Excellent!
13
65%
Very Good
4
20%
Good
2
10%
Fair
0
No votes
Poor
1
5%
 
Total votes: 20

User avatar
outpatient
Registered User
Posts: 17
Joined: Mon Jul 26, 2004 1:14 am

Topic Ban not working

Post by outpatient »

Great MOD!! Thanks for the hard work!

I have a couple of questions...
With this mod, can I topic ban a specific Usergroup?

Can I ban someone from a particular forum within a category instead of just a topic?


BOARD\ CATEGORY\ FORUM\ THREAD

Please let me know, I've been looking for ways to do either one of these things. Any help is appreciated. Thanks!
Swizec
Former Team Member
Posts: 1701
Joined: Mon Mar 10, 2003 9:42 pm
Location: Slovenia
Contact:

Post by Swizec »

No it doesn't have support for groups

and it's only for topic bans, no forum/category bans.

Sorry
djdadevil
Registered User
Posts: 56
Joined: Thu Mar 23, 2006 8:37 pm
Location: Maastricht/ Holland
Contact:

Post by djdadevil »

Can this mod be fully integrated within the Profile Control Panel Mod? If so? How-To???

In wait of answer I remain!

Your sincerrely,

djdadevil
Don't Stop That Body Rock, Don't Stop That Party!
Swizec
Former Team Member
Posts: 1701
Joined: Mon Mar 10, 2003 9:42 pm
Location: Slovenia
Contact:

Post by Swizec »

DOn't know, but I guess it wouldn't hurt to try :)
djdadevil
Registered User
Posts: 56
Joined: Thu Mar 23, 2006 8:37 pm
Location: Maastricht/ Holland
Contact:

Post by djdadevil »

Swizec wrote: DOn't know, but I guess it wouldn't hurt to try :)


Yes it does, wanted to know first, but installed with easymod, almost no errors, but all went fine... thanks anyway and nevermind!
Don't Stop That Body Rock, Don't Stop That Party!
Swizec
Former Team Member
Posts: 1701
Joined: Mon Mar 10, 2003 9:42 pm
Location: Slovenia
Contact:

Post by Swizec »

djdadevil wrote:
Swizec wrote:DOn't know, but I guess it wouldn't hurt to try :)


Yes it does, wanted to know first, but installed with easymod, almost no errors, but all went fine... thanks anyway and nevermind!


Glad to hear that ^^
Fayo
Registered User
Posts: 56
Joined: Wed Nov 09, 2005 10:56 am

didn't log in...

Post by Fayo »

Does the current version still have the "you didn't log in to the topic" problem?

If yes, I know that you know :) that it happens when you enter the topic via some external link. But maybe you don't know it also happens when there's an internet disconnection while you are in the topic. I noticed that normally, when the connection goes down while replying, and than you connect again, it asks you to log in again. But with your mod, it does not even try, it just says: you didn't log in to the topic. Maybe this helps?
Swizec
Former Team Member
Posts: 1701
Joined: Mon Mar 10, 2003 9:42 pm
Location: Slovenia
Contact:

Post by Swizec »

That is strange what you just said because the information about topics is in the sessions table... so when yo get a new session id it clears the information... but when you then access a topic normally it should allow you to login again normally.

This is a very strange error really... very very strange.
djdadevil
Registered User
Posts: 56
Joined: Thu Mar 23, 2006 8:37 pm
Location: Maastricht/ Holland
Contact:

Post by djdadevil »

Swizec wrote:
djdadevil wrote:
Swizec wrote:DOn't know, but I guess it wouldn't hurt to try :)


Yes it does, wanted to know first, but installed with easymod, almost no errors, but all went fine... thanks anyway and nevermind!


Glad to hear that ^^


Oops, cheered to soon hehe....

I am having some problems with my 'includes/functions_post.php' I already addressed it in here: http://www.phpbb.com/phpBB/viewtopic.php?p=2124430 but don't come any further in there, short description of my problem, when I want to post a new post or topic on my forum, it says the following:

Code: Select all

Error in posting

DEBUG MODE

SQL Error : 1064 You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '0, 0, 0, , 0)' at line 1

INSERT INTO phpBB_topics (topic_title, topic_noguest, topic_noguest_level, topic_password, topic_pass_level, topic_poster, topic_time, forum_id, topic_adminedit, topic_status, topic_type, topic_calendar_time, topic_calendar_duration, topic_vote) VALUES ('1','', '', '', '', 2, 1147013118, 1, ,0, 0, 0, , 0)

Line : 312
File : functions_post.php
I've placed my functions_post.php in a zip file here:
functions_post.php
I know it's a heavely modified file, but I think it's just a minor error concering the placement of tags....

Can someone help me with this here,

I presume it has something 2-do with the following code of this mod-install:

Code: Select all

#-----[ OPEN ]------------------------------------------ 
# 

includes/functions_post.php

# 
#-----[ FIND ]------------------------------------------ 
# 

submit_post(

# 
#-----[ IN-LINE FIND ]------------------------------------------ 
# 

&$bbcode_on,

# 
#-----[ IN-LINE BEFORE, ADD ]------------------------------------------ 
# 

&$noguest, &$adminedit, &$password, 

# 
#-----[ FIND ]------------------------------------------ 
# 

$sql  = ( ($mode != "editpost") || ($was_a_draft && 
[color=red](My edit!)[/color]

# 
#-----[ BEFORE, ADD ]------------------------------------------ 
# 

//mod topic mod add
$lockedit = $adminedit[1];
$pass = $password[1];
$pass_lvl = $password[2];
$noguest_lvl = $noguest[2];
$noguest = $noguest[1];
// mod topic mod: add to sql query

# 
#-----[ IN-LINE FIND ]------------------------------------------ 
# 

topic_title, 

# 
#-----[ IN-LINE AFTER, ADD ]------------------------------------------ 
# 

topic_noguest, topic_noguest_level, topic_password, topic_pass_level, 
[color=red]guess that this is the problem since all other tags are beginning with an $-mark... did post that already into it, but still having the same problem[/color]

# 
#-----[ IN-LINE FIND ]------------------------------------------ 
# 

topic_status, 
[color=red]same here I presume[/color]

# 
#-----[ IN-LINE BEFORE, ADD ]------------------------------------------ 
# 
(...) etc...
In wait of an answer, I Remain,

Your sincerrely,

djdadevil
Don't Stop That Body Rock, Don't Stop That Party!
Swizec
Former Team Member
Posts: 1701
Joined: Mon Mar 10, 2003 9:42 pm
Location: Slovenia
Contact:

Post by Swizec »

Uhm dude, the php file you linked to doesn't seem to have this mod even applied.

You're missing something in the sql query where the error occurs though... undefined variable or something.

Ah no wait, just the variables in the header of the "submit_post" function appear to be missing so that's probably what's wrong.
allan1956
Registered User
Posts: 18
Joined: Sat Apr 22, 2006 9:59 pm

Post by allan1956 »

Hi, thanks for this mod

I believe there might be a small error.

In ModCP the SQL Update for the Case Unlock seems to set the status to Locked. Somewhere around line 652 it says:

Code: Select all

: "UPDATE " . TOPICS_TABLE . " 
	SET topic_status = " . TOPIC_LOCKED . " 
	WHERE topic_id IN ($topic_id_sql) 
		AND topic_adminedit = '0'
		AND forum_id = $forum_id
		AND topic_moved_id = 0";
it its should be TOPIC_UNLOCKED
shouldn't it?

I had strange behavior whenI did unlocks, the topic symbol stayed locked. It was ina n odd state, when I made above chnage it all seems to work
djdadevil
Registered User
Posts: 56
Joined: Thu Mar 23, 2006 8:37 pm
Location: Maastricht/ Holland
Contact:

Post by djdadevil »

Swizec wrote: Uhm dude, the php file you linked to doesn't seem to have this mod even applied.

You're missing something in the sql query where the error occurs though... undefined variable or something.

Ah no wait, just the variables in the header of the "submit_post" function appear to be missing so that's probably what's wrong.


Ooh Damn, I see, I missed the first 'IN-LINE BEFORE, ADD', everything else was there, but I added it, but now I get some other weird messages, altough it posted the message, only I get the following error's.

Above overall_header I now get the following after posting a message:

Code: Select all

Warning: Missing argument 8 for user_notification() in /var/www/html/phpBB2/includes/functions_post.php on line 761

Warning: Missing argument 9 for user_notification() in /var/www/html/phpBB2/includes/functions_post.php on line 761

Warning: Missing argument 10 for user_notification() in /var/www/html/phpBB2/includes/functions_post.php on line 761

Warning: Missing argument 11 for user_notification() in /var/www/html/phpBB2/includes/functions_post.php on line 761

Warning: Cannot modify header information - headers already sent by (output started at /var/www/html/phpBB2/includes/functions_post.php:761) in /var/www/html/phpBB2/includes/page_header.php on line 652

Warning: Cannot modify header information - headers already sent by (output started at /var/www/html/phpBB2/includes/functions_post.php:761) in /var/www/html/phpBB2/includes/page_header.php on line 654

Warning: Cannot modify header information - headers already sent by (output started at /var/www/html/phpBB2/includes/functions_post.php:761) in /var/www/html/phpBB2/includes/page_header.php on line 655
And inside the box where it normaly says your message has been posted, I get the following error on this very same page:

Code: Select all

Could not obtain topic watch information

DEBUG MODE

SQL Error : 1064 You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'AND user_id = 2' at line 4

SELECT topic_id FROM phpBB_topics_watch WHERE topic_id = AND user_id = 2

Line : 918
File : functions_post.php
It postes the message but I get these errors instead of it's normal confirmation!
So there is still something wrong with it, could you help me solve this???

I posted my new functions_post.php here:
http://www.djdadevil.nl/functions_post.zip

Again in wait of respons, I remain!

your sincerrely,

djdadevil

ps:
Swizec wrote: Ah no wait, just the variables in the header of the "submit_post" function appear to be missing so that's probably what's wrong.

If this solves the problem could you please be a bit specific, cause my knowledge of PHP is 0,5% hehe.... sorry!
Don't Stop That Body Rock, Don't Stop That Party!
allan1956
Registered User
Posts: 18
Joined: Sat Apr 22, 2006 9:59 pm

Post by allan1956 »

The problems are all clearly installations problems,
Did you do this manually? or use EasyMod?
If manually well jsut need to spend the time going over it line by line
deejaybet
Registered User
Posts: 1814
Joined: Thu Dec 08, 2005 2:01 pm
Location: Derry, Northern Ireland
Contact:

Post by deejaybet »

reinstall it :)
allan1956
Registered User
Posts: 18
Joined: Sat Apr 22, 2006 9:59 pm

Post by allan1956 »

Another error on install I beleive.

Ths first symptom is a database failure when Moving a topic and leaving a shadow behind. The SQL insert is being messed up because the $make_admin is placed at the wrong spot.

This

Code: Select all

# 
#-----[ FIND ]------------------------------------------ 
# 

" . TOPIC_MOVED . ",

# 
#-----[ IN-LINE FIND ]------------------------------------------ 
# 

",

# 
#-----[ IN-LINE AFTER, ADD ]------------------------------------------ 
# 

$make_admin, 
should end up like

Code: Select all

VALUES ($old_forum_id, '" . addslashes(str_replace("\'", "''", $row[$i]['topic_title'])) . "', '" . str_replace("\'", "''", $row[$i]['topic_poster']) . "', " . $row[$i]['topic_time'] . ", " . TOPIC_MOVED . ", $make_admin, " . POST_NORMAL . ", " . $row[$i]['topic_vote'] . ", " . $row[$i]['topic_views'] . ", " . $row[$i]['topic_replies'] . ", " . $row[$i]['topic_first_post_id'] . ", " . $row[$i]['topic_last_post_id'] . ", $topic_id)";
but ends up like this: (or it at least it did for me)

Code: Select all

VALUES ($old_forum_id, '" . addslashes(str_replace("\'",$make_admin, "''", $row[$i]['topic_title'])) . "', '" . str_replace("\'", "''", $row[$i]['topic_poster']) . "', " . $row[$i]['topic_time'] . ", " . TOPIC_MOVED . ",  " . POST_NORMAL . ", " . $row[$i]['topic_vote'] . ", " . $row[$i]['topic_views'] . ", " . $row[$i]['topic_replies'] . ", " . $row[$i]['topic_first_post_id'] . ", " . $row[$i]['topic_last_post_id'] . ", $topic_id)";
Post Reply

Return to “[2.0.x] MOD Database Releases”