Register Members List Search Today's Posts Mark Forums Read

Reply
 
Thread Tools
  #1  
Old 24 Feb 2017, 19:15
tommythejoat's Avatar
tommythejoat tommythejoat is offline
 
Join Date: Apr 2008
Real name: Tom McIntyre
Question Is the vB4 thread structure broken

The two methods to reply in a thread are to reply to the post you are viewing using the reply link in the bottom border or to reply to the thread.

The reply to specific post works correctly and puts that postid in the parent postid for the new post. However, when you are replying to the thread, the parent postid is the latest post in the thread when it should be the first post in the thread.

The problem is readily visible when using hybrid or threaded view.

I would like for the parent postid to be 0 just as it is for the starting post in the thread. That gives a distinctive display for hybrid and threaded views.

We have a mod installed that appends a link in the title of the posters name linking to the parent postid. If the parent postid were 0 for reply to thread, the link would be suppressed and it would work the way we want it to.

The reference functions to prevent misunderstandings when someone thinks a reply is to their post instead of to a previous post in the thread or the thread as a whole.
Reply With Quote
  #2  
Old 24 Feb 2017, 19:58
MarkFL's Avatar
MarkFL MarkFL is offline
 
Join Date: Feb 2014
Real name: Mark
Try this plugin, hooked at "postdata_presave":


Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

__________________
Former vBulletin.org Staff Member



Support for my products (as well as updates/new product publishing) has been moved to MHB - vBulletin Products and TAZ - Add-ons
Reply With Quote
  #3  
Old 24 Feb 2017, 22:50
Bill Stuntz Bill Stuntz is offline
 
Join Date: Feb 2015
If it set the parentid to 0 instead of the incorrect postid that it picks now when invoked by "Reply to Thread" it shouldn't display ANY link in that new post title - which is what I want.
I asked the SAME question a couple days ago in another thread, http://www.vbulletin.org/forum/showthread.php?t=324497, trying to find SOME hook somewhere that would allow me to do EXACTLY that. We described different symptoms of the same disease, caused by the same germ. Tom & I are Admins on the same MB. Needless to say, HE's the senior admin, and I'm trying to learn.

I'm curious. Why did Tom get an essentially immediate response that does EXACTLY what I've been asking for, and my thread didn't? Have I done something to offend someone?
Reply With Quote
  #4  
Old 24 Feb 2017, 22:57
Paul M's Avatar
Paul M Paul M is offline
 
Join Date: Sep 2004
Real name: Paul M
Replies can sometimes be days.
Any response is entirely dependent on who is reading the forums at any given time
Your thread got a reply after 81 minutes, so I think you have nothing to be curious about.
__________________
Former vBulletin.org Staff Member


Cable Forum
Please do not PM me about custom work - I no longer undertake any.
Note: I will not answer support questions via e-mail or PM - please use the relevant thread or forum.
Reply With Quote
  #5  
Old 24 Feb 2017, 23:14
Bill Stuntz Bill Stuntz is offline
 
Join Date: Feb 2015
Yes, you DID respond that fast. And your response allowed me to find the apparently undocumented plugin that gave me the hint that I had to modify parentid. But I couldn't figure out where/how to do that. MarkFL's response does exactly what I've spent days trying to figure out. It wasn't so much the SPEED of the responses that bothered me. Is MarkFL the only one who knows that trick?

It should solve the problem for future posts, but I doubt that there's any way to fix the existing misleading links.
Reply With Quote
  #6  
Old 24 Feb 2017, 23:15
MarkFL's Avatar
MarkFL MarkFL is offline
 
Join Date: Feb 2014
Real name: Mark
Originally Posted by Bill Stuntz View Post
I asked the SAME question a couple days ago in another thread, http://www.vbulletin.org/forum/showthread.php?t=324497, trying to find SOME hook somewhere that would allow me to do EXACTLY that. We described different symptoms of the same disease, caused by the same germ. Tom & I are Admins on the same MB. Needless to say, HE's the senior admin, and I'm trying to learn.

I'm curious. Why did Tom get an essentially immediate response that does EXACTLY what I've been asking for, and my thread didn't? Have I done something to offend someone?
Hey Bill,

I do apologize if I gave the impression of preferential treatment...it wasn't my intention. Tom's initial post spoke explicitly of setting the "parentid" of posts made by replying to threads as opposed to replying to posts or quoting posts.

In your thread, you were talking about using a product that wasn't behaving as you wanted, and when I read that, I felt looking for the product thread was a good idea as suggested. Sometimes I don't connect the dots as would be desired by the person posting.

It could be the case when I read a post here, I am either idle and looking for something to do, or I am busy at the moment with other things and don't give the post as much attention as I would in the first scenario. That's my shortcoming, not that of anyone else, and is something I should try to improve.
__________________
Former vBulletin.org Staff Member



Support for my products (as well as updates/new product publishing) has been moved to MHB - vBulletin Products and TAZ - Add-ons
Reply With Quote
  #7  
Old 24 Feb 2017, 23:22
Bill Stuntz Bill Stuntz is offline
 
Join Date: Feb 2015
Thanks Mark. It was the stuff I found, guided by Paul's post, that allowed Tom to ask the question in the way he did. THANK YOU BOTH for the help!!!!!!!!!!!!!

P.S. I think I made the same point over there, too:
It works properly when replying to a specific post by using the correct non-zero parentid, but "Reply to Thread" seems to pick an inappropriate parentid.
P.P.S. I intend to install the "editor button" mod you did for me after things settle down & we get on the new system.

--------------- Added 24 Feb 2017 at 23:33 ---------------

Tom, are you going to install the fix, or are you going to leave it as an exercise for the student?

Last edited by Bill Stuntz; 24 Feb 2017 at 23:29.
Reply With Quote
  #8  
Old 24 Feb 2017, 23:38
MarkFL's Avatar
MarkFL MarkFL is offline
 
Join Date: Feb 2014
Real name: Mark
Originally Posted by Bill Stuntz View Post
Thanks Mark. It was the stuff I found, guided by Paul's post, that allowed Tom to ask the question in the way he did. THANK YOU BOTH for the help!!!!!!!!!!!!!

P.S. I think I made the same point over there, too:
P.P.S. I intend to install the "editor button" mod you did for me after things settle down & we get on the new system.
Yeah, that was part of me not connecting the dots when you posted. I believe also when you posted, I was hip deep in coding a custom mod for MHB (which turned out quite well!) and my mind was elsewhere. I'm not a good multi-tasker.

By the way, and I say this not to be self-effacing, but you asked if I was the only one who knew that trick. Of all those on staff here, and many who aren't on staff, I am the new guy still learning the basics.

I hope the custom editor toolbar mod works well for you!
__________________
Former vBulletin.org Staff Member



Support for my products (as well as updates/new product publishing) has been moved to MHB - vBulletin Products and TAZ - Add-ons
Reply With Quote
  #9  
Old 25 Feb 2017, 01:03
Snowhog's Avatar
Snowhog Snowhog is offline
 
Join Date: Oct 2011
Real name: Paul L
Originally Posted by MarkFL View Post
Try this plugin, hooked at "postdata_presave":


Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.
I don't want to assume, so will adding this have any effect if using the default Linear Mode?
__________________
"It is a capital mistake to theorize in advance of the facts." - Sherlock Holmes
Kubuntu Forums . Net | ZB BLOCK | StopForumSpam
Reply With Quote
  #10  
Old 25 Feb 2017, 01:09
MarkFL's Avatar
MarkFL MarkFL is offline
 
Join Date: Feb 2014
Real name: Mark
Originally Posted by Snowhog View Post
I don't want to assume, so will adding this have any effect if using the default Linear Mode?
All I can tell you for sure is that with that code in place, when a reply is made without replying to or quoting a specific post, then the "parentid" for that post will be set to zero.
__________________
Former vBulletin.org Staff Member



Support for my products (as well as updates/new product publishing) has been moved to MHB - vBulletin Products and TAZ - Add-ons
Reply With Quote
  #11  
Old 25 Feb 2017, 23:02
tommythejoat's Avatar
tommythejoat tommythejoat is offline
 
Join Date: Apr 2008
Real name: Tom McIntyre
Originally Posted by MarkFL View Post
All I can tell you for sure is that with that code in place, when a reply is made without replying to or quoting a specific post, then the "parentid" for that post will be set to zero.
Actually, the fix needed a slight tweak on our Message Board. Apparently the 'p' index does not test false unless you use isset to test it.

I was a bit confused when it did not work on the first try, but I decided it could not possibly harm to make it.

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

The only effect except eliminating the thread reference (that we find troubling) is that in hybrid or threaded view, the link graphics show a broken line for each new reference to the thread. It seems to me that is a benefit rather than a problem.

--------------- Added 25 Feb 2017 at 23:16 ---------------

I do not think it is possible to make this "feature" retroactive.

In my opinion, the current vB4 behavior is broken. Clearly the reply to thread should set previous post to the starting thread post . There is no way to know what the poster intended or which button was used to create a new post since both point to the most recent post.

This fix does eliminate the problem. If one wanted the feature to actually reference the first post in the thread, that could be done or, retroactively in the future a query could be executed to set all the 0 parent postid values to the value of the first postid in the thread.

--------------- Added 26 Feb 2017 at 02:48 ---------------

I thought I had this fixed but when I went to install it on the live site, it did not actually work and when I checked again on the test site the result was the same.

I hacked the plugin to insert a print_r on the $_REQUEST global and got this result for both reply from the border and reply with the button.


Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

'p' and 'postid' are both set to the same value and not missing or 0, etc.

Is there a different hook that will work, or is one of my other mods busting this. I notice that there is a jquery flag that looks like it may be bad.
Reply With Quote
  #12  
Old 29 Apr 2017, 19:28
chloe101 chloe101 is offline
 
Join Date: Dec 2007
Have you found a fix for this yet? I'm running VB4.2.4 and just noticed the same exacerbating problem. I'm trying to find a fix for this and if not, I'll just remove that button because it's misleading & useless as is.
Reply With Quote
Reply


Tags
post reference, thread structure


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


New To Site? Need Help?

All times are GMT. The time now is 22:09.

Layout Options | Width: Wide Color: