PDA

View Full Version : vBPrivate Threads


Eikinskjaldi
02-27-2006, 10:00 PM
vBPrivate Threads

This hack has been ported to vBulletin 3.5.4 from the vBulletin 3.0.0 version with permission granted by:
"You may modify, improve, upgrade, redistribute this hack, include it
in another hack or yours or translate it provided you do it free of
charge and you distribute it in www.vbulletin.org at least, there is no
need to pm me asking for permission"
in Kentaurus's post for its original release, found here (https://vborg.vbsupport.ru/showthread.php?t=62037&highlight=private+threads)

--------------------------------------------------------
This is my first major ported and released hack for vB.
--------------------------------------------------------

With this Code Modification you can add private threads to your forums. A private thread is:
A thread that some users or usergroups can view. Others cannot.
A thread that some users or usergroups cannot view. All others can.

Using this Modification, any user in a forum that has Private Threads turned on may create a private thread. It is useful for holding private moderator conversations, or for making a thread private when some users would like to see the discussion closed and others want it to continue.

Future Plans:

Add Super Moderators and Moderators to override the standard permissions
Admin Options for allowed private thread types
Admin Options to define users with override-permissions privilages
Admin Options for those who can make private threads
Private Threads will NOT show in the lastpost column when user does not have access to thread
Creator can view thread by default

Hack History:

Version 1.0.6
Changed several file edits to plugins (Thank you waza)
Some plugins were reverted back to file edits, no version change as it is going a bit backward
Version 1.0.5
Updated queries for install
Added queries for uninstall
1 Added Plugin
Fixed copy/paste errors in file edits find/change
Added missing printthread edit
Fixed Search problem
Version 1.0.0
Initial release

Hack Overview:
Products: 1
2 Queries 1 Phrase 13 Plugins
File Edits: 5 files (7 edits)
Template Edits: 3
Estimated Install time: Under 10 minutes

If you liked this hack then please Install (https://vborg.vbsupport.ru/vborg_miscactions.php?do=installhack&threadid=109096) it! :D

G-Force 199
02-28-2006, 03:48 AM
Installed.
Thank you :D

wholemama
02-28-2006, 05:45 AM
First and foremost...THANK YOU!!!

*****************************

I'm getting an error when we try to call the search function (as in when we click New Posts)...

Fatal error: Call to undefined function: private_thread_not_allowed() in /.../search.php on line 1823

Same happens in the other instantiation of the function on line 2224. Commented those out for now

****************************

The product doesn't seem to create the 'allowprivate' field...added that manually to the DB and then manually adjusted it as needed for my interim solution

***************************

When I try to edit a thread, I get...

Parse error: parse error, unexpected $ in /.../postings.php on line 2327

In the second portion of code added to postings.php, it's missing the closing } for the if statement

******************************

When I edit a thread that's been private...if I had more than one name saved originally in the allowed/denied list, when it pulls them back in, it only brings back the first name in the list.

Eikinskjaldi
02-28-2006, 06:30 AM
That's unexpected behavior, and I have it running just fine on my main board and test board. I'll install it on my test board again tonight and get back to you on the results of further testing.

It's still in beta and I have some improvements ready for it, too.

waza
02-28-2006, 07:37 AM
Does it has usergroup permissions?
And can't you do it with less file edits (by replacing them with plugins.)
However, It sure looks good!

Eikinskjaldi
02-28-2006, 08:29 AM
Bleh, my first release and I mess up stuff as simple as copying and pasting. Sorry about that :nervous:

I've updated to v1.0.5 and fixed the problems (works flawlessly when installed on my test board), added to the product, and added a new plugin to it.

@waza: What do you mean by usergroup permissions? You can allow or restrict viewing by usergroup, if that's what you mean.

I've tried to limit file edits to the best of my ability. I've only been on vB3.5 for a week, and just learning the new data management was daunting enough. If I can find other ways, or if anyone else can find other ways, to avoid file edits and maximize plugin use, the hack will be updated for that.

waza
02-28-2006, 11:55 AM
No what I mean is if you can restrict usergroups who can post private threads.
However, I looked @ the zip, and as there aren't any bitfield xml's their wont be usergroup permissions.
Like here:
https://vborg.vbsupport.ru/showthread.php?t=82844

And I'm sure a lot of file edits can be done by plugins, If I find some time I try to make use of plugins and pm them.

buro9
02-28-2006, 12:43 PM
Perfect!

You wouldn't believe the need I have for this. It's incredibly sensitive, and this is a life saver.

Thank you so much for making and publishing it.

rnmcd
02-28-2006, 12:50 PM
Thanks.

Looks like you finished before this:
https://vborg.vbsupport.ru/showthread.php?t=80135

XanTrax
02-28-2006, 01:33 PM
From the types of people I deal with in my forums this would be abused 10 thousand times over. If anything try to add an option for which usergroups or users are allowed/not allowed to use this option. Something like...

Can user select thread options: Yes / No

wholemama
02-28-2006, 01:39 PM
:) That version fixes everything!

And I figured out the multiple users thing...I was doing what was intuitive and putting a space after the semi-colon like a list...but no space can go there. So I'm altering the template to put a warning about that for my users (who aren't the most computer literate sometimes!).

The only problem that's keeping me from making this live now...when the thread shows in the Last Post column and you click on it, you can see it no matter if you're supposed to or not. It's like that call doesn't check the private_thread_not_allowed().

Eikinskjaldi
02-28-2006, 01:44 PM
Future Plans: Private Threads will NOT show in the lastpost column when user does not have access to thread
I'm hoping to have that changed soon. I still need to find out how to make it check for the next available "last thread" after that, and then repeat the permissions check, and loop until it finds one the person does have permission to.

buro9
02-28-2006, 01:49 PM
I think you missed out something like:

$threadinfo['privateusers'] = $threadinfo['privateusers'] ? implode(";",unserialize($threadinfo['privateusers'])) : "";


in the showthread.php file, and then change $restrictedusers to $threadinfo[privateusers] in the showthread template.

And I've made it admin only, by doing things like the following in the newthread and the edit thread templates:

<if condition="$foruminfo['allowprivate'] == 1 and is_member_of($bbuserinfo, 6)">


Where 6 is the id of the Admins usergroup

wholemama
02-28-2006, 02:00 PM
I'm hoping to have that changed soon. I still need to find out how to make it check for the next available "last thread" after that, and then repeat the permissions check, and loop until it finds one the person does have permission to.

Yup... :)

I don't mind it showing in the Last Post column...that doesn't matter at all...it's just that it needs to check it when you load from that link (or any other direct link).

wholemama
02-28-2006, 02:16 PM
Ok...got that working...that was my error! :D

Happy happy joy joy!

Eikinskjaldi
02-28-2006, 04:30 PM
Buro, the program by default checks if you are an admin or not. I am working on a more advanced usergroup selection for making and viewing threads, also, I am drawing closer to the cure for the message in the last thread posted in area, 'Tis a beta for a reason, It will have errors as it goes further, thanks for the feedback so far :D.

The update later should also include the permissions for the thread creator by default and make it so all admins, mods, and super mods can view threads, unless you choose to turn supermods and mods off.

tmcyouth
02-28-2006, 06:19 PM
Are you planning on making an option to enable only certain usergroups to set this option? How about making it only available in one forum?

Can't tell you how excited I am to get this! Thanks!

Eikinskjaldi
02-28-2006, 09:58 PM
I will add making permissions for who CAN make private threads to the "future plans" list. Hi already can set the ability to have private threads per forum (this is Yes by default).

Daniel
02-28-2006, 10:25 PM
Clicked install, hopefully in the future this won't need any file edits... if possible.

Ambie
03-01-2006, 04:51 AM
When I make a thread and list the people allowed to see it,I go in with my test regular user name...If I click on new posts or the forum the private thread is in ,I get this error message:

Fatal error: Cannot break/continue 1 level in /home/*****/public_html/forums/forumdisplay.php(938) : eval()'d code on line 4

But, I don't get this error if I make a thread using the test account and then go look at it logged in as an admin. I hope that made sense. Any idea?:ermm:

Eikinskjaldi
03-01-2006, 05:26 AM
When did you install the hack? Do you have any other plugins or file edits to forumdisplay.php? Could you show what that line (and surrounding lines) contains in your file?

The only change to forumdisplay.php (from my hack) should be a plugin, and I'm not experiencing any problems using it at all.

Ambie
03-01-2006, 06:43 AM
When did you install the hack? Do you have any other plugins or file edits to forumdisplay.php? Could you show what that line (and surrounding lines) contains in your file?

The only change to forumdisplay.php (from my hack) should be a plugin, and I'm not experiencing any problems using it at all.


I installed it tonight. Yeah I have a lot of things in the forumdisplay. This is what is around line 938



I will go disable things one by one and see if it is another hack causing it :)

Eikinskjaldi
03-01-2006, 07:50 AM
I think you're supposed to use CODE or PHP tags to hide the code from non-licensed users :)
If line 938 is the hook, and other plugins are using that hook, then the problem may be the order that the code is executed in. I know that the order can cause some problems. Perhaps try turning off the other plugins for that location?

Ambie
03-01-2006, 08:01 AM
I think you're supposed to use CODE or PHP tags to hide the code from non-licensed users :)
If line 938 is the hook, and other plugins are using that hook, then the problem may be the order that the code is executed in. I know that the order can cause some problems. Perhaps try turning off the other plugins for that location?

I just took it out of my post.:nervous:


Thanks, that is what I am trying now. :)

Eikinskjaldi
03-02-2006, 04:59 AM
Tell me how it turns out so I can look into why it might be eroring for you, need to fix bugs even if I cant reproduce it. :D

waza
03-02-2006, 07:50 AM
@ambie: If you disable the product of this hack, do you still get the error, if so it has nothing to do with this hack, otherwise:
post the content of the plugin from this hack in the hook: threadbit_display.

drex
03-02-2006, 03:48 PM
@Eikinskjaldi (or anyone else) -- before i go live with this, is the issue about the last post linking fixed, or can anyone see the thread/and or its contents?

do i have to do this?


I think you missed out something like:

Code:
$threadinfo['privateusers'] = $threadinfo['privateusers'] ? implode(";",unserialize($threadinfo['privateusers'])) : "";

in the showthread.php file, and then change $restrictedusers to $threadinfo[privateusers] in the showthread template.

And I've made it admin only, by doing things like the following in the newthread and the edit thread templates:

Quote:
<if condition="$foruminfo['allowprivate'] == 1 and is_member_of($bbuserinfo, 6)">




Where 6 is the id of the Admins usergroup

I didn't follow the above..

Thanks

drex

drex
03-02-2006, 03:56 PM
crap new posts in the vbcmps doesn't work now. whole board is screwy.

uninstalling....

drex
03-02-2006, 04:03 PM
ok, now that i was able to stop a disaster. (and no, i don't have a test board -- too much work), the issues are:

1) if you are not an admin, or one of the 'allowed' users, and you click on the LAST POST link, you get the error listed above that ambie stated.

2) the search for 'New Posts' on the Vbadvanced CMPS front page doesn't work either

luckily, if you turn off the 'private threads allowed' forums, all goes back to normal.

this is a little too buggy to use live. needs more work, though great hack...

drex
03-02-2006, 04:05 PM
the vbcmps error:

Fatal error: Cannot break/continue 1 level in /home/-----/public_html/search.php(2207) : eval()'d code on line 4
__________________

Eikinskjaldi
03-02-2006, 07:12 PM
Can you post or PM me the lines of code you are having issues with? I had no issues with my own board and this hack so it might be that something is interfering, if the line is a plugin then please specify the plugin and i'll check it to see if there is anything outstanding in it.

The other thing you mentioned is that it shows a link to a new private thread, but it gives you an error message, it should be a vBphrase error message as well. This is to alert the user they don't have permission. However until I figure out the exact code I need to use I cannot remove them from the 'New thread' area without making it do a much more ugly thing of 'Private thread' and no link.

drex
03-02-2006, 07:27 PM
that would be the 4th line of code in search.php.... ?? not sure which code you want me to give you!

Eikinskjaldi
03-02-2006, 10:09 PM
I believe I've found the problem - It was where several file edits had been changed to be plugins, plugins that, looking at the code, come at inopportune times. I am editing the install file and the product to reflect the revert back to having, I believe, 2 more file edits and 2 less plugins.

Eikinskjaldi
03-03-2006, 01:29 AM
*slaps forehead*

Well, I have found the cause of the search issue, It is quite a stupid one to be honest. If you have the current private thread hack installed, all you need to do is change the search and forumdisplay files. The instructions for each will be in the install directions.

Good luck!

[[Will shortly upload the new and improved install file with the correct code edit. Sorry about that!]]

Ambie
03-03-2006, 02:36 AM
Nothing I was doing was working, but I just got an update e-mail. I just uploaded the new file and did the file edits and now it works great. Thank you! :)

rnmcd
03-03-2006, 02:38 AM
Nothing I was doing was working, but I just got an update e-mail. I just uploaded the new file and did the file edits and now it works great. Thank you! :)

Where did the update email come from?

Eikinskjaldi
03-03-2006, 03:48 AM
I sent an update that automatically e-mails any user who has clicked "install" for this hack.

buro9
03-03-2006, 06:45 AM
I sent an update that automatically e-mails any user who has clicked "install" for this hack.

Is the printthread.php hack not missing one of these:

include_once('./includes/functions_privatethread.php');

drex
03-03-2006, 01:04 PM
i didn't see an email.... (i haven't uninstalled, just not activated a private forum)...

can you post the file edits here or pm me?

Eikinskjaldi
03-03-2006, 01:54 PM
buro9: Quite apparently in the installer, although my installed version seems to already have it. The product's been updated, thank you for catching that :)

drex: The plugins at threadbit_display and search_results_threadbit have been removed. They've been replaced with the following file edits.

In search.php
Find:
// show results as posts
if ($search['showposts'])
{
foreach ($itemids AS $post)
{
Add BELOW:
// M/DD/YY PRIVATE THREADS PORT
include_once('./includes/functions_privatethread.php');
if (private_thread_not_allowed($post))
{
continue;
}
// END PRIVATE THREADS PORT

In forumdisplay.php
Find: while ($thread = $db->fetch_array($threads))
{ // AND $counter++ < $perpage)
Add BELOW:
// M/DD/YY PRIVATE THREADS PORT
include_once('./includes/functions_privatethread.php');
if (private_thread_not_allowed($thread))
{
continue;
}
// END PRIVATE THREADS PORT

drex
03-03-2006, 02:05 PM
should i also reload the product (just in case)?

Eikinskjaldi
03-03-2006, 02:27 PM
Yes, I've updated the printthread plugin in the product.

bondjetta
03-03-2006, 07:08 PM
am i doing something wrong? when i click New Posts i can see the threads that are supposed to be hidden (from my test account)...however when I click them it says i don't have permission. The problem is when I hover over the link it gives me the preview of the thread...sort of defeating the purpose of the hack?

Eikinskjaldi
03-03-2006, 08:25 PM
This is an error I am working on currently, I am sorry for the current inconvience, it should be patched and fixed within the near future hopefully :D

EDIT: Wait, is this on forumdisplay or forumhome? When you view a forum you see the thread? Because that means you must have missed an edit somewhere. The only place a none viewable person can find out if a private thread exists is through forumhome's lastpost bit. I am currently working on making it so they cant see that either.

drex
03-04-2006, 12:13 AM
mine can be seen from the vbcmps screen... that's the only problem with this hack. it doesn't display in forumdisplay, and follows its permissions accordingly...

is there any way i can help?

thanks

drex

drex
03-04-2006, 01:29 AM
the problem lays with the file latesttopics.php from VB advanced CMPS. i have been looking at the template file, adv_portal_latesttopicbits .....

the first is the query and the second is the display thread.

Eikinskjaldi
03-04-2006, 02:39 AM
That's one of the things I'm still trying to work on. The original version also did not prevent threads in private threads from showing in the lastpost column or on a vbacmps page. What needs to happen is that the permissions check needs to occur, but if the user does not have the permission, the next latest thread needs to be found (and the process must repeat until there is a viable thread).

drex
03-04-2006, 12:35 PM
using the search.php for today's posts, it still shows up for the unauthorized users...... :ermm:

Eikinskjaldi
03-04-2006, 04:35 PM
Have you performed the file edits in search.php? Can you copy for me the code you've placed for the two file edits (and the surrounding code)?

drex
03-04-2006, 05:06 PM
missed one file edit in search.... now if it wouldn't display in forumhome....

here are the edits in forum (the search is fixed)..

$threadbits = '';
$threadbits_sticky = '';

$counter = 0;
$toread = 0;

while ($thread = $db->fetch_array($threads))
{ // AND $counter++ < $perpage)

// M/DD/YY PRIVATE THREADS PORT
include_once('./includes/functions_privatethread.php');
if (private_thread_not_allowed($thread))
{
continue;
}
// END PRIVATE THREADS PORT


// build thread data
$thread = process_thread_array($thread, $lastread, $foruminfo['allowicons']);
$realthreadid = $thread['realthreadid'];

if ($thread['sticky'])

is it just me, or is everyone having the same problem with forumdisplay.php (forumhome)?

rnmcd
03-04-2006, 06:03 PM
is it just me, or is everyone having the same problem with forumdisplay.php (forumhome)?

It looks like a great hack but I'm still to afraid to install it.

drex
03-04-2006, 08:19 PM
it is a great hack.

just a few more tweaks, and its a winner!

rnmcd
03-04-2006, 10:59 PM
it is a great hack.

just a few more tweaks, and its a winner!
I wholeheartedly agree!!!!

And Eikinskjaldi is really sticking with making it work! Thanks.

Eikinskjaldi
03-05-2006, 12:06 AM
now if it wouldn't display in forumhome....
I've already said that it will display in the "last post" column in the forumbit on both forumhome and forumdisplay because hiding those was not something even the original did.

However, as far as placing all the threadbits into forumdisplay, private threads that one doesn't have access to will not display. I'm working on this, so that the hack can really be complete and surpass the original, but I also have other stuff going :)

drex
03-05-2006, 01:55 AM
that's cool. i don't mind that it displays. the problem is the preview. is there a way to just shut the preview off, so that the message preview does not display; i wouldn't care that the thread title displays, just kill the preview on the private messages?

thanks!

Eikinskjaldi
03-05-2006, 03:33 AM
Can you possibly PM me a link so I can see this because I can't seem to get the same erro you are recieving. On my forum home it shows the forums last post stuff, but doesnt give any data, in forumdisplay when you view that forum a user who cant see a private thread shouldnt be able to know it exists, let alone hover there mouse over for a preview. This might be an error with the hiding code if this is going on.

drex
03-05-2006, 11:10 AM
ok, my bad. it only says 'go to first unread post in [thread name]' when you hover over it.

so, the security permissions are working well. the only way people know a thread exists (and who is posting in it), is via the known VBcpms and forumdisplay routes, as described above.

will be using this, but can't wait for it to be complete when the above is tweaked!

thanks!

-d

drex
03-05-2006, 06:50 PM
how about this... in forumdisplay, suppose one could modify the code to display the author as private instead of the authorname. that would solve the problem temporarily.

Eikinskjaldi
03-05-2006, 11:06 PM
Well that was an idea I had, to Automatically change thread name and posted to 'Private' but I just don't think it would look good on the forum in general and so I am working on a work around.

rnmcd
03-06-2006, 12:15 AM
not workarounds!!! :nervous:

workarounds always seem to bite you in the long run.

Eikinskjaldi
03-06-2006, 02:14 AM
Well it isnt a work around, its a fix to a problem :P

rnmcd
03-06-2006, 02:16 AM
This is gonna be one awesome hack!
Your first one, right?

Eikinskjaldi
03-06-2006, 03:33 AM
My first at least for 3.5, and my first released, yes.

bondjetta
03-06-2006, 12:31 PM
This is an error I am working on currently, I am sorry for the current inconvience, it should be patched and fixed within the near future hopefully :D

EDIT: Wait, is this on forumdisplay or forumhome? When you view a forum you see the thread? Because that means you must have missed an edit somewhere. The only place a none viewable person can find out if a private thread exists is through forumhome's lastpost bit. I am currently working on making it so they cant see that either.

nope it's on New Posts...search.php...but according to what i read above i missed an edit in Search.php?! I'll go double check, but i don't believe that's the case...one sec.

// show results as posts
if ($search['showposts'])
{
foreach ($itemids AS $post)
{
// M/DD/YY PRIVATE THREADS PORT
include_once('./includes/functions_privatethread.php');
if (private_thread_not_allowed($post))
{
continue;
}
// END PRIVATE THREADS PORT

// threadbit_deleted conditionals
$show['threadtitle'] = true;
$show['viewthread'] = true;
$show['managethread'] = true;

foreach ($itemids AS $thread)
{
// M/DD/YY PRIVATE THREADS PORT
include_once('./includes/functions_privatethread.php');
if (private_thread_not_allowed($thread))
{
continue;
}
// END PRIVATE THREADS PORT

Eikinskjaldi
03-06-2006, 03:43 PM
No, that's quite correct and matches what I have for private threads in my search.php file. And you say they're showing up when you do NOT have permission to view them on a "New Posts" search?

bondjetta
03-06-2006, 04:10 PM
No, that's quite correct and matches what I have for private threads in my search.php file. And you say they're showing up when you do NOT have permission to view them on a "New Posts" search?

yep...

http://www.worksafeboredom.com/content/

go there, click Today's Posts (or register and do New Posts) and you should be able to see a thread named Test w/ a preview of, "You can see this can't you?"

Eikinskjaldi
03-06-2006, 07:26 PM
Hmmm.... The next best thing to try is to uninstall the entire hack, and try at installing it again. Ensure that all of the plugins are turned on, and that all the file edits have been made.

Might I ask when you downloaded the package? It has been changed quite a few times in the past few days. Sorry about that.

Also, if you need any help installing it or wish me to do it then just drop me a PM. I have some free time this week so it wouldn't be to much of a problem :D

bondjetta
03-07-2006, 12:19 PM
Hmmm.... The next best thing to try is to uninstall the entire hack, and try at installing it again. Ensure that all of the plugins are turned on, and that all the file edits have been made.

Might I ask when you downloaded the package? It has been changed quite a few times in the past few days. Sorry about that.

Also, if you need any help installing it or wish me to do it then just drop me a PM. I have some free time this week so it wouldn't be to much of a problem :D

I had installed the version you posted just before you sent out the email that it had been updated (removed 2 plugins, added a file change or two...last week sometime)...then did the update when you sent the email about those new changes.

I'll uninstall/reinstall right now and tell you what I find. :)

nope, no luck. still showing up under New Posts.

Eikinskjaldi
03-07-2006, 08:56 PM
Thats just bizarre, I can't replicate it and I don't see anything in the code you posted, is there by chance anything that could be blocking it?

Any other hack that might be getting in the way.

bondjetta
03-08-2006, 10:01 PM
Thats just bizarre, I can't replicate it and I don't see anything in the code you posted, is there by chance anything that could be blocking it?

Any other hack that might be getting in the way.

the only other plugin that's registering on any of the search pages/functions is Thread Prefixes. I'm not sure if that could be it but i'll go disable it and test it.

EDIT: well..that was it. i turned off Thread Prefixes and the thread disappeared...*dang* :( i know you're busy but if "one day" you get a chance to work through that I'd appreciate it :) I have to use thread prefixes for a NWS section on my site that i want CLEARLY marked (so i require the prefix) so i can't keep that plugin disabled. :(

thank you for all the help so far though!

Eikinskjaldi
03-08-2006, 10:21 PM
Try changing the order of the plugins, as I'm certain this is causing the problem. I, too, have thread prefixes running alongside Private Threads.

Ohiosweetheart
03-09-2006, 12:52 AM
isn't this something that vBulletin already does? I know i have private password protected forums..

Eikinskjaldi
03-09-2006, 04:32 AM
This is not password protected, this allows the poster of a thread, in this case a mod and up the ability to restrict who can post and read said thread.

bondjetta
03-10-2006, 02:04 AM
Try changing the order of the plugins, as I'm certain this is causing the problem. I, too, have thread prefixes running alongside Private Threads.
pardon my ignorance but how do I change the order of the plugins? :confused: i don't see a place in here for reordering? :\

Eikinskjaldi
03-10-2006, 04:03 AM
Well aside from removing it and putting it back the only other method is to find the file the edit is in and then add the code you want directly before it, saddly it lacks a plugins less code dits feature, but it is not a standard vB feature to change the order of plugins as far as I can recall.

Possibly a future vB update?

bondjetta
03-14-2006, 03:05 PM
Well aside from removing it and putting it back the only other method is to find the file the edit is in and then add the code you want directly before it, saddly it lacks a plugins less code dits feature, but it is not a standard vB feature to change the order of plugins as far as I can recall.

Possibly a future vB update?
i tried the delete it, reinstall it technique with no luck...so i disabled Thread Prefixes for now. Your hack is far more useful ;)

Also, will it ever be possible to change a thread that's already been created into a private thread? right now i make the changes under Edit Thread but they won't stick. Or is this a bug and I've screwed up again? ;)

Eikinskjaldi
03-14-2006, 10:57 PM
hmm... I am not getting this error either. Is your system heavily hacked, because if it is you may have to end up moving the plugins into file edits to make it the most compatible. If you'd ever like help with that just drop me a PM and I can figure it into my sced.

Hornstar
03-15-2006, 07:24 PM
this will come in handy, thanks.

???`S?LV?R???`
04-04-2006, 05:20 PM
How is this currently working for 3.5.4?

Eikinskjaldi
04-05-2006, 04:23 AM
It is working well, We have noticed few to no errors.

I have been busy with new endevors and have but this on the side burner a bit, anyone watching our forums will know we have been busy in many other places and facets. However I have not forgotten about this and I will be making updates in the near future. Really th only two cruxxes are,
It shows the thread in newest post on forumhome/display They take up room on the forumdisplay even though the user can't see them.

The first issue is not so serious in my opinion and is a small change. The bigger issue is the second point which would involve making the query skip private threads a user can't see. This would mean an advanced query and I havn't had time to play with such. However I am shure it is possible by all means.

Once those two issues are solved it is prestine and ready to go as a full hack. However if those two things don't bother you much then it is a non-issue and your set to install!

-Eikin.-

???`S?LV?R???`
04-12-2006, 06:09 AM
Thanks, I appreciate the reply and useful details you provided, those 2 bugs don't sound too bad, but as always, would be nice to have those issues taken care of. I can understand that you are busy with other projects, I thank you for the work you've put in to provide this. Hopefully you'll get to the 2 bugs when you have time though, I'm sure we'll all appreciate it, and if not, I Will (lol).

Eikinskjaldi
04-20-2006, 02:50 AM
I fixed one of the issues, but the way to do it some might not like. So i'll make shure to note that in the install file. However I want to solve both before I upload a new version.

???`S?LV?R???`
04-20-2006, 03:37 AM
good to hear that one of the issues has been knocked out, i'll be lookin forward to the next release that has the bugs fixed. I'll probly wait to install until that one is ready.

SimCityForum
05-04-2006, 04:32 AM
Wonderful mod. You have made for some very happy people at one of my forums. So far everything works great. It has taken a little time to figure it out but I'll give it two thumbs up. :tup:

ozmazdaclub
05-16-2006, 03:12 AM
does this work in 3.5.0

I installed it but can not see anything in the threads? is there something i need to do?

Eikinskjaldi
05-26-2006, 06:33 AM
I do not have an active version of 3.5.0 to test it with, it works well with 3.5.4 as it was written for and some others with versions lower then 3.5.4 have reported no issues, It could be a number of things two, a misplaced code snippet or the likes. I can't be shure without a testing environment.

SimCityForum
05-26-2006, 03:09 PM
does this work in 3.5.0

I installed it but can not see anything in the threads? is there something i need to do?

I would assume it works in v3.5.0 as I am using it in v3.5.3 on one of my forums and am quite happy with it.

susie_in_texas
05-28-2006, 01:51 PM
I am running 3.5.4. I have installed it but nothing shows up in the advanced editing options. I have rechecked all of my codes and template edits to make sure I didn't miss anything.

Also there is nothing showing in ACP (under VB Options) for configeration..should there be? It shows as installed under products....

Any ideas why it is not working?

ETA****

Never mind.. It installed fine.. I didn't realize I had to go in to the forum permissions of each forum and turn it on. It is working great!

****

Eikinskjaldi
05-29-2006, 05:20 PM
This was ported before i understand making vBOptions pages, but to be fully honest there isnt many options to go with it, its more per forum like you pointed out. I might eventually add an options page if I get the time to look into that last error.

xfaethorx
05-30-2006, 06:38 AM
when i try to edit a thread now to add an extra user i get the following error.

"Please complete the title field for this thread."

however its already there. I believe everything has been installed correctly.

Eikinskjaldi
06-01-2006, 12:57 AM
The hack shouldnt have anything to do with the title field what so ever, thats something either one of your other scripts messed with or you messed up on installation. Maybe you accidently renamed the title field when making a template edit, seems kind of odd, but I don't know what else to offer you.

COBRAws
07-06-2006, 12:18 AM
I've been looking for this one! Thanks for the port Eikinskjaldi! (where u from? weird nickname)

paul41598
07-17-2006, 04:55 PM
lookin forward to the future plans. I could use this for the usergroups part of it. I.E --> the hack only being available to sepcific usergroups.

Simplicity
08-03-2006, 07:54 AM
This is a great mod

However there are 2 question!

1. How could I enable extra usergroups to access this, or when will the functionality be available?

2. I want to only give my users the ability to make their thread private (only admin/moderators can view it) or public, thread is open to all.

Ideally a simple thread [ Private o or Public o ] button would be great without the other fields, this would hopefully reduce confusion for some members. Would this be a simple edit to the code or more complex?

The only way I can really do this now is make two forums, one for private threads where users can only view their own threads, and a open forum where all threads are open. This makes the forum a little more cluttered. Any suggestions wold be appreciated

Eikinskjaldi
08-04-2006, 05:27 AM
I am a bit busy with upgrading and we are moving to a new version on the site I am primarily tech. for. I will give some suggestions really quickly though.

Allowing other usergroups to make private threads is as simple as editing the permissions function.

Making a special switch would be adding it to the form template and then pulling it and setting the two private thread variables with what you want if it is seclected as private. You might still need to edit permissions.

Sorry to be breif or make little sense but I am tired and I have been coding most of today and wont be stopping till I am done. what a dasy for 3.6 to release, what a day.

bondjetta
08-31-2006, 07:52 PM
Any word on a port to 3.6? :D

Tigerdude
09-02-2006, 12:54 PM
Any word on a port to 3.6? :D
Ditto. Has anyone tried this on 3.6? Does it work?

I definitely need this.

Eikinskjaldi
09-02-2006, 08:46 PM
I am going to release a version for 3.6 but it wont really be a port, i am finally going to release a version with all the bug fixes and such that this one never had. So yes it will be coming soon. It resembles less of the old version and more of my own code but at its heart it is still the same program, so port or new, its coming.

wholemama
09-03-2006, 11:28 PM
Has anyone successfully had this working on 3.6?

Tigerdude
09-05-2006, 12:45 AM
I am going to release a version for 3.6 but it wont really be a port, i am finally going to release a version with all the bug fixes and such that this one never had. So yes it will be coming soon. It resembles less of the old version and more of my own code but at its heart it is still the same program, so port or new, its coming.
Thats great to hear! Looking forward to it and thanks for doing it. :up:

SimCityForum
09-12-2006, 03:27 PM
Has anyone successfully had this working on 3.6?

Yes if you just upgraded from vB3.5x to vB3.6 you need to go back through and modify your templates and FOUR vBulletin PHP files as per the instructions.

Be very careful and use a little judgement as there are subtle adjustments that need to be made. For instance in postings.php the following mod needs to be used:

// M/DD/YY PRIVATE THREADS PORT

if ($_POST['do'] == 'updatethread')
{
$vbulletin->input->clean_array_gpc('p', array(
'visible' => TYPE_BOOL,
'open' => TYPE_BOOL,
'sticky' => TYPE_BOOL,
'iconid' => TYPE_UINT,
'notes' => TYPE_NOHTML,
'threadstatus' => TYPE_UINT,
'reason' => TYPE_NOHTML,
'title' => TYPE_STR,
'redirect' => TYPE_STR,
'frame' => TYPE_STR,
'period' => TYPE_UINT,
'privatethread' => TYPE_UINT,
'privateusers' => TYPE_STR
));
// END PRIVATE THREADS PORT


Instead of:

// M/DD/YY PRIVATE THREADS PORT

if ($_POST['do'] == 'updatethread')
{
$vbulletin->input->clean_array_gpc('p', array(
'visible' => TYPE_BOOL,
'open' => TYPE_BOOL,
'sticky' => TYPE_BOOL,
'iconid' => TYPE_UINT,
'notes' => TYPE_NOHTML,
'threadstatus' => TYPE_UINT,
'reason' => TYPE_NOHTML,
'title' => TYPE_STR,
'redirect' => TYPE_STR,
'privatethread' => TYPE_UINT,
'privateusers' => TYPE_STR
));
// END PRIVATE THREADS PORT


because of the two additional fields in v3.6. Just be careful and if you understand PHP you will be fine.

camoman
09-15-2006, 03:06 PM
IS there a way to have it NOT display the post to users who do not have permission to view it? right now when a user posts it shows the post on vbcmps but comes up with the No Permission reply. It would save some controversy on the site if people who didn't have permission to view it didn't see it at all..

also is there a way so that users can edit the list of people allowed to view the thread after the fact?

Eikinskjaldi
09-17-2006, 04:58 PM
Thanks for pointing out those little things above SimCit.

As for making it not show stuff on vbCMPS, I have not honestly looked into that because I dont show any private threads on it. However when the 3.6 version is released you can use a new permissions function for it most likely, but to make it look right you'd have to increase the amount of posts it takes in, to balance it out.

As far as making it editable by users, this seems to be a popular idea, I may e nd up making a page and such for it and just add it to inline tools but as I recall if you give the forums with private threads specific user permission they should be able to edit the thread or get to the place for editing options where they can also edit private users.

Been Told
11-21-2006, 10:32 AM
I am going to release a version for 3.6 but it wont really be a port, i am finally going to release a version with all the bug fixes and such that this one never had. So yes it will be coming soon. It resembles less of the old version and more of my own code but at its heart it is still the same program, so port or new, its coming.
That's great to hear :)
I just migrated from Invision and I had a hack that password-protected threads. This cool hack would be the nearest to that sort of thing I can find.

LadyBeth
11-26-2006, 10:53 AM
Really really need this for 3.6.3
Pretty please with sugar on top?

Been Told
11-29-2006, 06:06 PM
Same here... I migrated from Invision where I had a similar mod and my members want their private threads back lol.
:)

Revpolar
12-02-2006, 03:35 AM
I cant get it to work on 3.6. It does kinda work but when i select usergroup option everyone can see it. When I choose user option the selected user cant see it and get the your not allowed message. Im sure its a simple edit or two that would have it fully working.

Been Told
12-13-2006, 08:34 AM
I just got this to work on vBulletin 3.6!!!! Thanks very much for this great mod man! Awesome! :)

One Question though... How do I edit who can see the thread after it has been created?

Eikinskjaldi
12-16-2006, 01:58 PM
Currently only mods and admins can, you have to edit the actual thread. Same as the location where you edit the thread title. I am planning on moving this to its own option later on.

As for the official version for 3.6, iv run into to many time traps to get it out, when iv got the chance i'll start packaging the official Private Threads for 3.6

Revpolar
12-21-2006, 04:38 PM
Please do. I really would appretiate it.

soletrader
12-25-2006, 02:51 AM
Will be looking forward to the 3.6 release.

soletrader
12-25-2006, 06:18 AM
Does this hack allow a specific forum to display private threads only? I only want this in one of my forum. Thanks

chrisbr
12-25-2006, 07:30 PM
is there anyway that this can be reversed and used to block a user from a thread?

we sometimes have a thread when it is someones birthday and so would be nice to be able to @ban@ them from a thread created

Soliloquy
01-22-2007, 08:08 PM
I tried to install this on Ver. 3.6.4 but found I couldn't edit threads; I just get a blank page. I realize this mod wasn't intended for 3.6.4, but any ideas on how to fix this until the next version comes out would be appreciated.

Thanks Eikinskjaldi for a very useful mod!

Eikinskjaldi
01-27-2007, 12:25 AM
I am not sure why it would make your template go blank other then it is causing an error and you have php errors turned off, check your error log from cpanel to see what the error is.

As to the 3.6.4 edition, as things currently stand I am having issues optimizing a piece of it and until thats complete it won't release, as well it is not my top priority currently as other things have come up related to the site I co-own. It has the option to block users if I recall right, its one of the 3 or 4th options, if not i'll make shure to make that part of the next release.

Mum
02-01-2007, 04:38 PM
Can't wait for the 3.6.4 version! My members will love this!!! Especially the ban one member bit :)

ashley53680
02-05-2007, 11:35 PM
Subscribing so I can be here for the 3.6.4 version!

solinarius
03-06-2007, 07:45 PM
Hello :)
Any progress of this awsome mod ?

COBRAws
03-29-2007, 01:29 AM
Any update on this?

Singularity
05-03-2007, 02:21 PM
I am not sure why it would make your template go blank other then it is causing an error and you have php errors turned off, check your error log from cpanel to see what the error is.

As to the 3.6.4 edition, as things currently stand I am having issues optimizing a piece of it and until thats complete it won't release, as well it is not my top priority currently as other things have come up related to the site I co-own. It has the option to block users if I recall right, its one of the 3 or 4th options, if not i'll make shure to make that part of the next release.
Do you have any idea on when you expect to release Private Threads Redux?

Eikinskjaldi
05-11-2007, 01:06 AM
If it does get released it probably will not be till well into the summer at this point, this hack has dropped to the bottom of my list in priority due to other factors in my life and my own websites needs. It will come out eventually, but until such a time you may find it more time efficient to pay someone to do it for you, even if its just a port to work with 3.6

Mrdby
05-17-2007, 09:50 PM
3.6.6?

Zeitgeist
06-30-2007, 02:16 PM
For all those users who have problems with limiting a thread to certain usergroups: the key is that you musn't enter the usergroupid - you have to enter the title of the usergroup! When you do this, the thread is only viewable to this usergroup(s). Just to let you know this...

agsguar
07-02-2007, 06:42 PM
For all those users who have problems with limiting a thread to certain usergroups: the key is that you musn't enter the usergroupid - you have to enter the title of the usergroup! When you do this, the thread is only viewable to this usergroup(s). Just to let you know this...

you can install this hack in 3.6.7 vb version?? how?

G0F0RBR0KE
07-12-2007, 10:54 AM
I'm testhing this for 3.6.7

Singularity
07-12-2007, 11:37 AM
I'm testhing this for 3.6.7
Excellent.

G0F0RBR0KE
07-12-2007, 12:28 PM
Currently, manage to get the

"This is a private thread and you are not allowed to see it."

Normandi2
07-17-2007, 08:45 PM
Installed.
Thank you

netwind
08-19-2007, 07:31 AM
Did you forget about text-based archive ? /forum/archive/

Kaelon
09-19-2007, 02:19 PM
Has this been updated for vB 3.6.8? I saw that there was some testing with 3.6.7, but it's unclear whether it worked.

bandanafz1
09-19-2007, 02:41 PM
Yes same here as well... this is a great mod for me... but I'm running VB3.6.8 - of course I could just throw caution to the wind and go for it like I usually do :p

Thion
05-11-2008, 09:35 PM
Any chace, this will be portet to 3.7.0??!?!

Amiga Harrison
06-25-2008, 12:38 PM
This mod works perfectly as it is for vB 3.7.2

I've been using it since vB 3.6.4 and it has continued to work for all versions. You just need to be careful when editing the forum files and use common sense as some of the code has changed slightly since this mod was written.

It would be great if someone could write a product for this mod. It would mean no more manual file edits were needed, and we could then update vB without needing to worry about then having to re-edit all of the files again.

Would anyone be interested in writing this as a product for 3.7? I can't understand why a Private Threads mod like this isn't more popular or needed on most forums. It is invaluable on mine.

charokee
06-27-2008, 09:10 AM
I'm running it on an vBulletin 3.7 and it works fine.

I just have a problem because a registered user can't edit the thread-options when a reply has been postet. Is there any abillity that users can edit their thread options theirself?

Tyran1
12-27-2008, 02:16 AM
It works on vBulletin 3.8 RC 2 !!!

Tyran1
12-27-2008, 02:57 AM
Bug up Version 3.6.4 !!!

edit in the posting.php is not works!! Ist a Bug !!!

LadyBeth
12-29-2008, 02:58 PM
Can anyone tell me if this works in 3.7.4?

Thanks!
LB~

Mr.Abdullah
08-09-2009, 09:06 AM
Is there a new version??

3,8,3

?????????

Amiga Harrison
06-09-2010, 05:01 PM
Anyone know of anything like this for vB4?

I have quite a few threads in my current vB3.8.5 forum hidden from view with this mod that will suddenly become visible to all when I upgrade.

Bundle
06-11-2010, 11:52 PM
Anyone know of anything like this for vB4?

I have quite a few threads in my current vB3.8.5 forum hidden from view with this mod that will suddenly become visible to all when I upgrade.


+1 for that, would love to have this on my VB4 forum. Any chance of an upgrade?

Wolver2
09-01-2013, 11:58 AM
same here.. need it badly for 4.2.1 anyone with solutions?