BBC Permissions Mod

Started by winrules, September 01, 2006, 12:08:38 PM

Previous topic - Next topic

winrules

I'll have to revisit this mod...Right now it only checks for things on posting not in realtime, which can be a problem.


winrules
SMF Developer
               
My Mods
Please do not PM me for support.


Gobo

its a great mod all the same :D thanks

lookin forward to ur next version

Gobo

h winrules

just to let u know i noticed a small error in this mod

after installing EVERYONE (except the admin) were unable to use the "quote" tag anymore.

I checked and double checked the permissions for each and every group individually (I have advanced permissions for post based membergroups on) and all the permissions were proper. Yet this was occuring.

Just to let u know
aku

Poreman

Quote from: akulion on October 31, 2006, 07:26:24 AM
h winrules

just to let u know i noticed a small error in this mod

after installing EVERYONE (except the admin) were unable to use the "quote" tag anymore.

I checked and double checked the permissions for each and every group individually (I have advanced permissions for post based membergroups on) and all the permissions were proper. Yet this was occuring.

Just to let u know
aku

I found this true at my forums to, so I had to un-install the mod. Now waiting to see if the bugs get worked out in new versions before I try it again.

Poreman
I, even I, am the LORD; and beside me there is no saviour.
Isaiah 43:11

TrustingJesus

winrules

What happens when they try to quote? Does it not show the quote button, or does it not parse the quote?


winrules
SMF Developer
               
My Mods
Please do not PM me for support.


Poreman

Quote from: winrules on October 31, 2006, 03:39:45 PM
What happens when they try to quote? Does it not show the quote button, or does it not parse the quote?
It Doesn't parse the qoute? you get something like


[quote]
Context of qoute
[/quote]



Showing in the text message
I, even I, am the LORD; and beside me there is no saviour.
Isaiah 43:11

TrustingJesus

Gobo


Amicus

Quote from: akulion on October 31, 2006, 07:05:24 PM
same it dosent get parsed
Same for me.

And another one interested in deactivating automatic URL parsing:

Quote from: akulion on October 29, 2006, 08:39:01 PM
#2 if i post my link straight like this hxxp:path-to-peace.net [nonactive]
it shows up as a hyperlink so the purpose of URL BB code is defeated

Any possibility preventing this automatic parsing for "newbie" members, but not for "normal" users?

bebe

The "quote" tag works at my site. It parsed.

I have problem in activating or de-activating the BBC Permission initially, but i found the way to make it works.
I have to uncheck the "Allow all tags" first, then check on those tags that i want to allow.
If i don't do it this way but just uncheck those tags that i don't want to allow, the permission won't work correctly.

Hope this helps.

Amicus

#29
Found a possible solution to the quote problem:

If a group is edited, and all bbc tags are selected (to allow all tags), the row for that group should be deleted in the db-table bbc_permissions.
Instead the db-row of that group gets cleared, with no bbc tags left in this row.
This results in all bbc tags disallowed instead of no tags.

So the solution is to replace those 4 lines in ManagePermissions.php:


db_query("
REPLACE {$db_prefix}bbc_permissions
(ID_GROUP, disallowed)
VALUES ($_GET[group], '$disallowed')", __FILE__, __LINE__);


with this block:


if ($disallowed != '') {
db_query("
REPLACE {$db_prefix}bbc_permissions
(ID_GROUP, disallowed)
VALUES ($_GET[group], '$disallowed')", __FILE__, __LINE__);
} else {
db_query("
DELETE FROM {$db_prefix}bbc_permissions
WHERE ID_GROUP = $_GET[group]", __FILE__, __LINE__);
}

Amicus

Anyway, im still searching for a solution to the automatic url-code parsing...

Gobo

thanks for the solution

but im not trying it out on my live board im afraid ill break everything

winrules

Amicus, that should have no effect on the quote problem. Currently it will just insert a blank row. The automatic url parsing isn't a bug, but rather a limitation of the current way it does it.

I am completely unable to reproduce the problem with the quote tag. Can someone having that problem send me a test user with the abbillity to manage permissions, or a dump of the bbc_permissions table.


winrules
SMF Developer
               
My Mods
Please do not PM me for support.


Amicus

Hi winrules,

ok youre right, the url parsing isnt a bug. im anyway searching for a solution to this "problem"..

But the quote-bug..ok it isnt a "quote"-bug. It's an "all-tags"-bug..or something like this:
Freshly installed BBC Permissions mod, on SMF 1.1 RC3.
Go to Group Admincenter -> Members -> Permissions.
Select "modify" for "regular members", go to end of page and click on "save changes" without making any changes...

And now try to post any bbc tag as a regular member - doesn't work anymore. No bbc tags are parsed.
Only solution is to deselect at least one bbc-tag in the permissions, to get the other tags "back"...

That is the bug my posted code-changes fixed...

Greets,
Amicus

londonhogfan

could we get an update for 1.1 when you have time.  I have been wanting to put this mod to use for a long time.

Thanks.

Visualcode

Winrules, there seems to be some problem with your mod. I as administrator was having trouble being able to use ANY BBC codes. If I logged on a non-admin everything was fine. Sometimes my codes as an admin would work, but the tag would appear outside the code, for example:

[img]http://www.google.com/images/firefox/google.gif[/img]
would show as
[img][/img]

Other times, it would show as:
[img]http://www.google.com/images/firefox/google.gif[/img]

After uninstalling this modification, everything seems to work fine. So, I assume there is some error in handling administrators with this mod.

For more information, visit my previous topic:
http://www.simplemachines.org/community/index.php?topic=141184

Lanthan

Hai Winrules and Visualcode,
I've got the same Problem... and solved it.

It's in subs-post.php.

Search for this:
   // Now do the actual finding and replacing.
   $message = str_replace($find, $replace, $message);

and replace it with:
   // Now do the actual finding and replacing.
   if (!empty($disallowed))
      $message = str_replace($find, $replace, $message);


This should fix it.

@Winrules, perhaps you could fix it in your mod too.

Best Regards
Lanthan

nami_eiku

I have had an issue with this mod.
I installed it in a 1.1.1 smf upgraded to 1.1.2 to prohibit guests from posting urls and images (I was trying to control spam), but since I configured those permissions, no-one on other membergroups could post images nor urls (I have'nt try with other bbcodes). It just displayed the bbcode without parsing it.
At first I didn't know what was causing that, since my forum has more mods installed, so, I re-installed the whole forum, fresh 1.1.2 version.
Then, I went installing all the mods I had before and tested them, and when I installed this mod the trouble came back.
Fortunately, after uninstallation all went OK again.

Poreman

seems to have a problem made a test usergroup put a test user in it. unchecked the http in permissions.  Made a post with the test user using a http://www.anysite.com it still showed as a link didn't turn the http off.  went back and checked the permissions in test usergroup, http still unchecked but didn't make a change in the posting any reasoning behind this or do I need to uninstall anf forget this mod?

Poreman
I, even I, am the LORD; and beside me there is no saviour.
Isaiah 43:11

TrustingJesus

BlinkyBill01

#39
Problem:

If an Administrator does not belong to another usergroup, the administrator can not use any [ tags ] due to not being able to set permissions on himself. This is very problematic for the board admins.

Also, all of the tags seem to not work correctly, even when all permissions are set as all available to all users/groups. Example:

the IMG tag changes the image link to : http://hxxp: www1. istockphoto. com/file_thumbview_approve/424975/2/istockphoto_424975_doesn_t_work. jpg

it spaces out the URL and removes the slash

Advertisement: