MyBB Hacks

Full Version: Filtering Thread By Thread Author
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2 3 4
Well, finally, we can do this now Biggrin

The basic concept maybe like this:

Code:
filterxt_uid=user_uid

So, we can use it for several purposes:

1. Displaying Thread By Thread Author:

To do this, find this code in our forumdisplay_thread template:

Code:
{$thread['profilelink']}

Replace it with:

HTML Code
{$thread['profilelink']} &minus; <a href="{$forumurl_q}filterxt_uid={$thread['uid']}">All Threads In This Forum</a>

Now, after the thread user name, there is a link for displaying all threads by that user in that forum id.


2. Displaying All My Threads In This Forum (Link In Threadlist):

We can put this kinds of URL directly in our forumdisplay_threadlist template:

HTML Code
<a href="{$forumurl_q}filterxt_uid={$mybb->user['uid']}">Whatever</a>

Now, when our users viewing a threadlist, they can click the link to display all threads by them. We can use it for our XThreads application.
Example for Images Gallery:

HTML Code
<a href="{$forumurl_q}filterxt_uid={$mybb->user['uid']}">Display All My Images</a>

Maybe it is better to use conditional there, so, only member can view the link.

3. Displaying All Threads By A Member In A Forum (Link In Profile Page):

Put this kinds of URL directly in our member_profile template:

HTML Code
<a href="forumdisplay.php?fid=forum_id&amp;filterxt_uid={$memprofile['uid']}">Whatever</a>

Replace forum_id with a forum ID.
Now, each user has a link in their profile page to a specified forum id to display their threads only. We can use it for our XThreads application.
Example:
Images Gallery -> Forum ID = 9:

HTML Code
<a href="forumdisplay.php?fid=9&amp;filterxt_uid={$memprofile['uid']}">Display All Images By {$formattedname}</a>


4. Displaying All Threads By A Member In A Forum (Link In Postbit):

Put this kinds of URL directly in our postbit template:

HTML Code
<a href="forumdisplay.php?fid=forum_id&amp;filterxt_uid={$post['uid']}">Whatever</a>

Replace forum_id with a forum ID.
Now, each user has a link in their postbit to a specified forum id to display their threads only. We can use it for our XThreads application.
Example:
Images Gallery -> Forum ID = 9:

HTML Code
<a href="forumdisplay.php?fid=9&amp;filterxt_uid={$post['uid']}">Display All Images By {$post['username_formatted']}</a>

Maybe it is better if we put conditional there, so, the link will not be displayed if the post author is a guest.

Whoa - maybe coming soon, but how did you get the images and links to the picture forum in the profile like that? I have wanted that forever for my profile page for my downloads threads...............
It's an interesting idea RateU, but unfortunately, there's a few problems with this:
  • existing threads in the forum won't have the UID set
  • it relies on the submitted input to give the correct UID - a user could fake this
  • certain moderation options (move thread, split thread etc) can break this, though I suppose this is an issue with any required field for XThreads

A dedicated plugin would really be better for this...
(08-10-2010 08:43 PM)ZiNgA BuRgA Wrote: [ -> ]existing threads in the forum won't have the UID set

I realized it, Yumi. Basically, I use it for new forum.

(08-10-2010 08:43 PM)ZiNgA BuRgA Wrote: [ -> ]certain moderation options (move thread, split thread etc) can break this

I didn't thought about this Biggrin

(08-10-2010 08:43 PM)ZiNgA BuRgA Wrote: [ -> ]it relies on the submitted input to give the correct UID - a user could fake this

I think this is the biggest issue...

(08-10-2010 08:43 PM)ZiNgA BuRgA Wrote: [ -> ]A dedicated plugin would really be better for this...

Unfortunately, only XThreads right now has a filtering system. But it's OK, Yumi. I think MyBB built in search system has "something" like this.

Thank you very much for the review, Yumi Smile
I've edited my first post Smile And I'm really sorry for my mistake.

(08-10-2010 01:02 PM)leefish Wrote: [ -> ]how did you get the images and links to the picture forum in the profile like that?

I use a similar query like forum attachment gallery, Lee.
Keep up with the ideas RateU though - you've thought of some very novel ways to do things!
(08-11-2010 01:39 AM)RateU Wrote: [ -> ]
(08-10-2010 01:02 PM)leefish Wrote: [ -> ]how did you get the images and links to the picture forum in the profile like that?

I use a similar query like forum attachment gallery, Lee.

Sorry to hijack this thread RateU, but I would sell my favourite sim to the devil to have that threads posted in that layout showing for each users profile on my forum. Is there any possibility of sharing that plugin?

If its a no, I quite understand but er WOW.
(08-11-2010 08:57 AM)ZiNgA BuRgA Wrote: [ -> ]Keep up with the ideas RateU though

Thanks, Yumi Smile

@ leefish: This is what I use. Maybe we need to modify it a bit, because I created it for XThreads images gallery.
Thanks RateU, I shall have a look. (Lee runs off with new toy- yay)
Sorry for this to be off topic too, but wow RateU, that is exactly what I've been looking for! Thanks so much!
Hi RateU - maybe time to split this thread - Wink

Anyway, I was looking at the plug in you posted, and once again I have the need to get only the first picture in a given thread.....I tried modifying the plug in, but it kept blowing up Smile I was attempting to make the plugin show only the first picture from a thread and then show the next thread - pretty much as in the latest attachment gallery but with the styling of this plug in. I kept getting errors in my SQL syntax.

Its working well for Flaba because only ONE of his pictures per post are Xthreads attachments - for me, all of them are Xthreads attachments so I cant get the effect like on TSS (Flabas site)

Here is a link to how Flaba has the look:

http://thesimsupply.com/user-Flabaliki
Pages: 1 2 3 4
Reference URL's