Thread Rating:
  • 2 Votes - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
 Upgrade for 1.8?
nier3 Offline
Member
***
Posts: 125
Joined: Jul 2012
Post: #22
RE: Upgrade for 1.8?
Hi, this code is right? because sometime doesn't work (I have mybb 1.8):


PHP Code:
1
2
3
4
5
6
7
8
9
10
<if ($GLOBALS['mybb']->user['usergroup']) == 1 && ($GLOBALS['threadfields']['hide']) == HIDE then>
Hide content if thread field is on "hide", only for guests (group "1")

<elseif ($GLOBALS['mybb']->user['usergroup']) == 2 && ($GLOBALS['threadfields']['hide']) == HIDE then> 
Hide content if thread field is on "hide" for member in group "2", but with other description different for group "1"

<else>
Show normal content for all other members

</if>


Sometime doesn't work, I see thread also if I'm a guest for example but I'm sure that threadfield is on "hide". I use it on forumdisplay_thread.


Here thread field configuration for "hide" in ACP:

EDIT THREAD FIELDS

Title: Hide
Key: hide
Applicable Forums: only some forum
Hide Thread field on new/edit thread and show thread: uncheck all
Input Field Type: Listbox
Display order: 10


INPUT OPTIONS

Editable by Administrators

Value List

Quote:HIDE
SHOW

Allow multiple values for this field: no

Input Formatter: {VALUE}

Custom Modify Error: blank (nothing written)
Settable Value Permissions: blank (nothing written)


INPUT FIELD OPTIONS

Description: Hide or show

Default Value: HIDE
(this because when a user create a thread, I would like always it hidden for group 1 and 2, then I'll decide if show or not)

Field Input Width: 40
Field Input Height: 1

Capture Tab Key: yes
Use Custom Input HTML: no


OUTPUT OPTIONS

Blank Replacement Value: HIDE
Display Format: {VALUE}
Formatting Map List: blank (nothing written)
Viewable by Usergroups: administrators
Unviewable Value: blank (nothing written)

MISC OPTIONS
Filtering Mode: disabled
Underlying Data Type: text



Then another odd thing: from list of threadfields, in ACP, if I click on this threadfield "Hide", I go directly to the bottom of the page on "Misc Options". But with all others threadfields I haven't this. Like if there an error in Misc Options maybe.

With other threadfields I start from the top, from Title etc.

Do you know where could be the problem? and how fix it?

Thank you in advance and sorru for my English
10-18-2014 02:05 AM
Find all posts by this user Quote this message in a reply

« Next Oldest | Next Newest »

Messages In This Thread
Upgrade for 1.8? - codegamer - 07-31-2014, 05:47 AM
RE: Upgrade for 1.8? - RateU - 08-05-2014, 04:08 AM
reply - terzier - 08-05-2014, 07:41 AM
RE: Upgrade for 1.8? - avril - 08-05-2014, 11:25 AM
RE: Upgrade for 1.8? - RateU - 08-06-2014, 05:37 AM
RE: Upgrade for 1.8? - ZiNgA BuRgA - 08-06-2014, 11:36 AM
RE: Upgrade for 1.8? - avril - 08-12-2014, 01:02 AM
RE: Upgrade for 1.8? - RateU - 08-07-2014, 04:17 AM
RE: Upgrade for 1.8? - codegamer - 08-07-2014, 06:24 AM
RE: Upgrade for 1.8? - RateU - 08-07-2014, 06:39 AM
RE: Upgrade for 1.8? - nier3 - 08-21-2014, 09:43 PM
RE: Upgrade for 1.8? - ZiNgA BuRgA - 08-22-2014, 09:41 AM
RE: Upgrade for 1.8? - RocketFoot - 09-03-2014, 02:40 AM
RE: Upgrade for 1.8? - Indoril - 09-04-2014, 09:30 PM
RE: Upgrade for 1.8? - Jaizu - 09-08-2014, 09:58 PM
RE: Upgrade for 1.8? - nier3 - 10-05-2014, 06:57 AM
RE: Upgrade for 1.8? - ZiNgA BuRgA - 10-05-2014, 11:02 AM
RE: Upgrade for 1.8? - nier3 - 10-06-2014, 09:31 PM
RE: Upgrade for 1.8? - Hamster24 - 10-07-2014, 05:38 AM
RE: Upgrade for 1.8? - ZiNgA BuRgA - 10-07-2014, 05:00 PM
RE: Upgrade for 1.8? - nier3 - 10-07-2014, 08:12 PM
RE: Upgrade for 1.8? - nier3 - 10-18-2014 02:05 AM
RE: Upgrade for 1.8? - nier3 - 10-20-2014, 10:33 AM
RE: Upgrade for 1.8? - ZiNgA BuRgA - 10-21-2014, 05:27 PM
RE: Upgrade for 1.8? - Sama34 - 10-23-2014, 03:02 AM
RE: Upgrade for 1.8? - ZiNgA BuRgA - 10-24-2014, 04:05 PM
RE: Upgrade for 1.8? - Sama34 - 10-31-2014, 02:26 AM
RE: Upgrade for 1.8? - Hamster24 - 01-10-2015, 10:17 PM

 Standard Tools
Forum Jump: