Link to Mod (https://custom.simplemachines.org/mods/index.php?mod=2104)
Moderator and Administrator Comment Tags
Written by: Arantor | Current version: 1.9 |
|
Suitable for: 1.1.x, 2.0.x | Supported languages: (https://www.simplemachines.org/site_images/lang/english.gif) (https://www.simplemachines.org/site_images/lang/english_british.gif) (https://www.simplemachines.org/site_images/lang/french.gif) (https://www.simplemachines.org/site_images/lang/spanish.gif) (https://www.simplemachines.org/site_images/lang/german.gif) (https://www.simplemachines.org/site_images/lang/danish.gif) (https://www.simplemachines.org/site_images/lang/dutch.gif) (https://www.simplemachines.org/site_images/lang/portuguese_pt.gif) (https://www.simplemachines.org/site_images/lang/portuguese_brazilian.gif) (https://www.simplemachines.org/site_images/lang/russian.gif) |
Link to Mod (http://custom.simplemachines.org/mods/index.php?mod=2104) | Mod support topic (https://www.simplemachines.org/community/index.php?topic=334033.0)
SummaryThis mod adds three tags - [admin], [gmod] and [mod] - to the system which provide the ability for moderators and administrators to add comments clearly delineated as such.
All three are permission controlled; you can give out each button to any user group independently; for example you may have co-admins who are effectively admins without them having the 'administrate forum' permission, and this would allow you to grant it to them.
Groups who are not authorised to use these tags cannot do so and the tags are removed if they attempt to use them.
For themers: you can customise the resultant blocks by styling .admin_comment, .gmod_comment and .mod_comment respectively.
Thanks to @ngel for French translation, 130860 for Spanish translation, Eclipse16V for German translation, Akyhne for Danish translation, Pentaxian for Dutch translation, qnub for Russian translation and Costa for the Portuguese translation.
InstallationPackage Manager should work in most cases. If you need to make any edits, the full list can be obtained from the Parse function on the right.
Useful linksManual Installation Of Mods (http://docs.simplemachines.org/index.php?topic=402)
How Do I Modify Files? (https://www.simplemachines.org/community/index.php?topic=24110.0)
SupportQuestions should be address to the mod support topic (https://www.simplemachines.org/community/index.php?topic=334033.0).
UpdatingTo update from 1.8 or below, please uninstall then install 1.9 from the package manager.
Changelog1.9 - 28 December 2017
Modified the security routine to work on PHP beyond 5.5. PHP 5.3 is now required for mod v1.9.
1.8 - 29 December 2009
Added Russian and Portuguese support.
Cleaned up package contents (not a visible change)
1.7 - 9 November 2009
Added Dutch support
1.6 - 26 October 2009
Added 2.0 RC2 support.
1.5 - 25 September 2009
Added Danish translation.
1.4 - 10 September 2009
Made Moderator tag board specific.
Added German translation.
1.3 - 4 September 2009
Bugfix from French translation.
Added Spanish translation.
1.2 - 4 September 2009
Bugfix from 1.1 regarding the new Global Moderator tag permissions not being enforced correctly.
Added support for French translation.
1.1 - 4 September 2009
Added support for the global moderator tag, plus moved all three to permissions-based from the admin panel
1.0 - 14 August 2009
First release
Files modified by Moderator and Administrator Comment TagsSources/Subs.php
Sources/Subs-Post.php
Sources/ManagePermissions.php
Themes/yourtheme/Post.template.php (1.1 only)
Sources/Subs-Editor.php (2.0 only)
Themes/yourtheme/Modifications.*.php for supported languages.
Also adds 3 .gif files into Themes/yourtheme/images/bbc, and 3 into Themes/yourtheme/images
nice tweek
8: Undefined index: tag_comment_admin
File: /home/vhosts/www.site.com/Sources/Subs.php
Line: 3759
Thanks
Turkish language
$txt['tag_comment_mod'] = 'Moderator Yorumu';
$txt['tag_comment_admin'] = 'Yönetici Yorumu';
Is this comment visible for all members, or only moderators/admins?
for all
ps. thx for nice mod :D
ok thanks for your quick responds.
Thanks
Fine Mod
German Language
$txt['tag_comment_mod'] = 'Moderator Kommentar';
$txt['tag_comment_admin'] = 'Administrator Kommentar';
what about my error ? does anybody getting the same ?
Rohan_, are you using English? The mod only supports English and English British. Please note I've been out today and wasn't able to pick up on this earlier - please have patience as remember that real life takes priority.
qtime: the comment is visible to all. However only the mods and admins can use the tags, much like [html] tags.
funkenwerner: Thanks for the translation, I'll add that to the next version.
ya i only use English
Check your custom theme's Modifications.english.php file. You may have to add these lines to it:
$txt['tag_comment_mod'] = 'Moderator Comment';
$txt['tag_comment_admin'] = 'Administrator Comment';
okay and 1 more thing .. i want the border color red .. and the text i want is administrator's i want to add 's .. i tried it in modifications.english but i got error :(
For the border: add it to your CSS. I even left notes in the mod's description what to change.
For the ', make it \'
E.g.
$txt['tag_comment_admin'] = 'Administrator\'s Comment';
okay everything done .. now i didn't understand how to change the color of border
Go into your CSS file for your forum - style.css in your theme.
Try:
.admin_comment, .mod_comment {
border-color: red;
}
Styling isn't my forte, however (which is why my dev forum is still using the default!) so maybe that needs tweaking.
hey thanks .. it worked .. here is a look .. i also changed something to use this mod for warning puposes
(http://i32.tinypic.com/2ibor37.jpg)
Awesome :)
Note that it'll give you a red box on both right now but you can break it into two blocks easily enough.
yes i understand now
Thanks again Arantor .. today i am very happy because of this mod and the ban expire mod .. Do u have any other great mods waiting approval ?
(http://i32.tinypic.com/2rdw18g.gif)(http://i32.tinypic.com/2rdw18g.gif)(http://i32.tinypic.com/2rdw18g.gif)(http://i32.tinypic.com/2rdw18g.gif)(http://i32.tinypic.com/2rdw18g.gif)
I have 5 mods still awaiting approval at present. You can see my personal tracker of mods in my signature - Arantor Developments.
lets wait for them :)
I was thinking of this idea only a couple days ago.
Very nice mate! and thanks :)
Hi,
Looks good! Just to make it clear to me (and maybe others), this essentially does what Aaron's Modbreak MOD does, but has the changes you developed for that MOD incorporated. And expanded the concept into two BBCodes to differentiate between Moderators and Admins, yes?
Would it be possible to add a permission to allow another group to also use the Admin tag? On our site we have some folk who can do everything an Admin does except the Admin System Management. They have full authority but as they are not technically inclined, reduces the risk of something being changed unintentionally. They're based on the Global Moderator group with a few extra tweaks.
Really like the mod...
Would you know how to center the Moderators Comment & Admins(immortal in my attachment) Comment text so it stays inline with the border?
I've tried to center it via text-align within span and divs, but that brings the text within the border.
Maybe Im looking in the wrong place.
Any suggestions are always appreciated.
Cheers :)
Great mod Arantor, I've been using modbreak but I like this one more.
For the admin/mod box title tags:
I've changed the titles to my own handle and my mod's handle and also used css to change the colour to the admin and mod membergroup colours. Also, I've changed the font weight to bold. You need to add 'legend' to the css otherwise the text in the box will be the same as the title.
.admin_comment legend {
color: #0099FF;
font-weight: bold;
}
.mod_comment legend {
color: red;
font-weight: bold;
}
Looks really good Arantor 8)
It appears to work just fine in my SMF 2.0 RC1
Quote from: Cal O'Shaw on September 02, 2009, 12:13:18 AM
Looks good! Just to make it clear to me (and maybe others), this essentially does what Aaron's Modbreak MOD does, but has the changes you developed for that MOD incorporated. And expanded the concept into two BBCodes to differentiate between Moderators and Admins, yes?
Yes, it is all of that. Plus it adds permission-geared buttons on the post editor.
Quote from: Cal O'Shaw on September 02, 2009, 12:13:18 AM
Would it be possible to add a permission to allow another group to also use the Admin tag? On our site we have some folk who can do everything an Admin does except the Admin System Management. They have full authority but as they are not technically inclined, reduces the risk of something being changed unintentionally. They're based on the Global Moderator group with a few extra tweaks.
It would be possible, but that was out of the scope I originally had for the mod - which was essentially modbreak + enforcement of permissions + editor buttons. I can definitely add it to the list for the next version though I cannot guarantee if/when that'll get done.
Sabre: I don't think you can without modifying the raw HTML it generates to a style better suited to you. I've never before really encountered anyone styling a fieldset+legend in that way. You may have some luck styling the legend element as Blinker suggests.
Blinker: thanks for the tip! I deliberately didn't get into how to style it, because I figured anyone that knew about the two classes would be able to style the legend too - but in all honesty I'm not a CSS guru.
excellent
Quote from: Arantor on September 02, 2009, 06:38:29 AMBlinker: thanks for the tip! I deliberately didn't get into how to style it, because I figured anyone that knew about the two classes would be able to style the legend too - but in all honesty I'm not a CSS guru.
No probs Arantor. :) I'm certainly no guru either, I just look at the way other mods have used css and work it out from there.
BTW I also managed to use your code from the post template to get the BBC buttons working on my Enhanced Quick Reply Box. If anyone has trouble, just make sure you put Arantor's code under the button array between
);
and
$found_button = false;
Another excellent tip there, thanks Blinker :)
Very nice mod! Thanks for the work on this!
Arantor, thank you for this great mod. It installed easily and works great.
Maybe it is a given knowledge but you may want to mention the images files that need to be uploaded to the two folders (images and images/bbc) on the custom theme. I thought the package only contained bbc images until I saw the screencap in an earlier post that has an image in the post.
One question -
Is it possible to have tag for global moderators? I know global moderators can use mod tag but it would be nice to give them a tag of their own.
Well, the thing is that internally there isn't a separate 'global moderator' permission. The only permission you can rely on for mods is the ability for 'moderate_board'.
That said, I'm adding the permission in the next version to assign the admin tag to user groups, meaning that I could do the same for moderators.
That makes sense. Sounds great too.
Looking forward to your great work! Thanks!!
Quote from: bbmtalk on September 03, 2009, 10:19:04 AM
Is it possible to have tag for global moderators? I know global moderators can use mod tag but it would be nice to give them a tag of their own.
i am also thinking about this :)
Quote from: Rohan_ on September 03, 2009, 10:26:42 AM
i am also thinking about this :)
And as ever I'll get to it when I get to it, not before. Right now my paid vBookie mod is being developed which takes priority.
what does ur Vbookie do ?
Does what vBookie does for vBulletin - or at least it will when it's finished - and people are buying it.
Essentially it allows users to put up sporting events and have friendly bets on who they think will win.
i really don't know about vbookie
[Information about Vbookie] (http://lmgtfy.com/?q=vbookie)
Back on topic....
Your next release sounds pretty good, and very flexible.
Look forward to it.
Thanks mate :)
Here's the FRENCH translation
Thank you @ngel, I'll bundle that up into the file for v1.2, which I'll try and sort out later on tonight :)
Hi Arantor,
I see you posted 1.1 version which includes 3 groups. That is awesome!! Thank you!
Should I wait for 1.2?
The only difference between 1.1 and 1.2 will be the French translation; 1.1 already has both the 3 groups and permissions to individually control them (for both SMF 1.1 and 2.0 series)
Wow, really nice mod... :D
good mod Arantor, here is Spanish translation:
$txt['tag_comment_mod'] = 'Comentario del Moderador';
$txt['tag_comment_admin'] = 'Comentario del Adminstrador';
it doesn't use any rare character so it could be use on utf-8 and normal ;)
i uninstalled the old one and installed the new :) thanks ..... my super mods ate my head for this feature to give them
I also installed 1.1 and my global mods are happier with their own color showing their status. Thanks for adding it.
I have one issue though. In member permission, I assigned "mod squad" to only the mod tag and they can only see the mod BBC icon.
However, if they manually type [gmod] comment [/gmod]
, it will display global moderator comment and not remove the tag.
It is the same for regular members who didn't even assign to any mod tag - only happens for gmod.
Any idea why?
same problem here .. everyone can use gmod tags :( ... the image for gmod tag did not appears but if anyone type gmod manually then everyone can use it
130860, thanks for the translation - unfortunately with 1.1 I added a ton new strings which would also need translation.
Guys, thanks for the report. I'm not sure which version of SMF you're using so I'll just have to recheck both sets of code.
I'll roll the update for French in to the fix for this one too, expect to see 1.2 later on tonight, all fixed plus with French translation.
In fact... expect to see it momentarily. Stupid error on my part, fixed now for both 1.1 and 2.0, mod updated to 1.2 on the site - with French translation added.
lol
I was wondering how that line couldve been gmod, you had me going over the install.xml trying to find the mystery code that achieved it lol
Good work mate :)
It's the regular expression and the replaces in the middle block in Subs-Post, it was supposed to strip [gmod except where I copy/pasted from the admin block I kinda modded the permission set - and forgot to edit the code, so it would be stripping [admin again.
Quote from: Arantor on September 04, 2009, 05:41:43 PM
130860, thanks for the translation - unfortunately with 1.1 I added a ton new strings which would also need translation.
lol I missed it :P , I will translate all and post it again ;)
Many thanks - I'll add to 1.3 when that's done :)
ok, here you go:
utf-8:
$txt['tag_comment_mod'] = 'Comentario de Moderador';
$txt['tag_comment_gmod'] = 'Comentario de moderador global';
$txt['tag_comment_admin'] = 'Comentario de Administrador';
$txt['permissiongroup_modtag'] = 'Control de tags de moderador';
$txt['permissiongroup_simple_modtag'] = 'Control de tags de moderador';
$txt['permissionname_allow_mod_tag'] = '¿Permitir a este grupo usar el tag [mod] ?';
$txt['permissionhelp_allow_mod_tag'] = 'Este permiso, permite a los usuarios en este grupo usar el tag [mod] para usar comentarios al moderador. Estos comentarios no son removidos si el usuario abandona el grupo.';
$txt['permissionname_allow_gmod_tag'] = '¿Permitir a este grupo usar el tag [gmod] ?';
$txt['permissionhelp_allow_gmod_tag'] = 'Este permiso, permite a los usuarios en este grupo usar el tag [gmod] para usar comentarios al moderador global. Estos comentarios no son removidos si el usuario abandona el grupo.';
$txt['permissionname_allow_admin_tag'] = '¿Permitir a este grupo usar el tag [admin] ?';
$txt['permissionhelp_allow_admin_tag'] = 'Este permiso, permite a los usuarios en este grupo usar el tag [admin] para usar comentarios al administrador. Estos comentarios no son removidos si el usuario abandona el grupo.';
ANSI:
$txt['tag_comment_mod'] = 'Comentario de Moderador';
$txt['tag_comment_gmod'] = 'Comentario de moderador global';
$txt['tag_comment_admin'] = 'Comentario de Administrador';
$txt['permissiongroup_modtag'] = 'Control de tags de moderador';
$txt['permissiongroup_simple_modtag'] = 'Control de tags de moderador';
$txt['permissionname_allow_mod_tag'] = '¿Permitir a este grupo usar el tag [mod] ?';
$txt['permissionhelp_allow_mod_tag'] = 'Este permiso, permite a los usuarios en este grupo usar el tag [mod] para usar comentarios al moderador. Estos comentarios no son removidos si el usuario abandona el grupo.';
$txt['permissionname_allow_gmod_tag'] = '¿Permitir a este grupo usar el tag [gmod] ?';
$txt['permissionhelp_allow_gmod_tag'] = 'Este permiso, permite a los usuarios en este grupo usar el tag [gmod] para usar comentarios al moderador global. Estos comentarios no son removidos si el usuario abandona el grupo.';
$txt['permissionname_allow_admin_tag'] = '¿Permitir a este grupo usar el tag [admin] ?';
$txt['permissionhelp_allow_admin_tag'] = 'Este permiso, permite a los usuarios en este grupo usar el tag [admin] para usar comentarios al administrador. Estos comentarios no son removidos si el usuario abandona el grupo.';
it is valide to use on spanish_latin and spanish_es as well ;)
Arantor, thanks for the update.
I think the issue with gmod is fixed. After I installed the updated version, all of the following three show up French.
$txt['tag_comment_mod'] = 'Moderator Comment';
$txt['tag_comment_gmod'] = 'Global Moderator Comment';
$txt['tag_comment_admin'] = 'Administrator Comment';
My forum is only English. After removing all French text in Modification.english.php, they all now show in English.
Today just isn't my day, is it? Thanks for the heads-up, I know precisely what I did wrong there.
Another stupid mistake from trying to do too much.
Will repackage, fixed, with Spanish support in just a moment as v1.3.
Right, Spanish version added plus French issue fixed - for some reason the wrong version of the french.xml file was in the zip.
Quote from: Arantor on September 04, 2009, 06:52:16 PM
Today just isn't my day, is it?
lol
* scratches 'MIT director' from the ~~ Who is Arantor? list
Im personally sticking with your original release, as I have no need for the added function [gmod].
For now that is.
1.3. cool. You are making a great progress and thanks for the prompt support and update.
It seems now all installing and working fine. Another question for you. (I know I have been asking too much , sorry)
The permission for moderators is only available globally, right? Can it be set locally for mods only assigned to a certain boards?
Sabre: Fair enough, if it works for you and you don't need the translations or the custom permissions, stick with it.
bbmtalk: Argh. I thought it was too easy to set permissions; I forgot the Moderator group is kinda special in that regard.
Interim solution while I figure out how to make it work on the special group would be per-board permissions, and a special custom group that does basically the same job as Moderator but isn't subject to the way Moderator is set up. Ugly but it'd work for that member group.
I'll look into that one tomorrow.
Arantor, no hurry. I was just curious and I know it is gonna turn very complicated with permissions.
I can understand Sabre for sticking with original release. Sometimes less is more. I thought it was good enough for me - but not for my global mods.
Thanks again for all the great work.
Actually it shouldn't be that hard, I just have to remember to move it to the board permissions rather than the general permissions at group level. In theory the correct approach would be splitting [mod] to board and [gmod] and [admin] to group level but I think that would be confusing.
It's quite late here but I'll get on that one in the morning and repackage as 1.4.
Arantor Brother if the error is fixed then please give me the manual change of the code that u updated :(
Edit : okay then its too long now so i done it ...
Turkish
$txt['tag_comment_mod'] = 'Moderatör Yorumları';
$txt['tag_comment_gmod'] = 'Global Moderator Yorumları';
$txt['tag_comment_admin'] = 'Administrator Yorumları';
$txt['permissiongroup_modtag'] = 'Moderator etiket kontrolleri';
$txt['permissiongroup_simple_modtag'] = 'Moderator etiket konrolleri';
$txt['permissionname_allow_mod_tag'] = 'Kullanmak isteyen bütün kullanıcılara izin ver? [mod] ?';
$txt['permissionhelp_allow_mod_tag'] = 'Bu izin tüm kullanıcıların moderatör yorumlarını kullanmasına olanak verir.(mod)';
$txt['permissionname_allow_gmod_tag'] = 'Tüm kullanıcılara izin ver.[gmod] ?';
$txt['permissionhelp_allow_gmod_tag'] = 'Bu izin tüm kullanıcıların gmod blokunu kullanmasına olanak verir';
$txt['permissionname_allow_admin_tag'] = 'Kullanıcılara izin ver [admin] ?';
$txt['permissionhelp_allow_admin_tag'] = 'Bu izin kullanıcıların admin bloğunu kullanmasına olanak verir.';
Quote from: Rohan_ on September 05, 2009, 02:53:56 AM
Arantor Brother if the error is fixed then please give me the manual change of the code that u updated :(
Edit : okay then its too long now so i done it ...
The fix was in 1.3, and as for your 'too long now' of 2 hours patience, I couldn't reply before because I was trying to catch some sleep.
Mythcomeback: Thanks for the translation: I'll roll that into 1.4 well as the change in permissions to make moderator board-level, should be sometime today.
nice mod i can purpose one idea will be very useful if near comment will be wrote the name of author of that comment, i mean Moderator comment by (name of moderator)
Quote from: Mythcomeback | Burak on September 05, 2009, 04:43:27 AM
Turkish
$txt['tag_comment_mod'] = 'Moderatör Yorumları';
$txt['tag_comment_gmod'] = 'Global Moderator Yorumları';
$txt['tag_comment_admin'] = 'Administrator Yorumları';
$txt['permissiongroup_modtag'] = 'Moderator etiket kontrolleri';
$txt['permissiongroup_simple_modtag'] = 'Moderator etiket konrolleri';
$txt['permissionname_allow_mod_tag'] = 'Kullanmak isteyen bütün kullanıcılara izin ver? [mod] ?';
$txt['permissionhelp_allow_mod_tag'] = 'Bu izin tüm kullanıcıların moderatör yorumlarını kullanmasına olanak verir.(mod)';
$txt['permissionname_allow_gmod_tag'] = 'Tüm kullanıcılara izin ver.[gmod] ?';
$txt['permissionhelp_allow_gmod_tag'] = 'Bu izin tüm kullanıcıların gmod blokunu kullanmasına olanak verir';
$txt['permissionname_allow_admin_tag'] = 'Kullanıcılara izin ver [admin] ?';
$txt['permissionhelp_allow_admin_tag'] = 'Bu izin kullanıcıların admin bloğunu kullanmasına olanak verir.';
Thanks for translation into Burak
edi67: You should be able to use the secondary format to do that, for example:
[mod=Arantor says]This post is inappropriate.[/mod]
This would replace the 'moderator comment' with 'Arantor says'
Quote from: Arantor on September 05, 2009, 03:10:58 PM
edi67: You should be able to use the secondary format to do that, for example:
[mod=Arantor says]This post is inappropriate.[/mod]
This would replace the 'moderator comment' with 'Arantor says'
Great tip! Thanks!
Did I not add in the description that you could do that? Should work fine for all three tags, plus still should get removed if an unauthorised user tries to use it.
Quote from: Arantor on September 05, 2009, 03:10:58 PM
edi67: You should be able to use the secondary format to do that, for example:
[mod=Arantor says]This post is inappropriate.[/mod]
This would replace the 'moderator comment' with 'Arantor says'
oh yes this i know but for lazy staff could be intersting have it automatically ;) in same line or part of code
It would have to be yet another rewrite of the code to achieve, to be honest, or add an option somewhere in the admin panel (which I don't really want to do for this to be honest)
Quote from: Arantor on September 05, 2009, 03:55:40 PM
Did I not add in the description that you could do that? Should work fine for all three tags, plus still should get removed if an unauthorised user tries to use it.
Well I have followed this mod from 1.0 to 1.3 and it was new to me.
It's been in since 1.0. More likely I just never documented it.
for sum reason I am not getting the permissions to come up under permissions...
I am running smf 1.10 with tp
it said it installed properly, no errors using package manager
no other errors in forums either
What version are you using, clashbot?
Cool thanks!
Finnish Translation:
$txt['tag_comment_mod'] = 'Moderaattorin kommentti';
$txt['tag_comment_admin'] = 'Ylläpitäjän kommentti';
Thanks Abaliini - unfortunately I've added a lot more language strings since 1.0, for all the extra permissions which would also need to be translated. If you could find the time to translate them as well, I'll add it into the next version.
Works fine here, thanks for such a nice mod.
Here's a screenshot on how it looks on my forum for Global Moderators (after a little customization :)):
(http://i32.tinypic.com/jzba5e.png)
Nice Mod.
Here is the German:
// Mod Tag MOD
$txt['tag_comment_mod'] = 'Moderator Kommentar';
$txt['tag_comment_gmod'] = 'Globaler Moderator Kommentar';
$txt['tag_comment_admin'] = 'Administrator Kommentar';
$txt['permissiongroup_modtag'] = 'Moderator Tags';
$txt['permissiongroup_simple_modtag'] = 'Moderator Tags';
$txt['permissionname_allow_mod_tag'] = 'Erlaube das nutzen von [mod] ?';
$txt['permissionhelp_allow_mod_tag'] = 'Diese Berechtigung erlaubt es dem User die Funktion [mod] zu nutzen und somit ein "Moderator Kommentar" abzugeben. Diese Kommentare werden NICHT gelöscht wenn der User die Gruppe verlässt.';
$txt['permissionname_allow_gmod_tag'] = 'Erlaube das nutzen von [gmod] ?';
$txt['permissionhelp_allow_gmod_tag'] = 'Diese Berechtigung erlaubt es dem User die Funktion [gmod] zu nutzen und somit ein "Globaler Moderator Kommentar" abzugeben. Diese Kommentare werden NICHT gelöscht wenn der User die Gruppe verlässt.';
$txt['permissionname_allow_admin_tag'] = 'Erlaube das nutzen von [admin] ?';
$txt['permissionhelp_allow_admin_tag'] = 'Diese Berechtigung erlaubt es dem User die Funktion [admin] zu nutzen und somit ein "Adminstrator Kommentar" abzugeben. Diese Kommentare werden NICHT gelöscht wenn der User die Gruppe verlässt.';
NICE ARANTOR! Edited group permissions so admins can see only admin comment, and gmod, only gmod comment...!!!!!
keep up your great work with mods!!!
Excellent mod, works flawlessly! Great job!! :)
sorry for not answering sooner, I am using 1.3 of the admin mod on smf 1.1.10 and tp 1.0b4
clashbot: Can I see a screenshot of your Permissions area?
got it fixed, some of my other modules had created multiple 'board' => array( entries, so dug through managepermissions.php and manually cleaned up the dups, the extranious ")" and adding in the missing ","
very messy in there thanks to mod installs...lol...just took your mod to point it out to me. Works great now, thanks.
Nice Mod
Work fine in SMF 1.1.10
Quote from: Eclipse16V on September 08, 2009, 04:25:21 AM
Nice Mod.
Here is the German:
// Mod Tag MOD
$txt['tag_comment_mod'] = 'Moderator Kommentar';
$txt['tag_comment_gmod'] = 'Globaler Moderator Kommentar';
$txt['tag_comment_admin'] = 'Administrator Kommentar';
$txt['permissiongroup_modtag'] = 'Moderator Tags';
$txt['permissiongroup_simple_modtag'] = 'Moderator Tags';
$txt['permissionname_allow_mod_tag'] = 'Erlaube das nutzen von [mod] ?';
$txt['permissionhelp_allow_mod_tag'] = 'Diese Berechtigung erlaubt es dem User die Funktion [mod] zu nutzen und somit ein "Moderator Kommentar" abzugeben. Diese Kommentare werden NICHT gelöscht wenn der User die Gruppe verlässt.';
$txt['permissionname_allow_gmod_tag'] = 'Erlaube das nutzen von [gmod] ?';
$txt['permissionhelp_allow_gmod_tag'] = 'Diese Berechtigung erlaubt es dem User die Funktion [gmod] zu nutzen und somit ein "Globaler Moderator Kommentar" abzugeben. Diese Kommentare werden NICHT gelöscht wenn der User die Gruppe verlässt.';
$txt['permissionname_allow_admin_tag'] = 'Erlaube das nutzen von [admin] ?';
$txt['permissionhelp_allow_admin_tag'] = 'Diese Berechtigung erlaubt es dem User die Funktion [admin] zu nutzen und somit ein "Adminstrator Kommentar" abzugeben. Diese Kommentare werden NICHT gelöscht wenn der User die Gruppe verlässt.';
Thanks
:D
Sorry I didn't get to this, the last few days has been nightmare-busy.
Adding 1.4 in a moment which adds the German translation, and also fixes the stupid issue that means [mod] is now per board, meaning you can properly assign it to moderators (and they only have it in the boards they are moderators for)
Quote from: Arantor on September 10, 2009, 02:10:42 PM
Sorry I didn't get to this, the last few days has been nightmare-busy.
Adding 1.4 in a moment which adds the German translation, and also fixes the stupid issue that means [mod] is now per board, meaning you can properly assign it to moderators (and they only have it in the boards they are moderators for)
Thanks a lot. Hope you get some break in between.
what changes i need to make to update it for mod for board fix
I have today installed this code manually, And ive seem to have entered the languages for the mod and replaced old file but iam not getting the text string witch says Admin Comment/Quote
Ive attachted a screen shot below to show you.
Rohan_: the changes are quite a few in ManagePermissions.php.
meehan09: Check you have a file named Modifications.english.php in your theme's languages directory.
Yes arantor theres a Modifications.english.php in Themes/languages
Ive attachted this file below.
Well, the string is there.
If you go into the permissions area, do the permissions show up normally? And what language are you using? (It shouldn't matter, the mod should support both variants of English and English-British)
Note I've seen a similar problem with other language strings on your forum as I indicated to you elsewhere, and I see the strings are present there for the other mod we talked about.
Its showing the permissions but no text.
Ive added to modification.english.php and also added in cache lang index modifications.
And iam also using the normal english language ( modifications.egnlish.php ), Ive added the code in both files but doesnt seem to want to show the text in permissions and posts.
Would you be able take a look for me please arantor?
Go into Admin > Maintenance and clear the file cache.
Excellent ;D, that seem to fix the problem and now showing the text.
Thanks alot arantor :)
When i look in error log now iam getting no errors for anything.
Thanks alot and iam error free finally 8)
Quote from: meehan09 on September 10, 2009, 04:51:43 PM
Ive attachted a screen shot below to show you.
meehan09 - I like the round border you have. Can I ask how to do that? Something to modify in the css file?
Arantor, One question - does 1.4 still allow global permission of mod tag for all moderators or is it board permission only?
In 1.4, [mod] is now board-level as it should have always have been, because otherwise they have the ability to use it outside of boards in which they are not moderators. If they are to have the ability to use it outside of those boards, they may as well be global moderators.
Thanks for the explanation. With the board permission, the mod tag is still assigned to membership groups. Perhaps it is for a different set up. In my forum, I have one group called "mod squad" and they are assigned to different boards as moderators. Without separate groups of moderators (e.g. for different boards), how can I assign the mod tag to only a few moderators assigned to a board?
The only way to do that is to have separate groups of moderators and per-board permissions, I'm afraid. Even with the revised per-board permissions, it's still per-board at membergroup level, not sub-membergroup level. Refitting the permissions system to allow only part of a membergroup to have permissions would be an utter nightmare.
That's what I thought. For what the mod is now, it is already very useful. Since I don't have separate groups of moderators, I will stay with 1.3.
The local board permission is driving me nuts and like you said, can be a nightmare.
Fair enough - if it works for you, stick with it :)
Nice mod, works great thanks :)
very nice mod will gonna try this one too soon..
Quote from: funkenwerner on September 01, 2009, 01:50:46 PM
Thanks
Fine Mod
German Language
$txt['tag_comment_mod'] = 'Moderator Kommentar';
$txt['tag_comment_admin'] = 'Administrator Kommentar';
Same for Danish XD
Thanks for the translation except that as of the later versions, there are a lot more strings for the different permissions that are involved.
Sorry, realized that.
Here's the complete Danish translation. Fortunately no special characters there, so it works for UTF-8 as well as ISO-8859-1 :)
$txt['tag_comment_mod'] = 'Moderator kommentar';
$txt['tag_comment_gmod'] = 'Global Moderator kommentar';
$txt['tag_comment_admin'] = 'Administrator kommentar';
$txt['permissiongroup_modtag_g'] = 'Moderator tag kontroller';
$txt['permissiongroup_modtag_b'] = 'Moderator tag kontroller';
$txt['permissiongroup_simple_modtag_g'] = 'Moderator tag kontroller';
$txt['permissiongroup_simple_modtag_b'] = 'Moderator tag kontroller';
$txt['permissionname_allow_mod_tag'] = 'Tillad denne bruger at benytte[mod] ?';
$txt['permissionhelp_allow_mod_tag'] = 'Denne tilladelse tillader brugere i denne gruppe at bruge tag\'et [mod] til "Moderator kommentar" blokke. Disse kommentarer bliver IKKE fjernet hvis brugeren forlader denne gruppe.';
$txt['permissionname_allow_gmod_tag'] = 'Tillad denne bruger at benytte [gmod] ?';
$txt['permissionhelp_allow_gmod_tag'] = 'Denne tilladelse tillader brugere i denne gruppe at bruge tag\'et [gmod] til "Global Moderator kommentar" blokke. Disse kommentarer bliver IKKE fjernet hvis brugeren forlader denne gruppe';
$txt['permissionname_allow_admin_tag'] = 'Tillad denne bruger at benytte [admin] ?';
$txt['permissionhelp_allow_admin_tag'] = 'Denne tilladelse tillader brugere i denne gruppe at bruge tag\'et [admin] til "Adminstrator Comment" blokke. Disse kommentarer bliver IKKE fjernet hvis brugeren forlader denne gruppe.';
Thanks for that Akyhne, I'll add this to the next release in the next day or so :)
i think you could make the mod a little less complicated, but just keeping the 3 standard images in the Default/images folder, and then just use the direct link to the Default image folder.
To me it seems overkill to have the images in all my themes.
It only goes into the default theme's folder, not every theme.
Hmm, in my forum, it asks for the images in the specific theme.
The installation only puts them in the current theme (depending on how you've set it up); it shouldn't be recreating duplicates since there's only one require-file per file, directed at $themedir, which is the 'default' theme directory, usually Themes/default.
Love this mod. One problem though. My theme (Color default) is not showing the block images. It only shows the hover text with a row of ugly white blocks behind the text. All works well in the core default theme. Any way to get the three images where they need to be with the color default themes? Running 1.1.9. Thanks!
I asume you are seing the same as I am seing here:
Copy the images into your "custom themes" images folder
Quote from: Sabre™ on September 15, 2009, 08:56:55 AM
Copy the images into your themes images folder
That's my trouble. It shouldn't really be nessescary, with simple images like these.
Quote from: Akyhne on September 15, 2009, 08:52:51 AM
I asume you are seing the same as I am seing here:
That's what I'm seeing alright. Exactly the same.
Quote from: Sabre™ on September 15, 2009, 08:56:55 AM
Copy the images into your "custom themes" images folder
Themes>images folder, or themes>images>BBC folder?
* update - tried uploading pic in both folders. Still no luck.
Themes/default/images/*_tag.gif to Themes/[yourTheme]/images/*_tag.gif
Thanks! I'll give it a try!
There are 6 images in total. And the installer *cannot* guess which folder to put them in; it has to rely on the default theme's folder.
Themes/default/images/mod_tag.gif -> Themes/yourtheme/images/mod_tag.gif
Themes/default/images/gmod_tag.gif -> Themes/yourtheme/images/gmod_tag.gif
Themes/default/images/admin_tag.gif -> Themes/yourtheme/images/admin_tag.gif
Themes/default/images/bbc/mod.gif -> Themes/yourtheme/images/bbc/mod.gif
Themes/default/images/bbc/gmod.gif -> Themes/yourtheme/images/bbc/gmod.gif
Themes/default/images/bbc/admin.gif -> Themes/yourtheme/images/bbc/admin.gif
This is an underlying issue on SMF where you're using a different theme to core.
I know, but instead of using the $settings['images_url'], you could just call the Default theme image folder.
Apart from the fact that would never be approved, it is possible that users will have reconfigured not to use that.
In any case, the BBcode images *have* to go into the $imagedir directive because they must all be in the same place, and you can't just hotwire it the same way.
hmmm, dont mean to interrupt, but, I installed this and the images are in MY theme not the default, and its loading them from there too (properties of image /Themes/MYTHEME/Images/.
Thus in any case, if the mod was installed properly, regardless of theme, it should work, when you installed you could have forgotten to click "Install in other themes"
It installs to whatever the current 'default' theme is defined as. Works better in 2.0.
Oh yes, I forgot, SMF 1.x does not have that options, SMF 2.x is more sophisticated than SMF 1.x despite been a BETA, anyways, Nice mod, Im using it :) Thanks
Adding the images to my custom themes bbc folder was the only way I could get the images to display.
Without changing the code that is.
But that is with the first version you released, I dont know whether the code has sinced changed(regarding the images), but Im suspecting not.
Dunno how, why, who, what or where ;) but thats just how it worked
No, hasn't changed at all since then.
A lot depends on your exact setup as to whether it'll work or not.
All is working great now. Thanks for the support. Just needed to add the six required images to their respective folders.
We installed this mod and it did not show for directors, admins, or moderators. We also noticed some errors involving permissions, no such file, and more. We made the decision to uninstall the mod, but upon attempting - it is failing all of the tests. It passed the tests while installing - so we are a little concerned. Could we get some assistance please?
Please can I have a few more details, such as the version you're using, the theme you're using, and what errors you got in the error log please?
2.0 RC1.2
Custom theme
You can PM me for the error details if you would like to. Thank you for responding so quickly!
When you say "didn't work" what exactly do you mean? Can you provide screenshots?
The icons for the tags are completely missing. Yes, I can give you screenshots if you need them.
The icons are missing because they've been added to the default theme, not your custom theme, which you'll need to copy:
Quote from: Arantor on September 15, 2009, 09:49:21 AM
There are 6 images in total. And the installer *cannot* guess which folder to put them in; it has to rely on the default theme's folder.
Themes/default/images/mod_tag.gif -> Themes/yourtheme/images/mod_tag.gif
Themes/default/images/gmod_tag.gif -> Themes/yourtheme/images/gmod_tag.gif
Themes/default/images/admin_tag.gif -> Themes/yourtheme/images/admin_tag.gif
Themes/default/images/bbc/mod.gif -> Themes/yourtheme/images/bbc/mod.gif
Themes/default/images/bbc/gmod.gif -> Themes/yourtheme/images/bbc/gmod.gif
Themes/default/images/bbc/admin.gif -> Themes/yourtheme/images/bbc/admin.gif
This is an underlying issue on SMF where you're using a different theme to core.
Okay, I see those in the default. I will copy them over, and get back to you within the hour.
Another concern was being able to use them when we have renamed the root admin accounts to be Directors, the global admin account was changed to Admins, and we created the Moderators from scratch. Can you shed some light on whether the mod can be written to reflect the correct membergroup names?
I have to run out quickly, but will check back directly.
Thank you.
The permissions are applicable at usergroup level, you can assign the Admin and Global Moderator tags to be visible/usable by any group, and Moderator is based on the board moderators group (only; used when you specify moderators in individual boards from the board configuration, though you could change it if you're using per-board configuration)
If you want to change the strings to suit you, you can either:
1) Do so on a per-use basis with:
[admin=Director comment]comment goes here[/admin]
2) Change the default by editing Themes/default/languages/Modifications.english.php and editing the 'Administrator Comment' string and friends there to suit your defaults.
I was able to successfully copy the images to the custom theme, but it still does not show up.
Have you enabled permissions for the different user groups?
I have not been able to find those permission settings. Where would they be located? Wouldn't I be able to see them regardless of the settings, since I am the root admin?
You should be able to see all three as you're the admin.
The others are configured in the Permissions area however - see Members > Permissions for each group, there are 3 tick boxes as indicated in the screenshots for the mod.
Thank you for your response. The permissions are not there hon. Would you be interested in taking a look at the errors?
Sure, please post the errors you're getting.
Here are a couple of errors that were not related to the images needing to be copied to the correct folders.
http://www.soulsinserenity.org/forum/index.php?action=admin;area=packages;sa=install2;package=mod_tag.zip;pid=0
512: package_flush_cache(): some files are still not writable
File: /var/www/vhosts/soulsinserenity.org/httpdocs/forum/Sources/Subs-Package.php
Line: 2421
http://www.soulsinserenity.org/forum/index.php?action=admin;area=packages;sa=install;package=mod_tag.zip
2: fclose(): supplied argument is not a valid stream resource
File: /var/www/vhosts/soulsinserenity.org/httpdocs/forum/Sources/Subs-Package.php
Line: 2424
That suggests that some files could not be edited.
Please can you supply your Sources/ManagePermissions.php file?
Yes, would it be okay if I were to PM that to you for privacy purposes?
You can't PM attachments.
ManagePermissions.php only contains the list of permissions - not who has what.
I had difficulty attaching this and thought I would give it another try.
Hmmm, that's definitely odd. It's not showing any of the edits for permissions at all.
As per http://custom.simplemachines.org/mods/index.php?action=parse;mod=2104;attach=115100;smf_version=2.0_RC1.2 there should be a couple of edits to ManagePermissions.php which likely are the reason it gives you errors.
I understand. We believe the mod can be of good use for us, but obviously can not access it at this time. When we tried to uninstall it, all of the tests were failed (despite passing them during the installation). What can we do at this point?
The tests failed because the mod has not been installed, meaning there's a permissions issue somewhere most likely.
Okay - where do we go from here?
The mod package will not uninstall, and some of the files were written to - but we don't know which.
Well, the link above shows the files that have been modified, and what code was added to them. If you care to attach all those files I'll look them over and apply the necessary edits for you, thus installing the mod.
Thank you for your assistance, it is appreciated. I have attached the files.
Please Try the files below ;D
Nice job, Rohan_ - many thanks to you for all of that!
ohh Arantor please dont thank me .. u dont need to do this .. so did the files worked ?
They look like they contain all the edits necessary so I don't see why they shouldn't work.
hmmm lets wait for the reply of the attachments poster ;)
Thank you, Rohan_ and Arantor
We replaced our files with the new ones and it appears to be functioning properly at this time - meaning we can use it in our posts - however, the permissions are missing (or seems to be). Here are some screenshots of what we currently have.
What language are you using on your forum?
Strictly english.
Just checking - not English-UTF8?
Hmm, did you add the modified Modifications.english.php file to Themes/default/languages/ or to Themes/yourtheme/languages/ ?
No, it is not the UTF8. I added the modifed file into the default/languages. I wondered if this was an error on my part, but noticed there showed two boxes to be checked (instead of three) without the text. I thought it was better to ask than to damage something while trying to pinpoint it.
No, that's as it should be.
Try adding it to Themes/yourtheme/languages as well and see if that works?
Sure, will do. I'll look up the edits for the file and do it manually. I have a few other mods installed and I'm leary that I may alter one by mistake. I'll update you in just a few minutes.
Okay - apparently we do not have that file listed in our theme/languages/
Add the file from here to that directory and see if that fixes it.
I wasn't able to fix the issue as of yet. I looked at the uninstaller just to see if anything had changed. The only file affected still (failing tests) is the /Sources/Subs-Post.php
I would gather this may be the file with a possible error. I have attached it below.
I'll be out for a few hours, but will check back in. Thank you.
Well, I'm not entirely sure what you're asking.
That file contains the edits the mod install made.
It was the only file that appeared to have a problem should I uninstall the mod, so I thought that may be the file with the error preventing the mod to work properly. I'm not real sure of the resolution, and was looking for possible insight.
The only edit to that file is made if users attempt to use the [mod], [gmod] and [admin] tags when they are not authorised to.
It would have no effect on the language issues you've seen in the Permissions area.
Though I am confused as to why it fails to uninstall properly.
Yes, I am as well. I'll keep looking into it and get back to you asap. It will likely be in 1 to 2 hours though, as I am not at home. Thank you for continuing to help.
I have installed your mod on a 2.0-RC2 Forum. This works great! I have just one issue--see the attached picture. The buttons are not showing when editing a message. Note that after having edited a message the icons are shown in the normal message view.
When I look in the HTML source I see this:
{
sType: 'button',
bEnabled: true,
sImage: 'http://forum.nlcomputerforum.nl/Themes/default/images/bbc/.gif',
sCode: 'mod',
sBefore: '[mod]',
sAfter: '[/mod]',
sDescription: 'Moderator Comment'
},
{
sType: 'button',
bEnabled: true,
sImage: 'http://forum.nlcomputerforum.nl/Themes/default/images/bbc/.gif',
sCode: 'gmod',
sBefore: '[gmod]',
sAfter: '[/gmod]',
sDescription: 'Global Moderator Comment'
},
{
sType: 'button',
bEnabled: true,
sImage: 'http://forum.nlcomputerforum.nl/Themes/default/images/bbc/.gif',
sCode: 'admin',
sBefore: '[admin]',
sAfter: '[/admin]',
sDescription: 'Administrator Comment'
},
The picture files are actually right there:
http://forum.nlcomputerforum.nl/Themes/default/images/bbc/admin.gif
http://forum.nlcomputerforum.nl/Themes/default/images/bbc/mod.gif
http://forum.nlcomputerforum.nl/Themes/default/images/bbc/gmod.gif
For some reason, the URL is not complete. How could I solve this?
You need to upload the images from the mod package into your themes images directory :)
Quote from: ♪ JohnCcCcCc ♫ on October 23, 2009, 03:45:54 PM
You need to upload the images from the mod package into your themes images directory :)
Hi John! I'm using the default (Curve) Theme, so I think the images are already where they should be? Or am I missing something :D
Thx, Ronald
You shuold check anyway, sometimes permission issues happen and the files don't get uploaded.
Quote from: ♪ JohnCcCcCc ♫ on October 23, 2009, 03:49:27 PM
You shuold check anyway, sometimes permission issues happen and the files don't get uploaded.
Yeah, they're there, really there, and permissions are ok too. For example, this works: http://forum.nlcomputerforum.nl/Themes/default/images/bbc/admin.gif
The problem is that the actual link to that file is not generated properly:
http://forum.nlcomputerforum.nl/Themes/default/images/bbc/.gif
Note that at the end of this URL it says only '.gif' (not 'admin.gif')
hmmm, Thats strange, the image is defiantly not been linked correctly, and when you right click the area and select properties where the image is supposed to be, there the image links you get?
It won't work properly because I haven't updated the package for the changes in how RC2 works yet. (For each package I have updated for RC2 I am stating it in the mod's page)
In Subs-Editor.php:
if($modtag)
$context['bbc_tags'][$last]['mod'] = array('code' => 'mod', 'before' => '[mod]', 'after' => '[/mod]', 'description' => $txt['tag_comment_mod']);
if($gmodtag)
$context['bbc_tags'][$last]['gmod'] = array('code' => 'gmod', 'before' => '[gmod]', 'after' => '[/gmod]', 'description' => $txt['tag_comment_gmod']);
if($admintag)
$context['bbc_tags'][$last]['admin'] = array('code' => 'admin', 'before' => '[admin]', 'after' => '[/admin]', 'description' => $txt['tag_comment_admin']);
if($modtag)
$context['bbc_tags'][$last][] = array('image' => 'mod', 'code' => 'mod', 'before' => '[mod]', 'after' => '[/mod]', 'description' => $txt['tag_comment_mod']);
if($gmodtag)
$context['bbc_tags'][$last][] = array('image' => 'gmod', 'code' => 'gmod', 'before' => '[gmod]', 'after' => '[/gmod]', 'description' => $txt['tag_comment_gmod']);
if($admintag)
$context['bbc_tags'][$last][] = array('image' => 'admin', 'code' => 'admin', 'before' => '[admin]', 'after' => '[/admin]', 'description' => $txt['tag_comment_admin']);
You'll note the 'image' part was missing from the array; this is why it fails to add the picture in. This is one of the changes made in RC2.
Arrhh RC2, Charter Member, I should have known, He added the "(Curve)" part after I replied, Sometimes assumptions pay off, with no access to RC2, I cant help anyway :-\
Quote from: Arantor on October 23, 2009, 04:05:43 PM
You'll note the 'image' part was missing from the array; this is why it fails to add the picture in. This is one of the changes made in RC2.
Thanks a lot! That indeed has solved the problem :)
Thanks for making all these great mods!!
Quote from: Arantor on September 20, 2009, 02:23:01 PM
The icons are missing because they've been added to the default theme, not your custom theme, which you'll need to copy:
Quote from: Arantor on September 15, 2009, 09:49:21 AM
There are 6 images in total. And the installer *cannot* guess which folder to put them in; it has to rely on the default theme's folder.
Themes/default/images/mod_tag.gif -> Themes/yourtheme/images/mod_tag.gif
Themes/default/images/gmod_tag.gif -> Themes/yourtheme/images/gmod_tag.gif
Themes/default/images/admin_tag.gif -> Themes/yourtheme/images/admin_tag.gif
Themes/default/images/bbc/mod.gif -> Themes/yourtheme/images/bbc/mod.gif
Themes/default/images/bbc/gmod.gif -> Themes/yourtheme/images/bbc/gmod.gif
Themes/default/images/bbc/admin.gif -> Themes/yourtheme/images/bbc/admin.gif
This is an underlying issue on SMF where you're using a different theme to core.
Thanks for the info... it worked :D
Hi guys,
I'm using SMF 1.1.10 with Tinyportal v1.0 beta 4. Also using tinyportal custom theme where i downloaded from the tinyportal official website. The theme is called Class Red TP1. Where it stated for tinyportal theme.
I tried to install this mod on my theme. By looking to the manual installation, it has to modify the Post.template.php file. But, in this theme, the file doesn't exists. So, anybody can help how do i install this mod on this Class Red TP1 theme. Thanks.
It will use that file from the default theme. So you have no need to worry about it.
SMF does this for any template that is not within a custom theme.
So if that is the only file you need to modify in that theme, then just install the mod normally, and it should work.
Quote from: Sabre™ on November 02, 2009, 02:27:14 AM
It will use that file from the default theme. So you have no need to worry about it.
SMF does this for any template that is not within a custom theme.
So if that is the only file you need to modify in that theme, then just install the mod normally, and it should work.
I have installed it. It works fine, but the icon did not load on reply page & also in the topic.
I attached some screen capture of it.
---------------------------------------------------
Ok, have resolved the problem. The images doesn't exists in modify theme. After copy the image to theme folder, it's all perfect. Tq Sabre for fast reply.
lol anytime buddy, I should have mentioned you'd need to copy the images into your custom theme aswell.
Glad you got it sorted :)
Attached is the dutch xml translation. I can't get it working (probably because you need the mod to direct to it) but the Dutch text is OK.
Hope to be helpful in this.
To make the mod action it, it's just a case of having it be called in package-info.xml as well (like all the other language entries)
Thanks for submitting this; I'll get it added shortly :)
OK! Thanks!
Arantor,
Aaron is pulling his MODBREAK MOD in favor of yours.
As we've made a lot of use of MODBREAK, with the changes you've helped to make it work, I was hoping you could help me figure out what changes would need to be made to your package to make use of the tag "modbreak" instead of the moderator tag and the CSS used by MODBREAK.
I know MODBREAK will fail on uninstall and I'll have to manually edit the files with the permissions code, but I'd rather be using a MOD that will also work under 2.0.
Grazie mille!
Well... it depends whether it's board or global permission'd as to which you'd modify. [mod] as it stands is board dependent, like the Moderator group is, so you can assign it to them and they only have it in the boards they're in, while [gmod] and [admin] are globally available on relevant permissions.
Whichever one you want to modify, you would need to modify every instance of that throughout the edits, but that should be pretty much all you have to do.
Which version of 2.0 is it? I'll dig through the list of changes you'd have to make.
Quote from: Pentaxian on November 09, 2009, 11:14:51 AM
Attached is the dutch xml translation. I can't get it working (probably because you need the mod to direct to it) but the Dutch text is OK.
Hope to be helpful in this.
Thanks for this :) Newly updated with version 1.7 which now features the Dutch translation too.
Hi Arantor,
In looking things over, I think I would try to get the MOD tag to use the CSS style that I created for MODBREAK. And I'll give the co-admins access to the MOD tag and pretty much hide the GMOD tag from them.
So, I guess unless you're open to adding fields in the adminCP panel to define the title and CSS section displayed by default for each tag (doesn't hurt to ask, yes? ;) ) I'd just need to know what CSS section to move all the .modbreak style elements into for use by the MOD tag. I can locate and manually edit the default titles easily enough.
Oh, I don't have 2.0 up now. I just want to stay with MODs that will make the transition to 2.0. We're likely to wait for a few bug fix releases and all the MODs we use either going to 2.0 or being part of 2.0 before we migrate from 1.1.10 (I can't afford to try to switch early and possibly break the site).
Grazie!
QuoteFor themers: you can customise the resultant blocks by styling .admin_comment, .gmod_comment and .mod_comment respectively.
Default titles should be in Modifications.{language}.php. No plans to add boxes in the admin CP since I'm not planning to add any more 1.1 features (or indeed, really, planning to mod for 1.1 much longer) and in 2.0 the language editor is built in.
This is the part that I'm having trouble with: is it something you're assigning to a board-specific user (i.e. a user group like Moderator, that applies per board) or to the whole group?
If the former, modify [mod], if the latter, modify [admin]. The icon it adds isn't styled in CSS, you'll have to modify the function for that.
If the other users are true admin users, your best approach would be to actually strip out the tags you don't want since admins implicitly have all permissions so will have all three out of the box.
Installed on smf 2 RC2 and I can't see it on default topic.
What do you mean, you can't see it?
Are you an admin at the time of posting?
sorry I meant default template not topic
I'm admin and I see no tags. I tried reinstalling but all the same
So where are you looking? Screenshots would be handy too.
(http://www.imagesforme.com/thumb/thumb_7646471c.jpg) (http://www.imagesforme.com/show.php/781702_1.jpg)
I tried manually with tags but no result
What version of the mod are you using?
1.7
Did you get any errors during installation?
Please attach your Sources/Subs-Editor.php file.
no the installation went fine, all successfull.
Weird, very weird. The edits are listed and the same work absolutely fine for me, which is a fresh 2.0 RC2 (public) install.
What happens if you try using the tags manually?
all I get is a normal post like nothing happens
Please can you also attach Sources/Subs.php and Sources/ManagePermissions.php please?
sure
Hmmm, very very strange.
Random question: In the permissions area, under General Permissions, it lists the different assigned groups, how many users in them and how many permissions they have. How many are listed for Administrator? (It should say 'all' but I've seen some situations where it doesn't)
I see where the problem is. Only 1 account belongs to administrator group but 2 other accounts have admin permissions. When I log in with my Admin acc I can see the tags, when I use the other acc which has admin permissions I don't see the tags. The question is how do I make this work for other 2 accounts and for my moderators
For their membergroups, go into the permissions and grant them to their groups.
I'm not sure I understand. I just checked permissions for global mods and mods and I can't find anything about this tags.
Classic view: top half of the permission list, right column, under the heading of "Moderator tag controls", with "Allow this user to use [gmod]" and "Allow this user to use [admin]", then for board-specific, bottom right corner of the page, under the same heading, "Allow this user to use [mod]".
Simple view: under the 'Moderator tag controls' headings, should be at the bottom of each list.
got it working, thanks
I have a question, if the user edits the post again after the administrator used the [admin] tags, does it get removed because the user doesn't have the right to use it?
Yes it does.
Only a suitably privileged user can be the one pressing the edit button at the time; it will be stripped otherwise, regardless of the post's owner.
Works exactly the same as [html]
Quote from: Arantor on November 15, 2009, 09:28:08 PM
Yes it does.
Only a suitably privileged user can be the one pressing the edit button at the time; it will be stripped otherwise, regardless of the post's owner.
Works exactly the same as [html]
So the user can remove the mod tags easily then.
There's no way around that, just like there isn't for the html bbcode.
Admin should use a new post, then users can't get around it.
Make the post uneditable by a lower group afterwards?
No, the admin creates a post to hold the moderation. If it's deemed important to keep the post that caused the moderation to remain unchanged, then quote it in the Admin's post, followed by the moderation.
This way, no one can alter the moderation or the demonstration of why moderation was performed. After all, the original poster could alter the post and then try to claim the moderation was not justified.
Generally, an Admin altering another member's post to insert a moderation is not a good idea. Altering it to remove inappropriate material can be, but inserting a moderation is not.
Cal
To be honest, I have never seen a forum whereby the admin/moderators edited a given post to add moderation notes, unless the admin/moderation note is held separately to the message itself and otherwise cannot be altered... OR, the user was banned for what they posted, so they are not able to edit the post anyway.
I get a very strange error!
in the top of my index page all the html codes apear???
Look for image!
Please help, i want to use the mod....
Using 1.1.10 and babylon theme, language Dutch..
Thanx
gr
Look at your lang file.
there is a problem.
Ok, but what is the problem? Dutch is supported right?
Gr
How did you install it with the Dutch language?
Yes, i just downloaded the mod_tag zip file, uploaded it and install it, automatically it choose the dutch language....
If i look to the modifications.dutch.ph i see this at the end:
Quote$txt['profile_error_award_no_title'] = 'No title has been given for the award';
?>
$txt['tag_comment_mod'] = 'Commentaar van de moderator';
$txt['tag_comment_gmod'] = 'Commentaar van de groepsmoderator';
$txt['tag_comment_admin'] = 'Commentaar van de forumbeheerder';
$txt['permissiongroup_modtag_g'] = 'Moderatortag parameters';
$txt['permissiongroup_modtag_b'] = 'Moderatortag parameters';
$txt['permissiongroup_simple_modtag_g'] = 'Moderatortag parameters';
$txt['permissiongroup_simple_modtag_b'] = 'Moderatortag parameters';
$txt['permissionname_allow_mod_tag'] = 'Sta deze gebruiker het gebruiken van [mod] toe?';
$txt['permissionhelp_allow_mod_tag'] = 'Deze permissie staat de gebruikers in deze groep toe de moderatortag [mod] te gebruiken en daarmee een 'Commentaar van de moderator' te plaatsen. Deze commentaren worden niet verwijderd als de gebruiker deze groep verlaat.';
$txt['permissionname_allow_gmod_tag'] = 'Sta deze gebruiker het gebruiken van [gmod] toe?';
$txt['permissionhelp_allow_gmod_tag'] = 'Deze permissie staat de gebruikers in deze groep toe de moderatortag [gmod] te gebruiken en daarmee een 'Commentaar van de moderator' te plaatsen. Deze commentaren worden niet verwijderd als de gebruiker deze groep verlaat.';
$txt['permissionname_allow_admin_tag'] = 'Sta deze gebruiker het gebruiken van [admin] toe?';
$txt['permissionhelp_allow_admin_tag'] = 'Deze permissie staat de gebruikers in deze groep toe de moderatortag [admin] te gebruiken en daarmee een 'Commentaar van de moderator' te plaatsen. Deze commentaren worden niet verwijderd als de gebruiker deze groep verlaat.';
You see that the (?>) is not at the end? but it must be right?
If i manually change it and put the (?>) at the end i get a template error when showing my forum index...
Don't get it ::)
Gr
Ok Found it!!! The dutch translation of moderator comment was between '.........' but it must be "........." !
So this one is the right one:
Quote$txt['tag_comment_mod'] = 'Commentaar van de moderator';
$txt['tag_comment_gmod'] = 'Commentaar van de groepsmoderator';
$txt['tag_comment_admin'] = 'Commentaar van de forumbeheerder';
$txt['permissiongroup_modtag_g'] = 'Moderatortag parameters';
$txt['permissiongroup_modtag_b'] = 'Moderatortag parameters';
$txt['permissiongroup_simple_modtag_g'] = 'Moderatortag parameters';
$txt['permissiongroup_simple_modtag_b'] = 'Moderatortag parameters';
$txt['permissionname_allow_mod_tag'] = 'Sta deze gebruiker het gebruiken van [mod] toe?';
$txt['permissionhelp_allow_mod_tag'] = 'Deze permissie staat de gebruikers in deze groep toe de moderatortag [mod] te gebruiken en daarmee een "Commentaar van de moderator" te plaatsen. Deze commentaren worden niet verwijderd als de gebruiker deze groep verlaat.';
$txt['permissionname_allow_gmod_tag'] = 'Sta deze gebruiker het gebruiken van [gmod] toe?';
$txt['permissionhelp_allow_gmod_tag'] = 'Deze permissie staat de gebruikers in deze groep toe de moderatortag [gmod] te gebruiken en daarmee een "Commentaar van de moderator" te plaatsen. Deze commentaren worden niet verwijderd als de gebruiker deze groep verlaat.';
$txt['permissionname_allow_admin_tag'] = 'Sta deze gebruiker het gebruiken van [admin] toe?';
$txt['permissionhelp_allow_admin_tag'] = 'Deze permissie staat de gebruikers in deze groep toe de moderatortag [admin] te gebruiken en daarmee een "Commentaar van de moderator" te plaatsen. Deze commentaren worden niet verwijderd als de gebruiker deze groep verlaat.';
:D
Gr
Quote from: Welb on November 21, 2009, 06:48:27 AM
Ok Found it!!! The dutch translation of moderator comment was between '.........' but it must be "........." !
So this one is the right one:
Quote$txt['tag_comment_mod'] = 'Commentaar van de moderator';
$txt['tag_comment_gmod'] = 'Commentaar van de groepsmoderator';
$txt['tag_comment_admin'] = 'Commentaar van de forumbeheerder';
$txt['permissiongroup_modtag_g'] = 'Moderatortag parameters';
$txt['permissiongroup_modtag_b'] = 'Moderatortag parameters';
$txt['permissiongroup_simple_modtag_g'] = 'Moderatortag parameters';
$txt['permissiongroup_simple_modtag_b'] = 'Moderatortag parameters';
$txt['permissionname_allow_mod_tag'] = 'Sta deze gebruiker het gebruiken van [mod] toe?';
$txt['permissionhelp_allow_mod_tag'] = 'Deze permissie staat de gebruikers in deze groep toe de moderatortag [mod] te gebruiken en daarmee een "Commentaar van de moderator" te plaatsen. Deze commentaren worden niet verwijderd als de gebruiker deze groep verlaat.';
$txt['permissionname_allow_gmod_tag'] = 'Sta deze gebruiker het gebruiken van [gmod] toe?';
$txt['permissionhelp_allow_gmod_tag'] = 'Deze permissie staat de gebruikers in deze groep toe de moderatortag [gmod] te gebruiken en daarmee een "Commentaar van de moderator" te plaatsen. Deze commentaren worden niet verwijderd als de gebruiker deze groep verlaat.';
$txt['permissionname_allow_admin_tag'] = 'Sta deze gebruiker het gebruiken van [admin] toe?';
$txt['permissionhelp_allow_admin_tag'] = 'Deze permissie staat de gebruikers in deze groep toe de moderatortag [admin] te gebruiken en daarmee een "Commentaar van de moderator" te plaatsen. Deze commentaren worden niet verwijderd als de gebruiker deze groep verlaat.';
:D
Gr
Or \'Commentaar van de moderator\'
I just used the one I was given; didn't occur to me to check it too deeply, but oddly it should still have installed *before* the closing ?> not after it.
I've uploaded a new one to the site; not bumped version numbers though.
It did installed after the closing ?> but now i have install it manually , change the text and it works....
Gr
The one I have works fine in testing though :-/ I did update the site version earlier on today with the same one I have.
Ok, then it should be fine, on my forum it works....thanks, and you, you have another bug away ;)
Gr
Why Admins see tags but moderators not?
Language is Finnish UTF-8.
Because you need to enable them in the permissions?
russian translation
Hello...
i have a strange problem as everything installed very well and i have checked the manual instructions and everything there correct nothing wrong...
but the problem no admin mod gmod tag appear just icon no more...i'm using smf 1.1.11 with costume theme
so have a look at this pic
(http://i47.tinypic.com/20a8e8x.jpg)
any help plz?
I need to see an actual post with that in so I can see the code being used by the website. It's something in your theme that my mod doesn't seem to like.
$txt['tag_comment_mod'] = 'Comentário do Moderador';
$txt['tag_comment_gmod'] = 'Comentário do Moderador Global';
$txt['tag_comment_admin'] = 'Comentário do Administrador';
$txt['permissiongroup_modtag_g'] = 'Controlos da tag Moderador';
$txt['permissiongroup_modtag_b'] = 'Controlos da tag Moderador';
$txt['permissiongroup_simple_modtag_g'] = 'Controlos da tag Moderador';
$txt['permissiongroup_simple_modtag_b'] = 'Controlos da tag Moderador';
$txt['permissionname_allow_mod_tag'] = 'Permitir que o usuário use a tag [mod]?';
$txt['permissionhelp_allow_mod_tag'] = 'Esta permissão permite que os usuários deste grupo usem a tag [mod] para os blocos de "Comentário do Moderador". Os comentários adicionados <strong>não</strong> são removidos se o usuário deixa este grupo.';
$txt['permissionname_allow_gmod_tag'] = 'Permitir que o usuário use a tag [gmod] ?';
$txt['permissionhelp_allow_gmod_tag'] = 'Esta permissão permite que os usuários deste grupo usem a tag [mod] para os blocos de "Comentário do Moderador Global". Os comentários adicionados <strong>não</strong> são removidos se o usuário deixa este grupo.';
$txt['permissionname_allow_admin_tag'] = 'Permitir que o usuário use a tag [admin] ?';
$txt['permissionhelp_allow_admin_tag'] = 'Esta permissão permite que os usuários deste grupo usem a tag [mod] para os blocos de "Comentário do Administrador". Os comentários adicionados <strong>não</strong> são removidos se o usuário deixa este grupo.';
$txt['tag_comment_mod'] = 'Comentário do Moderador';
$txt['tag_comment_gmod'] = 'Comentário do Moderador Global';
$txt['tag_comment_admin'] = 'Comentário do Administrador';
$txt['permissiongroup_modtag_g'] = 'Controlos da tag Moderador';
$txt['permissiongroup_modtag_b'] = 'Controlos da tag Moderador';
$txt['permissiongroup_simple_modtag_g'] = 'Controlos da tag Moderador';
$txt['permissiongroup_simple_modtag_b'] = 'Controlos da tag Moderador';
$txt['permissionname_allow_mod_tag'] = 'Permitir que o usuário use a tag [mod]?';
$txt['permissionhelp_allow_mod_tag'] = 'Esta permissão permite que os usuários deste grupo usem a tag [mod] para os blocos de "Comentário do Moderador". Os comentários adicionados <strong>não</strong> são removidos se o usuário deixa este grupo.';
$txt['permissionname_allow_gmod_tag'] = 'Permitir que o usuário use a tag [gmod] ?';
$txt['permissionhelp_allow_gmod_tag'] = 'Esta permissão permite que os usuários deste grupo usem a tag [mod] para os blocos de "Comentário do Moderador Global". Os comentários adicionados <strong>não</strong> são removidos se o usuário deixa este grupo.';
$txt['permissionname_allow_admin_tag'] = 'Permitir que o usuário use a tag [admin] ?';
$txt['permissionhelp_allow_admin_tag'] = 'Esta permissão permite que os usuários deste grupo usem a tag [mod] para os blocos de "Comentário do Administrador". Os comentários adicionados <strong>não</strong> são removidos se o usuário deixa este grupo.';
$txt['tag_comment_mod'] = 'Comentário do Moderador';
$txt['tag_comment_gmod'] = 'Comentário do Moderador Global';
$txt['tag_comment_admin'] = 'Comentário do Administrador';
$txt['permissiongroup_modtag_g'] = 'Controlos da tag Moderador';
$txt['permissiongroup_modtag_b'] = 'Controlos da tag Moderador';
$txt['permissiongroup_simple_modtag_g'] = 'Controlos da tag Moderador';
$txt['permissiongroup_simple_modtag_b'] = 'Controlos da tag Moderador';
$txt['permissionname_allow_mod_tag'] = 'Permitir que o usuário use a tag [mod]?';
$txt['permissionhelp_allow_mod_tag'] = 'Esta permissão permite que os usuários deste grupo usem a tag [mod] para os blocos de "Comentário do Moderador". Os comentários adicionados <strong>não</strong> são removidos se o usuário deixa este grupo.';
$txt['permissionname_allow_gmod_tag'] = 'Permitir que o usuário use a tag [gmod] ?';
$txt['permissionhelp_allow_gmod_tag'] = 'Esta permissão permite que os usuários deste grupo usem a tag [mod] para os blocos de "Comentário do Moderador Global". Os comentários adicionados <strong>não</strong> são removidos se o usuário deixa este grupo.';
$txt['permissionname_allow_admin_tag'] = 'Permitir que o usuário use a tag [admin] ?';
$txt['permissionhelp_allow_admin_tag'] = 'Esta permissão permite que os usuários deste grupo usem a tag [mod] para os blocos de "Comentário do Administrador". Os comentários adicionados <strong>não</strong> são removidos se o usuário deixa este grupo.';
$txt['tag_comment_mod'] = 'Comentário do Moderador';
$txt['tag_comment_gmod'] = 'Comentário do Moderador Global';
$txt['tag_comment_admin'] = 'Comentário do Administrador';
$txt['permissiongroup_modtag_g'] = 'Controlos da tag Moderador';
$txt['permissiongroup_modtag_b'] = 'Controlos da tag Moderador';
$txt['permissiongroup_simple_modtag_g'] = 'Controlos da tag Moderador';
$txt['permissiongroup_simple_modtag_b'] = 'Controlos da tag Moderador';
$txt['permissionname_allow_mod_tag'] = 'Permitir que o usuário use a tag [mod]?';
$txt['permissionhelp_allow_mod_tag'] = 'Esta permissão permite que os usuários deste grupo usem a tag [mod] para os blocos de "Comentário do Moderador". Os comentários adicionados <strong>não</strong> são removidos se o usuário deixa este grupo.';
$txt['permissionname_allow_gmod_tag'] = 'Permitir que o usuário use a tag [gmod] ?';
$txt['permissionhelp_allow_gmod_tag'] = 'Esta permissão permite que os usuários deste grupo usem a tag [mod] para os blocos de "Comentário do Moderador Global". Os comentários adicionados <strong>não</strong> são removidos se o usuário deixa este grupo.';
$txt['permissionname_allow_admin_tag'] = 'Permitir que o usuário use a tag [admin] ?';
$txt['permissionhelp_allow_admin_tag'] = 'Esta permissão permite que os usuários deste grupo usem a tag [mod] para os blocos de "Comentário do Administrador". Os comentários adicionados <strong>não</strong> são removidos se o usuário deixa este grupo.';
Thanks, Costa :) I'll add that to the next version along with another translation I have.
You're welcome :)
Quote from: The Grinch on December 20, 2009, 09:57:02 AM
I need to see an actual post with that in so I can see the code being used by the website. It's something in your theme that my mod doesn't seem to like.
Okay thanks for answer....
here's the actual pic i have changed the theme also and tried in clean install for smf 1.1.11 and the same problem(http://i47.tinypic.com/1nzssn.jpg)
I still need to see a link to that page. I CANNOT help you without a link.
Quote from: The Grinch on December 20, 2009, 11:41:36 AM
I still need to see a link to that page. I CANNOT help you without a link.
okay here's a test page
http://www.egyptoboy.com/test2/index.php?topic=2.0
And I need to see it with the theme you have. For me on that link, it's using the default theme, which it works fine on.
All give me the same result i have tried with the default theme and tried in a just installed smf 1.1.11 and tried in my current theme but so all show me the same thing the icon appear but with no tag word beside....
can u help?
From the link you gave me, it works entirely as it is designed to. Please see the attached.
that's strange really....for my self i cant see that from my side but from your side u can that's funny m8 :D
btw thanks alot i just need that other can see so np about my self ;D
Change the default theme for the forum to be the same one you have, so even guests can see it, and then reply here and I'll take another look.
Look here bro at my actual forums
http://www.yovilleonline.com/index.php/topic,6249.msg38346.html#msg38346
the other pic i show u were for testing and the same problem without using any theme
That one also works properly for me.
Thanks bro.....i cant see it to work from the admin group but works for the whole members group....thanks for the help man
So does the admin have a different theme or something?
no bro the same theme and also i have tried for a clean install in a diff domain with the same problem only admin group can't see it works as i show you in the pic but u saw it with no problem...idk what's wrong that's strange
That is pretty weird, it's nothing I've encountered before. Suggests you've got another mod that adds something only to admin logins.
Hi arantor, in my admin panel, i only see the controls related to the "mod" tag and not the Global Mob and Admin...why? see this
Because that's the board specific permission. The others are assigned in the general permissions area.
ok i just saw them. ...tnx a lot for this great package arantor, it's simply awesome ;)
Glad you like it :)
Nice mod!
but i got an issue.
I am using 2.0 RC2 and when i type 2 lines between [admin] tags, in the post there is no \n between the lines. (don't know how to say \n in english :P )
Using WYSIWYG or not?
not using WYSIWYG
example in attachement
That's very very weird. I need to sit and thoroughly investigate this one, but it's not something I came across :-\
I installed this on my forum running 1.1.11 and right after it was installed all i get when i try and go the the forum is Fatal error: Cannot redeclare get_mod_comment() (previously declared in /home/foodies4/public_html/foodieforum/Sources/Subs.php:3761) in /home/foodies4/public_html/foodieforum/Sources/Subs.php on line 3781 i am unable to get into the admin page to remove it or anything please help
Quote from: CoolChef on January 29, 2010, 06:43:20 PM
I installed this on my forum running 1.1.11 and right after it was installed all i get when i try and go the the forum is Fatal error: Cannot redeclare get_mod_comment() (previously declared in /home/foodies4/public_html/foodieforum/Sources/Subs.php:3761) in /home/foodies4/public_html/foodieforum/Sources/Subs.php on line 3781 i am unable to get into the admin page to remove it or anything please help
You clicked the install button twice. You'll need to manually edit Subs.php to remove some code.
Quote from: Arantor on January 30, 2010, 12:38:00 AM
Quote from: CoolChef on January 29, 2010, 06:43:20 PM
I installed this on my forum running 1.1.11 and right after it was installed all i get when i try and go the the forum is Fatal error: Cannot redeclare get_mod_comment() (previously declared in /home/foodies4/public_html/foodieforum/Sources/Subs.php:3761) in /home/foodies4/public_html/foodieforum/Sources/Subs.php on line 3781 i am unable to get into the admin page to remove it or anything please help
You clicked the install button twice. You'll need to manually edit Subs.php to remove some code.
What code do i need to remove?
Hello,
I had this mod for a bit now. It was working fine, but for some reason as a Admin having all the permissions, I cannot see the BBC tag buttons for some reason.
I created a dummy user as a Global mod, even with the setting of allowance of using this mod, I was unsuccessful in seeing the BBC buttons...
However the tags work with the post and show up if I use them.
The Mod was installed on the default "theme". EDIT
Not sure why its not working, please let me know why.
Thank you.
Any errors in the log?
Quote from: CoolChef on January 30, 2010, 04:01:51 PM
Quote from: Arantor on January 30, 2010, 12:38:00 AM
Quote from: CoolChef on January 29, 2010, 06:43:20 PM
I installed this on my forum running 1.1.11 and right after it was installed all i get when i try and go the the forum is Fatal error: Cannot redeclare get_mod_comment() (previously declared in /home/foodies4/public_html/foodieforum/Sources/Subs.php:3761) in /home/foodies4/public_html/foodieforum/Sources/Subs.php on line 3781 i am unable to get into the admin page to remove it or anything please help
You clicked the install button twice. You'll need to manually edit Subs.php to remove some code.
What code do i need to remove?
If you attach it I may look
SMF 2.0 RC 2
I just reread your post and noticed "The Mod was installed on the default mod"
Default theme? Do you use the default theme?
Did you install manually or via the package manager?
Sorry I meant theme.
Quote from: live627 on January 30, 2010, 05:20:21 PM
Did you install manually or via the package manager?
Package manager...
Quote from: live627 on January 30, 2010, 05:07:55 PM
Quote from: CoolChef on January 30, 2010, 04:01:51 PM
Quote from: Arantor on January 30, 2010, 12:38:00 AM
Quote from: CoolChef on January 29, 2010, 06:43:20 PM
I installed this on my forum running 1.1.11 and right after it was installed all i get when i try and go the the forum is Fatal error: Cannot redeclare get_mod_comment() (previously declared in /home/foodies4/public_html/foodieforum/Sources/Subs.php:3761) in /home/foodies4/public_html/foodieforum/Sources/Subs.php on line 3781 i am unable to get into the admin page to remove it or anything please help
You clicked the install button twice. You'll need to manually edit Subs.php to remove some code.
What code do i need to remove?
If you attach it I may look
27. Extract File ./Themes/default/images/bbc/mod.gif
28. Extract File ./Themes/default/images/bbc/admin.gif
29. Extract File ./Themes/default/images/bbc/gmod.gif
30. Extract File ./Themes/default/images/mod_tag.gif
31. Extract File ./Themes/default/images/admin_tag.gif
32. Extract File ./Themes/default/images/gmod_tag.gif
@Vyache: Are those image files in place?
Quote from: CoolChef on January 30, 2010, 05:45:22 PM
Quote from: live627 on January 30, 2010, 05:07:55 PM
Quote from: CoolChef on January 30, 2010, 04:01:51 PM
Quote from: Arantor on January 30, 2010, 12:38:00 AM
Quote from: CoolChef on January 29, 2010, 06:43:20 PM
I installed this on my forum running 1.1.11 and right after it was installed all i get when i try and go the the forum is Fatal error: Cannot redeclare get_mod_comment() (previously declared in /home/foodies4/public_html/foodieforum/Sources/Subs.php:3761) in /home/foodies4/public_html/foodieforum/Sources/Subs.php on line 3781 i am unable to get into the admin page to remove it or anything please help
You clicked the install button twice. You'll need to manually edit Subs.php to remove some code.
What code do i need to remove?
If you attach it I may look
I removed the extra function...
Quote from: live627 on January 30, 2010, 05:48:38 PM
27. Extract File ./Themes/default/images/bbc/mod.gif
28. Extract File ./Themes/default/images/bbc/admin.gif
29. Extract File ./Themes/default/images/bbc/gmod.gif
30. Extract File ./Themes/default/images/mod_tag.gif
31. Extract File ./Themes/default/images/admin_tag.gif
32. Extract File ./Themes/default/images/gmod_tag.gif
@Vyache: Are those image files in place?
Yes these are in place...
Quote from: live627 on January 30, 2010, 05:48:38 PM
27. Extract File ./Themes/default/images/bbc/mod.gif
28. Extract File ./Themes/default/images/bbc/admin.gif
29. Extract File ./Themes/default/images/bbc/gmod.gif
30. Extract File ./Themes/default/images/mod_tag.gif
31. Extract File ./Themes/default/images/admin_tag.gif
32. Extract File ./Themes/default/images/gmod_tag.gif
@Vyache: Are those image files in place?
Yes, you just have to FTP into your site and copy all six to your local computer, and upload each of those files to all your themes, in the same folder in each folder...
Is the folllowing code in ./Sources/Subs-Editor.php?
$modtag = allowedTo('allow_mod_tag');
$gmodtag = allowedTo('allow_gmod_tag');
$admintag = allowedTo('allow_admin_tag');
if($modtag || $gmodtag || $admintag) {
$last = count($context['bbc_tags']) - 1;
$context['bbc_tags'][$last][] = array();
if($modtag)
$context['bbc_tags'][$last][] = array('image' => 'mod', 'code' => 'mod', 'before' => '[mod]', 'after' => '[/mod]', 'description' => $txt['tag_comment_mod']);
if($gmodtag)
$context['bbc_tags'][$last][] = array('image' => 'gmod', 'code' => 'gmod', 'before' => '[gmod]', 'after' => '[/gmod]', 'description' => $txt['tag_comment_gmod']);
if($admintag)
$context['bbc_tags'][$last][] = array('image' => 'admin', 'code' => 'admin', 'before' => '[admin]', 'after' => '[/admin]', 'description' => $txt['tag_comment_admin']);
}
My code:
// Add the moderator/admin comment buttons
$modtag = allowedTo('allow_mod_tag');
$gmodtag = allowedTo('allow_gmod_tag');
$admintag = allowedTo('allow_admin_tag');
if($modtag || $gmodtag || $admintag) {
$last = count($context['bbc_tags']) - 1;
$context['bbc_tags'][$last][] = array();
if($modtag)
$context['bbc_tags'][$last][] = array('image' => 'mod', 'code' => 'mod', 'before' => '[mod]', 'after' => '[/mod]', 'description' => $txt['tag_comment_mod']);
if($gmodtag)
$context['bbc_tags'][$last][] = array('image' => 'gmod', 'code' => 'gmod', 'before' => '[gmod]', 'after' => '[/gmod]', 'description' => $txt['tag_comment_gmod']);
if($admintag)
$context['bbc_tags'][$last][] = array('image' => 'admin', 'code' => 'admin', 'before' => '[admin]', 'after' => '[/admin]', 'description' => $txt['tag_comment_admin']);
}
The only think I can think of is allowedTo() returns false :P
But you said even admin couldn't see the button. I hope the original mod author can help out here :S
Its a mod conflict, I tested this thing on my test forum, I trying to locate it.
So what other mods do you have?
I have the following mods... Not sure what caused the problem...
1. Aeva Media
2. Moderator and Administrator Comment Tags
3. Ajax-Chat Integration
4. Sort-able Packages
5. Simple Portal
6. Custom Portal
7. Ad Management
8. Footnotes
9. Nice-Tooltips
10. reCAPTCHA for SMF
11. Registration Password
12. PMXBlog
13. Yet Another Global Announcements Mod
14. SA Affiliates
15. SMF Articles
16. Team Page
17. Treasury
18. Simple Award System
19. Topic Note
20. Word Description
21. eNinja - Admin Notes
22. BackGround Tag
23. InfoBox
24. Signature Dropdown Choices
25. Search Focus Dropdown
26. Proxy Blocker
27. Member Color Link
28. Images on Print Page
29. Add Honey Pot to Track IP
30. Favicon
31. Dynamic_Memberlist
32. Custom Field On Posting
33. Buddy Page
34. Curve mobile mod
35. Apache Error Handler
36. Active Members In Topic
37. Admin member list registration date
38. Site Menu
Hmm. Can you attach your Subs-Editor.php file please? Something is breaking it - if you're an admin, allowedTo returns immediately with true without performing any other checks.
Nice modification Arantor!
Czech language
http://www.simplemachines.org/community/index.php?topic=301494.msg2481715#msg2481715
Thanks - I'll add that in to the next version.
@Arantor
Here is the Sub-Editor.php file...
Quote from: Vyache on January 31, 2010, 01:31:28 PM
@Arantor
Here is the Sub-Editor.php file...
The modification is in the file yet installed!
Yeah, I can't see anything wrong with the code here.
Please can I have a screenshot of you as an admin on the full posting screen?
Quote from: live627 on January 30, 2010, 05:51:56 PM
Quote from: CoolChef on January 30, 2010, 05:45:22 PM
Quote from: live627 on January 30, 2010, 05:07:55 PM
Quote from: CoolChef on January 30, 2010, 04:01:51 PM
Quote from: Arantor on January 30, 2010, 12:38:00 AM
Quote from: CoolChef on January 29, 2010, 06:43:20 PM
I installed this on my forum running 1.1.11 and right after it was installed all i get when i try and go the the forum is Fatal error: Cannot redeclare get_mod_comment() (previously declared in /home/foodies4/public_html/foodieforum/Sources/Subs.php:3761) in /home/foodies4/public_html/foodieforum/Sources/Subs.php on line 3781 i am unable to get into the admin page to remove it or anything please help
You clicked the install button twice. You'll need to manually edit Subs.php to remove some code.
What code do i need to remove?
If you attach it I may look
I removed the extra function...
Thank You SO Much Live627 that fixed it perfectly.
@Arantor,
Yea, it isn't. I accidentally gave you the wrong file. I reinstalled my forum and it seems to be working fine now, I guess it might of been something left over in the SQL or Permissions...
SOLVED
Updated russian translation
Hey everyone.
Arantor has (generously :D) given me this Modification. I will be trying my best to address any support questions, issues, and feature requests.
Thanks again, Arantor!
That's great, Ha2! Now I can stop helping people with this mod, heh :P
Thanks to both of you for taking care of it; this has been an awesome mod to be involved with during its life but it was time to let it go, I think.
I read through all the posts, But I'm stuck on how to change the Border.. It says your "CSS file for your forum - style.css in your theme."
But where do I edit this??? I'm looking through my theme & cannot find "style.css" Using Curve Default, Please tell me step by step where do I need to go to edit this for change of border color.
Thanks all!
Use your theme's index.css instead.
Quote from: Arantor on February 23, 2010, 08:11:58 PM
Use your theme's index.css instead.
Ok, Looking REALLY hard I see /httpdocs/Themes/default/style.css.. Is that where I edit? If so How? Because I can not find the codes mentioned in the earlier post? Or do I have to just add them? Sorry, I'm usually pretty decent in all this code stuff but this one has got me stuck. Thanks for the quick response! Please if you can just tell me exactly what I need to do again.. I would really appreciate it
Hey,
A link to your forum would really help so I could see for myself exactly what file you need to make the edits in. Also, exact desired definitions on the new border (color, width, and whether it will be dashed or dotted) you are seeking could allow me to write the CSS for you.
Quote from: Ha² on February 23, 2010, 08:53:06 PM
Hey,
A link to your forum would really help so I could see for myself exactly what file you need to make the edits in. Also, exact desired definitions on the new border (color, width, and whether it will be dashed or dotted) you are seeking could allow me to write the CSS for you.
Ok here is my site
I made you a member since guest do not have full access
Oh & I just want to make the border red
Try opening /Themes/default/css/index.css and adding this to the end of it:
.mod_comment, .gmod_comment, .admin_comment
{
border-color: red;
}
You may have to clear your browser's cache.
It worked!! Thank you so much!!
(http://i48.tinypic.com/s4117r.png)
But what if in the future, I wanted to make a background color inside the box, can that be done?
Sure can... Try replacing the code I posted above with:
.mod_comment, .gmod_comment, .admin_comment
{
border-color: red;
background: yourcolorhere; /* Replace "yourcolorhere" with your desired background color ;) */
}
Thank you so much for your help! (http://bxmedialinks.com/Smileys/BxSmileys/yourock.gif)
No problem at all. :) If you've got more questions, feel free to ask.
Can someone tell my if this is SMF 2.0 RC3 compatible ?
I don't see any reason why it shouldn't be barring a change of version tag.
Suggestion: backup forum then use the version emulate tool (Admin > Packages > Browse Packages > Advanced > enter SMF 2.0 RC2)
As far as I know it should work without any changes.
/me updates the Mod for RC3.
Updated for RC3.
Thanks Ha! When I upgrade, I will do this!
I installed this today on RC3 (default curve theme)... and the permissions seem to be ignored. Even guests can see all 3 comment boxes.
* Set the permissions for globalmods and mods... and made sure the permission where not set for guests or regular members.
Anyone else having this issue or am I missing something?
Thanks.
Quote from: Pegasys on March 12, 2010, 04:04:21 PM
I installed this today on RC3 (default curve theme)... and the permissions seem to be ignored. Even guests can see all 3 comment boxes.
* Set the permissions for globalmods and mods... and made sure the permission where not set for guests or regular members.
Anyone else having this issue or am I missing something?
Thanks.
Are you saying that the guest can see the box, or that the guest can post the box? The permissions only prevent people from posting the box (using the [mod]/[gmod]/[admin] BBC), not from viewing it. :)
Quote from: Ha² on March 12, 2010, 04:14:15 PM
Are you saying that the guest can see the box, or that the guest can post the box? The permissions only prevent people from posting the box (using the [mod]/[gmod]/[admin] BBC), not from viewing it. :)
Hehehe... my misconception. I misunderstood what the purpose of the comment blocks was for. The buttons are indeed hidden from those not authorized to use them.
Thanks.
Yeah, the idea is a big warning that makes the comments from admin/gmod/mod stand out more and makes it more 'official'.
Hi there, I love this mod! I was wondering if someone could help me on putting the buttons on Quick Reply as well? I have custom themes, so if you could just tell me where in the code I should look, that would be a big help:)
Autumn13: What version of SMF?
Do you already have a mod that puts buttons in the Quick Reply area, if so which one?
Aranator: 1.1.11. As for the mod to enable buttons on quick reply, it seems to be something the previous Admin before me did (in short, we are not in contact so I cannot ask). I do not see any mod installed that matches it, so I wonder if she manually created the code.
Would you like to see a list of my mods?
I really appreciate the help.
A copy of Display.php and Display.template.php would be more useful than a list of mods, to be honest.
I appreciate the help. I only have a Display.template.php file. I have a post.template.php, index.php and an index.template.php, would one of those be the other you may need?
I also have one more request - the [mod] tag is only availably in the Global permissions, not Local. How can I fix this so that the [mod] tag is for Local permissions? Only my Staff forums are Global, and the rest are Local, meaning my Moderators can't use it where it needs to be used the most.
Thank you so much for the help :)
Display.php is in Sources/.
As for permissions... I don't remember how I wrote that originally in 1.1 :(
I did not realize about the permissions until today. Unfortunately, this is more important than having the icons in the quick reply. I have too many things set up in a particular way for me to manually change each board to Global just for this.
If I go through the manual install of this mod, I hopefully should be able to find where it sets the permissions so that I can tweak it some. Right?
I'm not sure if having the icons in quick reply will matter if my Mods can't use their mod comment outside of the Staff forums where they are doing editing, but in the hopes that I can fix it either way, here is the other file you requested.
Again, I appreciate your help immensely:)
The permission is physically added to the setup in ManagePermissions.php, so it just does whatever SMF expects it to.
From the mod's page, select 1.1.11 and Parse, that'll show you all the edits the mod makes. IIRC it's only the definition in ManagePermissions.php that would change.
/me is confused by the code you've posted with respect to quick reply, will try and take another look tomorrow morning when it's not midnight...
/me thanks Aranator for being a hardworking helper, even at midnight ;)
Thank you for trying. I don't know PHP in and out, but I'm pretty good at figuring things out/troubleshooting. I did not take a look in those files you requested, so I will do so sometime this weekend, as well as check all the edits the mod makes to see if I can figure it out.
Hi everyone,
I didn't work on the fast reply, but I DID fix the permissions:
./Sources/ManagePermissions.php
It says find
)
),
'board' => array(
Replace with:
),
'modtag_g' => array(
'allow_gmod_tag' => false,
'allow_admin_tag' => false,
)
),
'board' => array(
Then it has a separate one for the regular mod tag. Skip the other part and just add the mod part to the above so it looks like the following:
'modtag_g' => array(
'allow_gmod_tag' => false,
'allow_admin_tag' => false,
'allow_mod_tag' => false,
)
),
Hope that helps someone:)
How to bold this text and change color?
(http://ultraphoto.org/images/xnd9ewzhy5t3h31ddai.png)
Hello, I have a problem with the tags. It appears that all users, even guests, can see them. I checked permissions, and apparently it has nothing to do with that, what may be wrong?
If you have different member groups, remember to check the regular permissions for Regular Members (or it's called something like that. It is in Italics). I have found out from personal experience that that particular group may have been overlooked if all my custom member groups (Jr. Member, Sr. Member, etc) have the permissions correct.
Tucayo: All users are SUPPOSED to be able to see the tag and its contents.
They're just not supposed to be able to post it in their own posts.
Oh I see. I thought Tucayo meant the icons above the reply toolbox.
Oh, I see. I thought the tags were meant so regular users would not see them.
Thanks
No, as originally intended they're tags to make it clear that it is an 'official' response.
How can I change the colour of the " Administrator Comment " text actually all three my background is black and we cant see the text lol
QuoteFor themers: you can customise the resultant blocks by styling .admin_comment, .gmod_comment and .mod_comment respectively.
Add this to your CSS file (since I have no idea what version of SMF, I have no idea what file you should add this to)
.admin_comment, .gmod_comment, .mod_comment
{
color:white;
}
Oh and if it's the wrong colour, sorry but you didn't tell me what colour it should be.
im using 2.0 RC3 but its on a different theme than the default..
ahh the theme is BlackBox by Crip
white is fine
thank you for the quick reply
*shrug* I have no idea what file it should be then. style.css or index.css if it exists.
index exists lol sorry
ok that changed the text colour which is fine but the acutal words " Administrator Comment " is black.... can I change that to white ?
.admin_comment, .gmod_comment, .mod_comment, .admin_comment legend, .gmod_comment legend, .mod_comment legend
{
color:white;
}
should do it.
still black
Did you refresh it after saving the changes?
ok got it thank you so much
Hi i installed this on my site but having a few small problems. Seemed to install correctly but doesnt work properly.
Pictures attached show the problems. The buttons when making a comment are a bit messed up and when you look at the topic after its missing the warning triangles. Help appreciated asap. thanks
So, 2.0 RC3 on a... custom theme?
Did you select to install on custom themes when installing? If not, you're missing some images from the mod's package that will be in the default theme's images and bbc folders.
Sorry ya meant to include that. Running on RC3 and using the inferno theme. I installed the mod on the inferno theme so they should be in the right directory but just not showing up.
Its ok i fixed it. I reinstalled it and that didnt work. For some reason it installs the images into the default theme so i copyed them and put them into the same folders on the inferno theme and it works now. Thanks anyway and it may be worth looking at that when you get a chance.
Well, I don't even maintain this mod any longer.
But it will install to other themes if you use 2.0's Install On Other Themes option in the package manager. It cannot under any other circumstances.
Ok no problem thanks
So if a regular user tries to use the [admin]admin[/admin] tags, it wont work, but if they use [ADMIN]ADMIN[/ADMIN] tags it will, whats up with that? This also pertains to gmod, GMOD and mod, MOD tags as well...
I see the problem, I'll even throw in a solution since it's my bug (though since I copied the SMF code for the HTML tag I figured it'd work.)
If you look at the mod's code, you'll see changes for strpos for the mod, gmod and admin tags. Change those to stripos not strpos. (This is PHP 5 only, if you need a PHP 4 version, I'd encourage you to get your host to upgrade. I can find you a PHP 4 version if needed though)
Thanks for the fast reply, although I am not an administrator of the forum that has the issue, I will pass on your info and solution to the admins. I will also send them here if they have any further questions.
Is this a correct fix?
The problem is that when the posts are scanned for the comment tags, they use the strpos() function which is case-sensitive. This needs to be replaced with the stripos() function which is case-insensitive, so the bug can no longer be exploited. Here is the code:
This is in the Subs-Post.php
// if users aren't moderators or admins, strip the [ mod ] and [ admin ] (but not the [ MOD ] or [ ADMIN ] tags!!)
if (!$previewing && stripos($parts[$i], '[mod') !== false) //HERE
{
...
}
if (!$previewing && stripos($parts[$i], '[gmod') !== false) //HERE
{
...
}
if (!$previewing && stripos($parts[$i], '[admin') !== false) //AND HERE
{
...
}
Yup, those are the places to change.
If you get undefined function 'stripos' errors, that's because you're using PHP 4. Most hosts, thankfully, aren't now.
Hello, :)
Cool mod :D
We are running SMF ver2.0 RC3 AND using SMF Default Curve (which happens to be the forum's Default or we think it is (screen shot Forum-Default.jpg)
Installed with package manager and used "Install in other themes" still installed with all being "Successful"
Tested and appears to be functioning.
For your information, in our case, Guests AND others that do NOT have permission, do NOT even see the icons.
First problem = We set our testing user "Demo" to our Demo level user and assigned that user as Moderator of "Your Questions Notepad" which is located on "The Front Porch" category. As assigned moderator, Demo SHOULD see, BUT does NOT see the Moderator icon. (see screen shot Demo-is-a-Moderator.jpg and No-Mod-icon.jpg).
Second problem = Demo can see G/Mod icon because we went to permissions and were FORCED to set it up that way, (see screen shot Permissions.jpg), because the regular mod icon was not available (screen Shot No-Mod-icon.jpg).
Quote from: Arantor on September 01, 2009, 04:22:51 PM
For the border: add it to your CSS. I even left notes in the mod's description what to change.
For the ', make it \'
E.g.
$txt['tag_comment_admin'] = 'Administrator\'s Comment';
Quote from: Rohan_ on September 01, 2009, 04:36:04 PM
okay everything done .. now i didn't understand how to change the color of border
Quote from: Arantor on September 01, 2009, 04:47:21 PM
Go into your CSS file for your forum - style.css in your theme.
Try:
.admin_comment, .mod_comment {
border-color: red;
}
Styling isn't my forte, however (which is why my dev forum is still using the default!) so maybe that needs tweaking.
Third problem = We would like to make these changes, yet there is no "style.css"
(see screen shot No-style-css.jpg)
Wanting to use the AWESOME mod!!
EDITTo see this live, Demo's login is:
username=Demo
password=letmesee
Here is a link to Your Sanctuary (http://www.asanctuary.net/yoursanctuary/index.php)Thank you in advance.
Will check back in an hour or two.
Be Well,
Cloud 8)
Images are not showing on custom theme
Quote from: punjablovers on July 31, 2010, 07:37:24 AM
Images are not showing on custom theme
Have you copied the images into your custom themes images directory?
Quote from: √®╠╣∩©Ç瀫 on July 31, 2010, 10:39:00 AM
Quote from: punjablovers on July 31, 2010, 07:37:24 AM
Images are not showing on custom theme
Have you copied the images into your custom themes images directory?
How can i copy the images?
How do I use FTP? / What is FTP? (http://docs.simplemachines.org/index.php?topic=480.0)
Copy them to your local PC, (from default theme), then copy them from your local PC to the custom theme...
copied the images form package images to custom theme images folder, but still not showing,
I installed this Mod, but the Radio buttons don't show up. They are broken images. What needs to be done to repair the images?
Thanks in advance for any support.
means you need to copy the images from themes/default/images/bbc into the images/bbc folder of your theme
Quote from: Oya on October 19, 2010, 06:51:41 PM
means you need to copy the images from themes/default/images/bbc into the images/bbc folder of your theme
Awesome, this worked thanks. Now the only issue I am having is inside the specific post it shows as broken image. What would I need to change for this to work?
(http://img19.imageshack.us/img19/8789/captureqvd.jpg)
the mod instructions say
[quote]Move the included file "mod_tag.gif" to "./Themes/default/images".
Move the included file "admin_tag.gif" to "./Themes/default/images".
Move the included file "gmod_tag.gif" to "./Themes/default/images".
copy those three from themes/default/images to your theme's images folder
Quote from: Oya on October 20, 2010, 09:51:25 AM
the mod instructions say
[quote]Move the included file "mod_tag.gif" to "./Themes/default/images".
Move the included file "admin_tag.gif" to "./Themes/default/images".
Move the included file "gmod_tag.gif" to "./Themes/default/images".
copy those three from themes/default/images to your theme's images folder
Thanks for the help. I love that the SMF community always helps.
There is no picture for general moderator but it is ok for only moderators and admin. Why
How can i get this to work with 2.0 RC4, just upgraded my forum only to find out this great mod don't work anymore :-[
any ideas or will there be an upgrade soon ;)
gerry
Moderator and Administrator Comment Tags for RC4 :)
Quote from: Laza on December 04, 2010, 06:57:55 AM
Moderator and Administrator Comment Tags for RC4 :)
Done. :)
Version 1.8.1 Released has been released!
Changelog:
- Added support for SMF 2.0 RC4
- Fixed the bug mentioned on this page (http://www.simplemachines.org/community/index.php?topic=334033.msg2633076#msg2633076) which allowed members without permission to use the tags by posting them in all caps
- Dropped support for SMF 2.0 RC1.2, 2.0 RC2, and 2.0 RC3
Thank you Ha² ;)
Registered users can simply edit their messages and delete the text between the tags or both - text and the tags.
Is there any way to avoid this?
ooh, I like this.
However, the point brought up by RaveN7 is valid... the original user can edit out the notes.
maybe set a lock which prevents a user from editing a post that has been "noted"
edit-
meh.... problem.... the moderator comment removes all carriage returns from the comment.
test
1
2
3
4
comes out as
test1234
Some of my users were commenting that they missed the old, manual mod comments because we used a different color to notate a mod comment and, despite the icon and bug around it, they were missing the mod comments...... SO...........
If you have a similar problem:
Add the following to the end of install.xml (just BEFORE the </modification> closing tag)
<file name="$themedir/css/index.css">
<operation>
<search position="before"><![CDATA[/* Fieldsets are used to group elements. */
]]></search>
<add><![CDATA[
fieldset.mod_comment
{
color: green;
font-style:italic;
}
fieldset.gmod_comment
{
color: #6363ff;
font-style:italic;
}
fieldset.admin_comment
{
color: #e74242;
font-style:italic;
}
]]></add>
</operation>
</file>
the green is the standard staff color on our boards... the gmod and admin colors match the color of the triangle warning icon.
Quote from: RaveN7 on December 07, 2010, 10:47:26 AM
Registered users can simply edit their messages and delete the text between the tags or both - text and the tags.
Is there any way to avoid this?
This would be a nice feature! Please Ha
2?? Thanks.
Well, when I originally wrote this mod, that didn't occur to me, and implementing it is beyond complicated. Better solution, the one that I suggested, the one that Aaron's earlier modbreak mod followed... DON'T EDIT THEIR POSTS. There's no reason to edit their posts, just put it in a new post. They can't edit that!
Ah, ok. I will make new posts with "@username" for notes for them. Thanks.
Thanks very much for this great MOD.
Realy loving it.
Quote from: Kindred on December 21, 2010, 11:25:40 AM
edit-
meh.... problem.... the moderator comment removes all carriage returns from the comment.
test
1
2
3
4
comes out as
test1234
I had this problem also using SMF2 RC4. The way I fixed it was to replace the '/n' portion in Subs-Post.php
Replace this:
if (allowedTo('allow_mod_tag'))
$parts[$i] = preg_replace('~\[mod(.+?)\[/mod\]~ise', '\'[mod\' . strtr(un_htmlspecialchars(\'$1\'), array("\n" => \' \', \' \' => \'  \')) . \'[/mod]\'', $parts[$i]);
With this:
if (allowedTo('allow_mod_tag'))
$parts[$i] = preg_replace('~\[mod(.+?)\[/mod\]~ise', '\'[mod\' . strtr(un_htmlspecialchars(\'$1\'), array("<br/>" => \' \', \' \' => \'  \')) . \'[/mod]\'', $parts[$i]);
Replace this:
if (allowedTo('allow_gmod_tag'))
$parts[$i] = preg_replace('~\[gmod(.+?)\[/gmod\]~ise', '\'[gmod\' . strtr(un_htmlspecialchars(\'$1\'), array("\n" => \' \', \' \' => \'  \')) . \'[/gmod]\'', $parts[$i]);
With this:
if (allowedTo('allow_gmod_tag'))
$parts[$i] = preg_replace('~\[gmod(.+?)\[/gmod\]~ise', '\'[gmod\' . strtr(un_htmlspecialchars(\'$1\'), array("<br/>" => \' \', \' \' => \'  \')) . \'[/gmod]\'', $parts[$i]);
Replace this:if (allowedTo('allow_admin_tag'))
$parts[$i] = preg_replace('~\[admin(.+?)\[/admin\]~ise', '\'[admin\' . strtr(un_htmlspecialchars(\'$1\'), array("\n" => \' \', \' \' => \'  \')) . \'[/admin]\'', $parts[$i]);
With this:
if (allowedTo('allow_admin_tag'))
$parts[$i] = preg_replace('~\[admin(.+?)\[/admin\]~ise', '\'[admin\' . strtr(un_htmlspecialchars(\'$1\'), array("<br/>" => \' \', \' \' => \'  \')) . \'[/admin]\'', $parts[$i]);
As you will notice all that is changed is the
/n to
<br/>.
After this anything you post there onwards should have spaces between lines, hope this helps.
Thanks all
everything is ok
But there are some problem :
1 : when administrator adds a tag, normal user can edit that post and remove the tag.
even the tag will be remove just when normal user edit the post.
2 : you can't understand which moderator has added this tag. simply i can write a wrong name in tag as description
3 : a moderator can delete a tag that has been inserted by administrator.
4 : it was better to add new tags by administrator and you were not forced to use just 3 tags
are you going to solve this problems ?
yes yes and yes... so what? The mod never claims to be anything other than it is.
"fixing" item 1 would be difficult at best.
item 2 could be updated, but if you can't trust your mods and admins, why are they mods and admins?
item 3, see item 1 and 2.
Speaking as the original author of this mod:
These aren't problems, not really, and you don't need a technical solution to solve a user stupidity problem.
1. Don't edit their post, then. Make a new one where the user can't edit it. This has been said before, more than once, even in the last page or so.
2 & 3. As Kindred said. If they can't be trusted, demote them. The more complex you make something to make it more idiot proof, a better idiot comes along.
Dear Arantor
tagging is always used to preventing of making new post. by posting new one, you don't need a tagging system.
It's not so logical to say : Just don't do that
It's not the matter that moderators are trusted or not. A big website may have a lot of experts and moderators.
All moderators are tagging posts and Administrator couldn't ask all of them to know which one has tagged this post.
Also i couldn't say them to always write their name. It's like saying members to write their name where posting.
Dear Kindred
Item 1 is not so hard as you said. ;)
You can just trying to parse the content of a post before showing it. if there is a tag that the current user has not permission to access it, temporarily remove it from edit area and store it in the hidden field. then it will be post to server when saving and you can add it again.
That simple
Lol... That simple??
You are funny... So, rewrite the entire post display function because you can not trust you mod staff?no offense, but if it is so simple, then go ahead and do it yourself? The mod author has already indicated no....
Quotetagging is always used to preventing of making new post. by posting new one, you don't need a tagging system.
It's not so logical to say : Just don't do that
How is it not logical to say "Just don't do that." Again, if you don't trust your moderators, don't make them moderators!
QuoteAlso i couldn't say them to always write their name. It's like saying members to write their name where posting.
That's why you make them write a new post which will have their name against it. Like every member's post does! It's automatic.
QuoteYou can just trying to parse the content of a post before showing it. if there is a tag that the current user has not permission to access it, temporarily remove it from edit area and store it in the hidden field. then it will be post to server when saving and you can add it again.
Really, uh huh. So let me get this straight, you want to rewrite the single largest, single slowest, single most complex part of SMF, just because you can't manage your moderators effectively.
Dear Arantor and Kindred
I don't understand why you are challenging me just for suggesting a solution.
Ok, i forbear, do what you like.
i had changed that myself in my local system so easily and will be upload so soon in our online forum.
i just thought you may want to develop your mod but seems i was wrong.
Good Luck
I'm challenging you because I wrote this mod originally and am only too aware of how complex the suggestion you're proposing is, not to mention how much slower it will make the forum, assuming it's done properly (since there are so many ways to affect what you're talking about, that you probably aren't even aware of)
I had changed it myself and will publish it after some necessary changes.
I don't know how did you understand that i'm not aware of things that you mentioned but it's not so important.
I will send you changes although you behave so bad.
then you can see that things are so easier than what you think sometimes.
Don't attack others just because you think they don't know. Maybe you don't know.
End of my participation
I didn't mean to come out so aggressively, and for that I'm sorry.
But parse_bbc is the single most complex function in SMF, making changes to it is not a trivial process because of all the different times, different ways, different routes to which it can be called, and any change to it will invariably have consequences that you won't be aware of. I'm not saying that I would necessarily be aware of all of them, but having worked with the SMF code virtually full time for the last 18 months or so, I'm well aware of how fragile it can be at times. This is one of those times.
It's not just called with posts, it's called for signatures, it's called for entries in the moderation centre, it's called for newsletters, the news function, and myriad other places, so for which there won't necessarily be an 'owner' of the content to check against, and checking against the current user's id (as many people seem to think will solve the problem) won't do it either, unless you check it at creation time, though that's not always possible either.
I love this mod, have always found it really useful and like it just the way it is, so many thanks :)
Will it be updated for RC 5 ?
works fine for me on RC5 already.... just use the emulate function down at the bottom of the package manager screen
Quote from: Kindred on March 23, 2011, 04:29:18 PM
works fine for me on RC5 already.... just use the emulate function down at the bottom of the package manager screen
D'oh! - missed that - many thanks :)
Will this excellent MOD be updated formally to 2.0?
Grazie,
Cal
Hello,
I tried to use Kindred's suggestions to edit the (theme)/css/index.css to make the comments stand out a bit more.
Unfortunately, I've tried to edit the file manually and had no success.
Any suggestions would be most welcome!
Grazie,
Cal
Quote from: Cal O'Shaw on June 24, 2011, 02:16:27 AM
Will this excellent MOD be updated formally to 2.0?
Grazie,
Cal
Hi, :)
Same question.
Tried to parse, but not compatible. :(
Update for ver 2.0 Final "soon"? :P
Thanks,
Cloud 8)
this works perfectly in 2.0! thanks ^_^
Quote from: Jessica. on June 29, 2011, 01:22:18 PM
this works perfectly in 2.0! thanks ^_^
Wait What???!!! :o
It won't parse for SMF ver 2.0 Final,
I downloaded any way and tried install and got the attached screen shot.
Cloud 8)
Use the "advanced" link at the bottom of the packages list.... set it to a version which this does work for (e.g. 2.0 RC3)
Quote from: Kindred on June 29, 2011, 02:03:40 PM
Use the "advanced" link at the bottom of the packages list.... set it to a version which this does work for (e.g. 2.0 RC3)
Hi Kindred, :)
I went to the package manager,
went to bottom right of page,
clicked on advanced, 2.0 was default,
clicked on apply.
No "Install Mod" present.
Tried to Upload again.
Got message "File exists, Delete before uploading",
deleted file.
Uploaded file,
got
"The file is either corrupted or is incompatible with this version of SMF"
???
I attached screen shots
Thanks, ;)
Cloud UPDATE: Forgot the screen shots here they are
Quote from: A_Survivor on June 29, 2011, 02:29:37 PM
Quote from: Kindred on June 29, 2011, 02:03:40 PM
Use the "advanced" link at the bottom of the packages list.... set it to a version which this does work for (e.g. 2.0 RC3)
Hi Kindred, :)
I went to the package manager,
went to bottom right of page,
clicked on advanced, 2.0 was default,
clicked on apply.
No "Install Mod" present.
Tried to Upload again.
Got message "File exists, Delete before uploading",
deleted file.
Uploaded file,
got
"The file is either corrupted or is incompatible with this version of SMF"
???
I attached screen shots
Thanks, ;)
Cloud
Quote from: Kindred on June 29, 2011, 02:03:40 PM
...set it to a version which this does work for (e.g. 2.0 RC3)
Quote from: A_Survivor on June 29, 2011, 01:48:48 PM
Quote from: Jessica. on June 29, 2011, 01:22:18 PM
this works perfectly in 2.0! thanks ^_^
Wait What???!!! :o
It won't parse for SMF ver 2.0 Final,
I downloaded any way and tried install and got the attached screen shot.
Cloud 8)
as two other people said, emulate it using "Advanced". emulate it to RC4 (Put in SMF 2.0 RC4), I did that and was able to install it
Question, is it possible to edit lets say [mod] to [custom name] for example i don't use mod on my site just a globe mod but got other uses
modify modifications.english.php
Quote from: Kindred on June 29, 2011, 02:03:40 PM
Use the "advanced" link at the bottom of the packages list.... set it to a version which this does work for (e.g. 2.0 RC3)
UPDATE: Functions normally in SMF ver 2.0 Final ~ All I had to do was follow instructions.
Thanks Kindred!
Be Well,
Cloud 8)
Very Simple Question:
What CSS edits do I need to make to change the color of the text in the Title box that is generated?
(like "Administrator Comment" or "Global Moderator Comment" )
I can not find where it is pulling style info....
(PS: also running 2.0Gold just fine. Emulation worked like a charm! 8) )
Quote from: sdkid on August 07, 2011, 03:31:20 PM
Very Simple Question:
What CSS edits do I need to make to change the color of the text in the Title box that is generated?
(like "Administrator Comment" or "Global Moderator Comment" )
I can not find where it is pulling style info....
(PS: also running 2.0Gold just fine. Emulation worked like a charm! 8) )
sdkid,
Simple answer.
Use
[color=color name goes here (yellow, blue, or red] Text (will be the correct color)[/color]
I agree that you have to do this each time, HOWEVER, the thought is that you should only use the Mod Comment Mod to correct your members as little as possible. O:)
Cloud 8)Here's a link to see an example on the test forum (http://www.asanctuary.net/TEST_FORUM/index.php?topic=2.0)
Under 1.1 this MOD uses a CSS to set font, color, size, etc. That is missing in the 2.0 version.
Sure, one could go back into stuffing a bunch of BB codes each and every time mod, gmod, or admin are used. But losing the formatting that makes these comments stand out and requiring my moderators to have to add a bunch of codes (which they will not remember to do) does not seem ideal.
If it's not possible to use CSS, would it at least be possible to add an AdminCP panel to feed formatting attributes to each of the tags?
Thanks,
Cal
Hi,
First of all, I love this mod. It is really helpful :)
Now for the question. I would just like to make sure if the mod really strips the formatting inside the the tags? Like the line breaks, or even listing. Because when I recently updated to SMF 2.0 final and updated the mod as well, it now strips those.
If it shouldn't be doing that, what could've made it work that way? Is installing it as emulating SMF 2.0 RC5 be the culprit?
Thanks!
I am not talking about the color of the COMMENT itself--- I am talking about the LABEL of the box (Administrator Comment, or Global Moderator Comment) that surrounds the individual comments. The formatting of that LABEL is coming from somewhere in css....but where? I have a dark forum-- and the text LABEL is very dark. The text INSIDE the tags appears just fine
If you look through the code when parsed through the mod site, does it tell you anything, like where to look?
I would like to follow up on my question. I realized the tag works like a noBBC tag.
I need the tag to parse the formatting of the text in it, as we are using it as official notices and what not to make it easier to read. Is there a way to do that?
Quote from: live627 on August 10, 2011, 08:38:37 PM
If you look through the code when parsed through the mod site, does it tell you anything, like where to look?
No clue-- it is using some css code that is already there-- I just don't know what it is. If I knew it was using the .catbg3 title css, for example, I could make the change I want. I just can't figure out what setting in CSS it is actually using.
Firebug is your friend to help you figure out css
Quote from: sdkid on August 14, 2011, 02:47:03 PM
Quote from: live627 on August 10, 2011, 08:38:37 PM
If you look through the code when parsed through the mod site, does it tell you anything, like where to look?
No clue-- it is using some css code that is already there-- I just don't know what it is. If I knew it was using the .catbg3 title css, for example, I could make the change I want. I just can't figure out what setting in CSS it is actually using.
Found it in CSS around line 170:
fieldset legend
{
font-weight: bold;
color: #whateveryouwant;
}
Arouse to start
Quote[mod=<script>alert(hi admin)</script>]<script>alert()</script>[/mod]
[gmod=<script>alert(hi admin)</script>]<script>alert()</script>[/gmod]
[admin=<script>alert(hi admin)</script>]<script>alert()</script>[/admin]
Realy so must be?
Run - Opera, Chrome
Huh? ...???
Is it possible to add a tag for additional member groups? e.g. Guru I wanna add [guru] tag for them to use.
anything is possible, you just have to re-code it....
in other words - yes, but you would have to code in the additional group
that's the thing, I'm not a good coder.. :(
Quote from: Hackathon on October 26, 2011, 08:43:51 AM
that's the thing, I'm not a good coder.. :(
Ironic considering your username. Sorry Off topic. :-X
spanish utf8 language strings are not real utf8
Hi
I installed this mod on smf 2.0.2 and it's great, work perfectly. But! In membergroups I added new group called ModeratoR, because i want to add som new premissions fore moderators...
In standard membergroup Moderator i see premission Moderate tag controls/Allow this user to use [mod] ?, but in mine new created ModeratoR gorup i don't see this premmision.
Please help me to add this premission to my newlly created group. Thanks in forward... ;)
Quick question,
How would I go about changing Global Moderator Comment to Super Moderator comment? And how would I go about changing the box outline to red?
Thanks.
the outline is handled in the CSS file (I suggest that you use firefox+firebug - it's a very useful tool to find the correct CSS items)
The text is either handled in modifications.english.php or directly in subs.php
As mentioned in the very first post (and the mod's page)
QuoteFor themers: you can customise the resultant blocks by styling .admin_comment, .gmod_comment and .mod_comment respectively.
That's the CSS that would have to be changed, specifically the .gmod_comment code.
Quote from: bakabandit on February 04, 2012, 08:03:44 AM
I installed this mod on smf 2.0.2 and it's great, work perfectly. But! In membergroups I added new group called ModeratoR, because i want to add som new premissions fore moderators...
I attempted to install on 2.0.2 and got an error that it was not compatible. Did you manually install it?
use emulation....
Thanks Kindred -I have been trying to avoid doing that because (1) I don't know what emulation actually does, and (2) I didn't know how to do it. Past tense. I figured it out and it didn't break my test forum so I went ahead and installed it on my live site. It's a good mod and will hopefully help to make things clearer to members. Many thanks to those who have worked on it over the years!!
Any chance of an update to 2.0.2 ?
it works just fine on 2.0.2. Just use emulation
Quote from: Kindred on November 02, 2012, 05:07:58 PM
it works just fine on 2.0.2. Just use emulation
What kind of an emulation I'm with 2.0.2 and I really want to use this mod and I don't have any clue how to "emulate" it.
Dooooh!!!
It works.
I tried to install this mod,but nothing..
The package you are trying to download or install is either corrupt or not compatible with this version of SMF.
Forum Version is 2.0.4
How can I install a mod that doesn't work in my SMF version? (http://wiki.simplemachines.org/smf/How_can_install_a_mod_that_doesn%27t_work_in_my_SMF_version)
Quote from: Arantor on May 11, 2013, 02:16:38 PM
How can I install a mod that doesn't work in my SMF version? (http://wiki.simplemachines.org/smf/How_can_install_a_mod_that_doesn%27t_work_in_my_SMF_version)
Yes.I know,thank you! 8)
Look now (http://www.dodaj.rs/f/1p/VA/2brOXwKs/slika.png)
What is problem?How can I fix that? :)
As per the mod's page, three files get added to the Themes/default/images/bbc folder, you need to put these in Themes/yourtheme/images/bbc as well.
Quote from: Arantor on May 12, 2013, 01:05:47 PM
As per the mod's page, three files get added to the Themes/default/images/bbc folder, you need to put these in Themes/yourtheme/images/bbc as well.
Thanks a lot! 8)
Please update I can't install on version 2.0.4
it works fine on 2.0.4
http://wiki.simplemachines.org/smf/How_can_I_install_a_mod_that_doesn%27t_work_in_my_SMF_version
Could someone "with the power" remove the "solved" (http://media.simplemachinesweb.com/smf/default/images/post/solved.gif) from this support thread? I tend to skim over threads marked as such :)
huh? this is a mod thread... there is no "solved"
-edit - it looks liek the original author used the standard icon selection....
I can also confirm that this works fine on 2.0.4. Just use emulate. :)
Hello All,
I wonder if it is possible to have more green modtags in the post template.
I think it's difficult to discribe, but please look at my image.
What i want is that normal moderators have 5 green buttons, each button for a different standard moderator comment.
Can anybody tell me what i must add to the html? Try different things like add more
'if($modtag)
$context['bbc_tags'][$last]['mod'] = array('code' => 'mod', 'before' => '[mod]', 'after' => '[/mod]', 'description' => $txt['tag_comment_mod']);
in the post.template , but works not as good as i hope :-X
Thanks!
Just found out if i add a extra line with ['mod2']
Quote$context['bbc_tags'][$last]['mod2'] = array('code' => 'mod', 'before' => '[mod]', 'after' => '[/mod]', 'description' => $txt['tag_comment_mod']);
if($gmodtag)
and also add a mod2.gif it is working.
now i have to find out how to change the text ;D
Ok done, for anyone who is interested.
Add as many of these line's you want and change the ['mod'] in for example ['mod2'] ['mod2'].....etc
Quote$context['bbc_tags'][$last]['mod2'] = array('code' => 'mod', 'before' => '[mod]', 'after' => '[/mod]', 'description' => $txt['tag_comment_mod']);
if($gmodtag)
$context['bbc_tags'][$last]['mod3'] = array('code' => 'mod', 'before' => '[mod]', 'after' => '[/mod]', 'description' => $txt['tag_comment_mod']);
if($gmodtag)
And don't forget to add as many mod2.gif, mod3.gif....etc as you add lines!
You can type standard tekst here:
Quote$context['bbc_tags'][$last]['mod2'] = array('code' => 'mod', 'before' => '[mod]you can add here', 'after' => '[/mod]', 'description' => $txt['tag_comment_mod']);
if($gmodtag)
$context['bbc_tags'][$last]['mod3'] = array('code' => 'mod', 'before' => '[mod]you can add here something else ', 'after' => '[/mod]', 'description' => $txt['tag_comment_mod']);
if($gmodtag)
Now it wil work, but of course i want to help the moderators, it should be easy if they can see which buttons do what if they touch it with the cursor.
So i also change the ['tag_comment_mod'] to ['tag_comment_mod2'] , ['tag_comment_mod3']....etc
Quote$context['bbc_tags'][$last]['mod2'] = array('code' => 'mod', 'before' => '[mod]you can add here', 'after' => '[/mod]', 'description' => $txt['tag_comment_mod2']);
if($gmodtag)
$context['bbc_tags'][$last]['mod3'] = array('code' => 'mod', 'before' => '[mod]you can add here something else', 'after' => '[/mod]', 'description' => $txt['tag_comment_mod3']);
if($gmodtag)
After that go to the ./Themes/default/languages/Modifications.english.php
and add extra $txt['tag_comment_mod'] = ' lines
Quote$txt['tag_comment_mod'] = 'youre moderator comment for helping mod 1 ';
$txt['tag_comment_mod2'] = 'youre moderator comment for helping mod 2';
$txt['tag_comment_mod3'] = 'youre moderator comment for helping mod 3';
Ok that's it i think!
Or do i forget anything? permissions appear to be good ::)
Aaaaand I managed to break it XD
If somebody that is NOT an admin or a global mod etc has his post edited by someone with permission to add those commands and then he tries to quickly-edit his reply without removing the tag he just can't edit the command but if he goes into the actual post screen and tries to post you get a database error in the error log.
Quote
Type of error: Database
URLhttp://vige.altervista.org/forum/index.php?action=jsmodify;topic=84;c6275ebdef=4600ccf29079e457e6c75ef44e91e72a;xml
Database Error: Unknown column 'mem.posts' in 'field list'
File: /Sources/Post.php
Line: 2856
Also no clues of the reason why it is not really "Database Error" but that piece of report is in Italian while everything else is set to English..... Wtf....
Anyway I hope you will still follow this up even if it was a long time ago... You could either kill the error or call a new function pointing to an error popping out when somebody tries to edit a comment edited by an admin or global mod etc.
Thanks in advance, eventually :)
Please attach your Post.php.
I don't remember the query involved... but I have a feeling this mod isn't it because I don't recall it using queries to get post count. At least... I don't remember writing it to use that.
Idk how I could forget about attaching the file... That's probably what doing multiple things at the same time does... Anyway there it is :)
As suspected this is nothing whatsoever to do with this mod.
Something else has broken that post query; gut instinct says it's the Anti Spam Links mod if that's installed since the query on line 2856 is not touched by the mod (as verifiable from this mod's parse page)
Then why does this happen ONLY while editing posts including these tags?
Considering the query would be run on *any* quick modify call and doesn't do a proper join to the members table (thus mem.posts is never defined)...?
*shrug* Whatever. It is not the problem of this mod, seeing how the mod does not modify Post.php.
$request = $smcFunc['db_query']('', '
SELECT
t.locked, t.num_replies, t.id_member_started, t.id_first_msg, t.add_authors, t.is_sticky,
m.id_msg, m.id_member, m.poster_time, m.subject, m.smileys_enabled, m.body, m.icon,
m.modified_time, m.modified_name, m.approved, IFNULL(mem.posts, 0) AS postcount, IFNULL(m.id_member, 0) AS poster_id
FROM {db_prefix}messages AS m
INNER JOIN {db_prefix}topics AS t ON (t.id_topic = {int:current_topic})
WHERE m.id_msg = {raw:id_msg}
AND m.id_topic = {int:current_topic}' . (allowedTo('approve_posts') ? '' : (!$modSettings['postmod_active'] ? '
AND (m.id_member != {int:guest_id} AND m.id_member = {int:current_member})' : '
AND (m.approved = {int:is_approved} OR (m.id_member != {int:guest_id} AND m.id_member = {int:current_member}))')),
array(
'current_member' => $user_info['id'],
'current_topic' => $topic,
'id_msg' => empty($_REQUEST['msg']) ? 't.id_first_msg' : (int) $_REQUEST['msg'],
'is_approved' => 1,
'guest_id' => 0,
)
);
This is not standard - and is not changed by the installer as can be verified by anyone here.
And that's ok to me but still the question remains - why does it happen only with messages containing these tags? It's ok that the error is not from this mod but then what should I do to fix it or who should I ask about? The anti spam links mod author perhaps? I don't quite get it, sorry :/
EDIT: oh lol the author is smf cust team... And the mod is actually installed here too IIRC...
It's not the same mod as installed here. I would double check the installation instructions. Odds are one of your other mods clashes somewhere.
Indeed. I tried it in a clean install and it works without the error but... You know what? I will keep it like this and the reason is quite simple: if someone tries to edit the admin comment I get notified for free XD *evilface*
And if they try to edit the admin comment, it's going to fail on them afterwards which is why if you read the thread the advice has always been: put your admin comments in their own post where they can't be edited by unauthorised users anyway.
*like button pressed*
Thanks :)
I'm testing this mod at the moment and it looks great :)
Just one thing. I just find out that any user can use the mod tags while writing their PMs. Is there a way to avoid it?
Tell your users not to do it, and issue warnings if they don't behave?
Fixing the mod code instead?
Not all end cases require technical solutions. I don't understand why this 'every possible edge case must be fixed with a code solution' mentality is so prevalent. You cannot fix user idiocy or users being deliberately irritating to each other by way of code.
The permissions should still work regardless, though. They certainly did when I originally wrote this mod like 5 years ago. And on an otherwise unmodified 2.0.9 + this mod it seems to work properly for me...
The PM code flow is strange, but preparsecode still gets called and the permissions checks should still be run even in that situation. It just gets called later.
Lol you talk about fixing edge cases and you are always concerned about them when you write code... I don't quite get it. Whatever.
Like you even know what I mean by 'edge cases'.
That's your thought. Arguing is quite useless, you can either fix the code or leave it there but I have better things to do than arguing about this.
Guys, emulating this one isn't working for me, I don't get the install mod option, just list files and delete.
Quote from: Paracelsus on February 10, 2015, 06:42:07 PM
Guys, emulating this one isn't working for me, I don't get the install mod option, just list files and delete.
How you emulate it? maybe you are writing it wrong
Quote from: luuuciano on February 11, 2015, 08:50:30 AM
Quote from: Paracelsus on February 10, 2015, 06:42:07 PM
Guys, emulating this one isn't working for me, I don't get the install mod option, just list files and delete.
How you emulate it? maybe you are writing it wrong
Forget it luuuciano, I was emulating it wrong. Installation went fine after that.
Quote from: Yukino on August 10, 2011, 02:25:08 AM
Hi,
First of all, I love this mod. It is really helpful :)
Now for the question. I would just like to make sure if the mod really strips the formatting inside the the tags? Like the line breaks, or even listing. Because when I recently updated to SMF 2.0 final and updated the mod as well, it now strips those.
If it shouldn't be doing that, what could've made it work that way? Is installing it as emulating SMF 2.0 RC5 be the culprit?
Thanks!
Having recently installed the mod on SMF 2 I notice the same thing with line breaks... They don't exist inside the comment tag. There's a workaround though, to use the [ br ] bbcode tag, it creates the desired line break.
I see this isn't compatible with 2.0.10 right? Will it be soI use this on 1.1.21 and want to update tot 2.0.10....
Thanks...
this is compatible with 2.0.10
Almost any mod for 2.0.x will work with any other 2.0.x
Quote from: simplebeer on December 15, 2013, 06:45:04 AM
Ok done, for anyone who is interested.
Add as many of these line's you want and change the ['mod'] in for example ['mod2'] ['mod2'].....etc
Quote$context['bbc_tags'][$last]['mod2'] = array('code' => 'mod', 'before' => '[mod]', 'after' => '[/mod]', 'description' => $txt['tag_comment_mod']);
if($gmodtag)
$context['bbc_tags'][$last]['mod3'] = array('code' => 'mod', 'before' => '[mod]', 'after' => '[/mod]', 'description' => $txt['tag_comment_mod']);
if($gmodtag)
And don't forget to add as many mod2.gif, mod3.gif....etc as you add lines!
You can type standard tekst here:
Quote$context['bbc_tags'][$last]['mod2'] = array('code' => 'mod', 'before' => '[mod]you can add here', 'after' => '[/mod]', 'description' => $txt['tag_comment_mod']);
if($gmodtag)
$context['bbc_tags'][$last]['mod3'] = array('code' => 'mod', 'before' => '[mod]you can add here something else ', 'after' => '[/mod]', 'description' => $txt['tag_comment_mod']);
if($gmodtag)
Now it wil work, but of course i want to help the moderators, it should be easy if they can see which buttons do what if they touch it with the cursor.
So i also change the ['tag_comment_mod'] to ['tag_comment_mod2'] , ['tag_comment_mod3']....etc
Quote$context['bbc_tags'][$last]['mod2'] = array('code' => 'mod', 'before' => '[mod]you can add here', 'after' => '[/mod]', 'description' => $txt['tag_comment_mod2']);
if($gmodtag)
$context['bbc_tags'][$last]['mod3'] = array('code' => 'mod', 'before' => '[mod]you can add here something else', 'after' => '[/mod]', 'description' => $txt['tag_comment_mod3']);
if($gmodtag)
After that go to the ./Themes/default/languages/Modifications.english.php
and add extra $txt['tag_comment_mod'] = ' lines
Quote$txt['tag_comment_mod'] = 'youre moderator comment for helping mod 1 ';
$txt['tag_comment_mod2'] = 'youre moderator comment for helping mod 2';
$txt['tag_comment_mod3'] = 'youre moderator comment for helping mod 3';
Ok that's it i think!
Or do i forget anything? permissions appear to be good ::)
This option does not help.. so Can you help me to get it to work, I add the code and the tag shows but [lock][/lock] that what I get so fair
Alright, I have it working 100% and I have customise it to my liking, Apart from the post above where I added an 4th option and it's not working. Anyway I can't work out the permissions for it? Only the admin has the option to do this and I need other staff group to see there options to..
So from the ManagePermissions.php where do I go from there?
Hi,
it's a good mod, but slightly unusable, because if I modify post with admin tags, then if any moderator modify this post again, admin tags are disappear...
yes... because otherwise, a moderator (or the user) could modify the text between the admin tags and make it seem to say whatever they wanted
Does mod works on the latest version smf?
Does anybody has a fix for that strange phenomenon that "strips" things like line breaks or lists when writing inside these tags (you have to type [ br ] without the spaces to get a line break). The 1.x version was ok, it happens in the 2.x version.
hmmm... doesn't happen for me...
are you using the wysiwyg editor?
Does works on SMF 2.0.10? I've to change the smf version under the options?
Quote from: Kindred on June 11, 2015, 02:12:42 PM
hmmm... doesn't happen for me...
are you using the wysiwyg editor?
It happens no matter if wysiwyg is activated or not.
trying to install this at 2.0.10 as version 1.1.21 and it failed.
Anyone know why?
At./Themes/default/Post.template.php i can't find the code
Quote$found_button = false;
at and at ./Sources/ManagePermissions.php i cant'find the code
'board' => array(
Whats wrong?
even with emulation - mods for 1.1.x will almost certainly NOT work with 2.0.x...
but in the page for this page you say:
Quote from: Kindred on April 30, 2015, 06:44:09 AM
this is compatible with 2.0.10
Almost any mod for 2.0.x will work with any other 2.0.x
and if i have a look at the mod it say compatible :-[
is it possible to put the code somewhere else manually?
2.0 RC4 is not yet 2.0.x ;) Yet some previous posts claim it works fine in 2.0.2/4 so it should work in 2.0.10.
You need to manually find the affected code and fix it as most likely other MOD conflicts with this one.
Manual Installation of Mods (http://wiki.simplemachines.org/smf/Manual_installation_of_mods)
I know how to do it manually but i can't find the codes which i have to replace, so i don't know the position of the new text.
i have try to put it at the end before <?> but it isn't working... :-\
Wait... The MOD doesn't touch Post.template.php
custom.simplemachines.org/mods/index.php?action=parse;attach=163476;smf_version=2.0_RC4;mod=2104
You said...
Quote from: simplebeer on July 20, 2015, 07:34:08 AM
trying to install this at 2.0.10 as version 1.1.21 and it failed.
and this will not work.
if you emulate 2.0 RC4, it is likely to work.
Yes it is, thanks!
Getting the following error in the error log.
8192: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead
Sources/Subs-Post.php line=271
Mod still works.
SMF 2.0.11
Yeah, that's the deprecated modifier at PHP 5.5, it will continue to work until the deprecated modifier is completely removed. Both the original author and the current maintainer are absent so it's unlikely that the MOD is updated further :(
How can I add other tags?
Like this
(http://i.imgur.com/0jzyLfp.png)
[szuperadmin][/szuperadmin]
[foadmin][/foadmin]
Sry for bad english
Quote from: Westwegoman on November 15, 2015, 11:40:30 AM
Getting the following error in the error log.
8192: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead
Sources/Subs-Post.php line=271
Quote from: margarett on November 15, 2015, 05:06:15 PM
Yeah, that's the deprecated modifier at PHP 5.5, it will continue to work until the deprecated modifier is completely removed
At PHP7+ (I'm using 7.1.5) this mod causes all kinds of trouble due to the deprecated modifier /e being removed entirely, as forewarned above.
The fix is as follows:
Sources/Subs-Post.php
$parts[$i] = preg_replace('~\[mod(.+?)\[/mod\]~ise', '\'[mod\' . strtr(un_htmlspecialchars(\'$1\'), array("\n" => \'\', \' \' => \' \')) . \'[/mod]\'', $parts[$i]);
$parts[$i] = preg_replace_callback (
'~\[mod(.+?)\[/mod\]~is',
function ($p) {
$res = strtr(un_htmlspecialchars($p[1]), array("\n" => "", " " => " "));
return '[mod' . $res . '[/mod]';
},
$parts[$i]);
$parts[$i] = preg_replace('~\[gmod(.+?)\[/gmod\]~ise', '\'[gmod\' . strtr(un_htmlspecialchars(\'$1\'), array("\n" => \'\', \' \' => \' \')) . \'[/gmod]\'', $parts[$i]);
$parts[$i] = preg_replace_callback (
'~\[gmod(.+?)\[/gmod\]~is',
function ($p) {
$res = strtr(un_htmlspecialchars($p[1]), array("\n" => "", " " => " "));
return '[gmod' . $res . '[/gmod]';
},
$parts[$i]);
$parts[$i] = preg_replace('~\[admin(.+?)\[/admin\]~ise', '\'[admin\' . strtr(un_htmlspecialchars(\'$1\'), array("\n" => \'\', \' \' => \' \')) . \'[/admin]\'', $parts[$i]);
$parts[$i] = preg_replace_callback (
'~\[admin(.+?)\[/admin\]~is',
function ($p) {
$res = strtr(un_htmlspecialchars($p[1]), array("\n" => "", " " => " "));
return '[admin' . $res . '[/admin]';
},
$parts[$i]);
I had the same issue when upgrade to php 7.1 and smf 2.0.14 and this has fix it, thanks!
Please update to 2.0.14 SMF version
Quote from: ItsBlockFighter
Please update to 2.0.14 SMF version
It already works on 2.0.14
It's not good for me
But I can not install it
Why can you not install it?
He writes:
The package that you are trying to download or install is either corrupted or incompatible with this version of SMF.
Quote from: ItsBlockFighter
The package that you are trying to download or install is either corrupted or incompatible with this version of SMF.
How can I install a mod that doesn't work in my SMF version? (https://wiki.simplemachines.org/smf/How_can_I_install_a_mod_that_doesn%27t_work_in_my_SMF_version)
Read the above, then you'll want to set your forum version to "2.0 RC4"
https://wiki.simplemachines.org/smf/How_can_I_install_a_mod_that_doesn%27t_work_in_my_SMF_version
So I updated the package. It now shouldn't need to emulate 2.0 RC4. It also should work correctly on PHP 7 and 7.1.
Thanks Arantor, nice mod, installed in my Forum version 2.0.15 works well.
Translated into Italian "see Attachment", tested and working.
Belfa
How to install the mod? and where
use the package manager.
see the wiki/manual on how to do that
how can i add new tags like: [sadmin]Example[/sadmin]
Example:
(https://www.kephost.com/images/2018/04/11/sa.png)
Quote from: patrikx
how can i add new tags like: [sadmin]Example[/sadmin]
Look at how the mod does it. Add your extra tag in the same way.
This mod was discontinued by the author some time ago -- however, if anyone still has it installed, be aware that the mod uses create_function which is deprecated in php 7.4 and removed in php 8.0. Therefore, this mod will start throwing errors if your system is updated.
array(
'tag' => 'mod',
'type' => 'unparsed_content',
'content' => '$1',
'block_level' => true,
'validate' => create_function('&$tag, &$data, $disabled', '$data = get_mod_comment($data, "mod", null, ' . ($smileys ? 'true' : 'false') . ', \'' . $cache_id . '\');'),
),
array(
'tag' => 'mod',
'type' => 'unparsed_equals_content',
'content' => '$1',
'block_level' => true,
'validate' => create_function('&$tag, &$data, $disabled', '$data[0] = get_mod_comment($data[0], "mod", $data[1], ' . ($smileys ? 'true' : 'false') . ', \'' . $cache_id . '\');'),
),
array(
'tag' => 'gmod',
'type' => 'unparsed_content',
'content' => '$1',
'block_level' => true,
'validate' => create_function('&$tag, &$data, $disabled', '$data = get_mod_comment($data, "gmod", null, ' . ($smileys ? 'true' : 'false') . ', \'' . $cache_id . '\');'),
),
array(
'tag' => 'gmod',
'type' => 'unparsed_equals_content',
'content' => '$1',
'block_level' => true,
'validate' => create_function('&$tag, &$data, $disabled', '$data[0] = get_mod_comment($data[0], "gmod", $data[1], ' . ($smileys ? 'true' : 'false') . ', \'' . $cache_id . '\');'),
),
array(
'tag' => 'admin',
'type' => 'unparsed_content',
'content' => '$1',
'block_level' => true,
'validate' => create_function('&$tag, &$data, $disabled', '$data = get_mod_comment($data, "admin", null, ' . ($smileys ? 'true' : 'false') . ', \'' . $cache_id . '\');'),
),
array(
'tag' => 'admin',
'type' => 'unparsed_equals_content',
'content' => '$1',
'block_level' => true,
'validate' => create_function('&$tag, &$data, $disabled', '$data[0] = get_mod_comment($data[0], "admin", $data[1], ' . ($smileys ? 'true' : 'false') . ', \'' . $cache_id . '\');'),
),