MyBB Community Forums

Full Version: Inline Moderation Dropdown: Where are the options stored?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hey,

I'm trying to get the "Lock Posts" plugin to work. Everything works, except that it puts a Inline Post Moderation option in the dropdown at the bottom of threads... which only works on the default theme.

I have tried really hard - as a person with no PHP skill but has a reasonable "tinkering" skill - to look through the database, the templates, and even the plugins PHP file itself. I'm lost in the database, no template in the default theme has been edited, and I don't understand PHP well enough to read the file but I have tried to look through it for a scent of where the Inline Post Moderation dropdown's options are stored.

So that is precisely my question: Where are the options for said dropdown stored? For most other things it is normally as easy as adding in the option in to a template but none of the templates appear with green 'edited' names...

[Image: 3485cvt.png]

Plugin's PHP file: http://pastie.org/10793423

Thank you for any help!

Thank you to ectomatt for fixing this plugin up to 1.8 to work at all too!
Show Thread Templates >> showthread_inlinemoderation_standard
Thanks for your reply captain m!

Unfortunately, not only is the template name not green to indicate changes from the default, but I don't see anything in that page that the plugin would have inserted.

<optgroup label="{$lang->standard_mod_tools}">
	{$inlinemodsoftdelete}
	{$inlinemodrestore}
	{$inlinemoddelete}
	{$inlinemodmanage}
	{$inlinemodapprove}
</optgroup>
that plugin is not editing code in templates - instead it is inserting code directly

you can add below code just above {$inlinemodsoftdelete} in showthread_inlinemoderation_standard template
<option value="lockposts">{$lang->inline_lock_posts}</option>
<option value="unlockposts">{$lang->inline_unlock_posts}</option>
Excellent! Thank you very much, that worked almost perfectly! Oddly the languages didn't work and all I got was a blank options menu, but I just typed in "Lock Posts" and "Unlock Posts" manually instead.

Except now, this plugin is supposed to add a locked icon, which is does fine in the default theme... but in this one, it does this:

http://i65.tinypic.com/2zpqfdj.png


I've looked in the "postbit" theme but all I see is;

	<div class="postbit_buttons post_management_buttons float_right">
		{$post['button_edit']}{$post['button_quickdelete']}{$post['button_quickrestore']}{$post['button_quote']}{$post['button_multiquote']}{$post['button_report']}{$post['button_warn']}{$post['button_purgespammer']}{$post['button_reply_pm']}{$post['button_replyall_pm']}{$post['button_forward_pm']}{$post['button_delete_pm']}
	</div>

How exactly is this plugin inserting it's features? First it doesn't add it's options, now the icon - which works in the default theme - doesn't show anything in this template yet it does exist (even if it doesn't work 100%)?

Very odd?
^ in the plugin file find <img src="'.$theme['imgdir'].'/lock.png" and change it to <img src="images/lock.png" - that should fix it.
I love you.