UBB.Dev
Posted By: donJulio I need some help with my postlist.tmpl file - 06/06/2005 5:15 AM
When I click on the button to expand the topics, and I click on a specific post, it brings up the showflat mode when it should bring up the post in flat when it should be threaded. Example here:
http://www.laondalatina.com/foros/postlist.php/Cat/0/Board/telenovelas
Click on the + to expand the topics and click on a message and it brings up showflat. I'm attaching the postlist.tmpl file to look at, though I'm not sure if this is a problem with postlist.tmpl or postlist.php. Any help would be appreciated

Attached File
128195-postlist.tmpl  (379 downloads)
Posted By: Anno Re: I need some help with my postlist.tmpl file - 06/06/2005 11:04 AM
>it brings up the showflat mode when it should bring up the post in flat when it should be threaded.

Hmm....
So what exactly do you want? Do you want it to display threaded in this case?
The code for this is in likely in postlist.php.
It just seems odd to me that when in expanded view you get showflat when clicking on a message. I thought it was supposed to bring up the threaded mode. I changed my preference to Expanded in my profile and it still did it. In fact, it does it here at ThreadsDev as well, so maybe it's supposed to do that. Doesn't make sense to me at least.
Posted By: Anno Re: I need some help with my postlist.tmpl file - 06/07/2005 11:14 AM
By design it is supposed to do so, correct.
If you want it to go to the showthreaded, you will have to change the postlist.php file a bit. Which version are we talking about?
I'm on version 6.5.1.
Posted By: Anno Re: I need some help with my postlist.tmpl file - 06/08/2005 10:47 AM
Well, here at threadsdev, when you have threaded mode selected, and you choose expand, then the links to the individual posts are in threaded mode.

I found a bug though:

The desired behavior is that when you click on a link in the expanded list when displaying posts in flat mode, it takes you directly to the post.
It doesn't do that though, since the syntax is wrong in postlist.php

Fix:

in postlist.php
search for:
$postrow[$z]['goto'] = "#$PNumber";

Replace with:
$postrow[$z]['goto'] = "#Post$PNumber";

Search for:
$postrow[$z]['goto'] = "#$Number";

Replace with:
$postrow[$z]['goto'] = "#Post$Number";
Posted By: Anno Re: I need some help with my postlist.tmpl file - 06/08/2005 10:55 AM
OK, to your problem:
If you want the links to be threaded regardles of the board setting or the user preference, then:

in postlist.php

search for:
if (!$debug) {

insert before:

if($view == "expanded"){
$mode = "showthreaded";
}
© UBB.Developers