Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Force Classic or New Post Layout
#1
I think we should have the option to force post layout on our users. We already have control over what the rest of our forum looks like, and this is an option that the admin should be able to control. I have no interest in allowing the new post layout on my board, and I am sure others love it and want all of their users to use it. So please give us the option.
#2
You can change it back to classic via Admin CP. Smile
#3
(08-30-2008, 02:27 AM)ToxicZero Wrote: You can change it back to classic via Admin CP. Smile

This option does not override the User CP.
#4
Something you could try is just copy the contents of postbit_classic and paste it into the postbit template.
#5
(08-30-2008, 06:43 AM)ZiNgA BuRgA Wrote: Something you could try is just copy the contents of postbit_classic and paste it into the postbit template.

I did this, but the output was a little weird looking.

That, and this is a rather contrived solution to something that should be simpler than this.
#6
(08-30-2008, 07:25 AM)Bey Brad Wrote: I did this, but the output was a little weird looking.

That, and this is a rather contrived solution to something that should be simpler than this.

It should look exactly the same. This is probably the best solution until the option to force which postbit is used is added.
[Image: vqApN3l.gif]
#7
(08-31-2008, 01:50 AM)monacelli Wrote:
(08-30-2008, 07:25 AM)Bey Brad Wrote: I did this, but the output was a little weird looking.

That, and this is a rather contrived solution to something that should be simpler than this.

It should look exactly the same.

Yes, well, it didn't, and I know how to copy and paste. Dodgy
#8
I'd also like this. Something that'd make the admin's choice of layout the default layout to both guests and registered members.

If they don't like it, there's always the User CP... but yeah, a change like this makes sense.

EDIT: Oddly enough, setting "1" as the default value in the classpostbit field in the mybb_users table doesn't make "1" the default. It still shows "0" on all users that register after this change.
#9
(08-31-2008, 01:50 AM)monacelli Wrote: It should look exactly the same.

Actually there are two minor differences... for classic mode, MyBB shows the "classic header" (the thing that says Author and Message), and adds a <br /> tag to the usergroup image.

Instead of changing the postbit templates to force one layout or the other, you can edit the User CP Options page and get rid of the option...

Instructions

Open the usercp_options template.

Find and remove the following code:

	<tr>
	<td valign="top" width="1"><input type="checkbox" class="checkbox" name="classicpostbit" id="classicpostbit" value="1" {$classicpostbitcheck} /></td>
	<td><span class="smalltext"><label for="classicpostbit">{$lang->show_classic_postbit}</label></span></td>
	</tr>

Now find this (near the top of the template):

<form action="usercp.php" method="post">

And add this underneath:

<input type="hidden" name="classicpostbit" value="1" />

Change the value from 1 to 0 if you don't want the classic layout.

Save the template.

For new registrations, you'll need to apply the PHP code fix posted by DennisTT here (which will be included in 1.4.2).

Finally, to set the option for all existing users, run this database query:

UPDATE mybb_users SET classicpostbit=1

Again, change the 1 to 0 if necessary.

Done.

Note: I know users can still change the option if they really want to (and know how), but who cares? :p
#10
The default values of MySQL columns aren't really used in the mybb_users table. Generally the user datahandler in MyBB dictates the "default" value.
Dennis Tsang
Former MyBB Team Member
Web: http://dennistt.net


Forum Jump:


Users browsing this thread: 1 Guest(s)