vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 4.x Add-ons (https://vborg.vbsupport.ru/forumdisplay.php?f=245)
-   -   vBulletin CMS Widgets - [WIDGET] Recent Threads (https://vborg.vbsupport.ru/showthread.php?t=236404)

janaf 06-12-2010 10:14 PM

I like this widget!

Can someone tell us how to list not only forum posts but a mix of ALL the latest posts, in forums, articles etc, all in the same list, also in time order?

Videx 06-12-2010 10:55 PM

I believe this would list new articles, since those are created in a forum (and assuming you included the forum). But not blogs.

janaf 06-12-2010 11:20 PM

By Articles I meant in the CMS. Would those be included too? Or what do you mean by articles?

merk_aus 06-25-2010 04:24 AM

Quote:

Originally Posted by janaf (Post 2052702)
By Articles I meant in the CMS. Would those be included too? Or what do you mean by articles?

Yes they are included unfortunately which is why I am uninstalling it.

Ohiocustoms 06-25-2010 05:47 PM

Quote:

Originally Posted by merk_aus (Post 2059193)
Yes they are included unfortunately which is why I am uninstalling it.

Just don't typing in the forum id # for them ;)

rsuplido 06-25-2010 06:40 PM

Any way to add the user's mini avatar just like the default Latest Replies?

Also, why add the forumid condition after the fact? I suggest doing that in SQL like:
Code:

and forum.forumid NOT IN (105,83,121,110,82,112,109,101,102,72)


For those asking about going to the last post, 'newpost' is better, since it goes to the first reply that the member hasn't read.

Change:
Code:

$recent_thread[threadid].'">'
to
Code:

$recent_thread[threadid].'&goto=newpost">'

merk_aus 06-27-2010 09:39 AM

Quote:

Originally Posted by Ohiocustoms (Post 2059495)
Just don't typing in the forum id # for them ;)

Because I am not a lazy administrator and put things all in the one forum. MY front page news is typed directly into the front page they don't have a forum id so how do you propose we do it now then?

Instead of just posting to increase your post count it would be better if you realised everyone was not a lazy administrator and had all the news in one section.

unknown03 07-04-2010 03:11 PM

This is working great...Kind of..I may have found a bug

I have a private section that I don't want to appear in the results, but putting the forum id in the array causes the entire widget to not list ANYTHING..Through trial and error I discovered that it is because my forum settings are set to not act as a forum (as a category instead) --> because I only want people going through a private link without seeing other posts should they try to list the parent section..

So my question is this, instead of using the array to EXCLUDE forum id's, how can I set it to only INCLUDE forum ids?

EDIT:
Quote:

Originally Posted by Videx (Post 1999259)
It only has an exclusion array, so you would have to list all your other forums. Or just edit it and make the list inclusive. Take out the ! in "if (!in_array".

Found it, thanks Videx...

However, this doesn't seem to work

Ohiocustoms 07-05-2010 02:01 AM

Quote:

Originally Posted by merk_aus (Post 2060381)
Because I am not a lazy administrator and put things all in the one forum. MY front page news is typed directly into the front page they don't have a forum id so how do you propose we do it now then?

Instead of just posting to increase your post count it would be better if you realised everyone was not a lazy administrator and had all the news in one section.

Offered quick advice from your one liner of why you was uninstalling. Guess next time I won't try and increase my post count all 14 of them. By the way this mod pulls the data from the forum id's, guess were all lazy :confused:

PS
Admincp>forum&moderators>forum manager

Click on this one - vBCms Comments

At the top
Forum: vBCms Comments (id: 28)

See the id# and include it.

Your Welcome and have a nice day :)

Yurified 07-30-2010 03:01 PM

Thank you so much for this!
I was wondering is there a way that we can use this for forum sideblock?

avitor 07-31-2010 04:09 PM

hi
how make the thread'S view count ?
is possible to show this ?
thanks

inqelaab.org 09-17-2010 07:00 AM

Hi I just got vbulletin 4.0.6 installed and I am not being able to find this location to install this Widget
Plugin System > Manage Products > [Add/Import Product]

lubbie 09-17-2010 07:21 AM

this is no Plugin or an addon. U have to add the Code as written in the Widget´s decription. Reading might help sometimes

inqelaab.org 09-17-2010 08:53 PM

Thanks for the tip, reading does help... lol only thing I lack is concentration..

inqelaab.org 09-17-2010 08:58 PM

@Lubbie , can you tell me how can I show this on home page as well..

jacobsen1 09-23-2010 01:10 PM

installed, thanks!

Scan Cape Cod 10-01-2010 05:31 PM

Forgive my ignorance, but is there some comprehensive explanation as to why when I take the code in this mod and add it to the configuration of my php widget, save it, and return to it all I see is what was originally in the configuration box, which is:

Code:

$output = date(vB::$vbulletin->options['dateformat']) . "<br />\n";
Go easy kids, I'm a fledgling with this stuff, but my searches of this site for an explanation are coming up empty. I also see a few other questions of this nature in this thread, as the above displays the current date of course in the widget box. I'm obviously missing something, I'm just not versed in this stuff enough to deduce what it is.

Thanks in advance.

Videx 10-01-2010 06:41 PM

Can you save any widgets? Or you just can't save one with this code?

Scan Cape Cod 10-01-2010 09:10 PM

Can't save any in PHP format. HTML and the other canned CMS widgets work fine.

Videx 10-01-2010 09:38 PM

A quick search at vb.com shows it may be a server issue. http://www.vbulletin.com/forum/showt...ve+php+widgets

Scan Cape Cod 10-01-2010 11:00 PM

Indeed. I'll check further. Dummy here didn't search beyond .org .... I always seem to find my answers here...shame on me. Thanks for the handhold, I'll take it from here! :D Nice looking addition; I hope I can get it working.

Ronseal 10-20-2010 07:05 PM

Can anybody help me please? I'm trying to get this widget to display the info on two lines rather than four so I've added a table, however it's having none of it and I'm getting the following error.

Parse error: syntax error, unexpected '<' in /home/mysite/public_html/forum/packages/vbcms/widget/execphp.php(194) : eval()'d code on line 26


Many thanks. Ron :confused:

Quote:

ob_start();
global $vbulletin, $db;
//Begin Thread Counts
$toutput='';
$recent_threads = $vbulletin->db->query_read("
SELECT thread.threadid, thread.title, thread.dateline, thread.lastpost, thread.lastposter, thread.lastposterid, thread.visible, thread.open, thread.postusername, thread.postuserid, thread.replycount, thread.views, forum.forumid, forum.title as forumtitle
FROM " . TABLE_PREFIX . "thread AS thread
LEFT JOIN " . TABLE_PREFIX . "forum AS forum ON ( forum.forumid = thread.forumid )
WHERE NOT ISNULL(threadid) AND visible = '1' AND open!='10'
ORDER BY lastpost DESC
LIMIT 0, 10
");
$i = 0;
while ($recent_thread = $db->fetch_array($recent_threads))
{
$i++;
if (!in_array($recent_thread[forumid], array(105,83,121,110,82,112,109,101,102,72))) {
if ($i & 1) {$class='alt1';} else {$class='alt2';}
$recent_thread[title] = unhtmlspecialchars($recent_thread[title]);
$recent_thread[lastpostdate] = vbdate('M jS', $recent_thread[lastpost], 1);
$recent_thread[lastposttime] = vbdate($vbulletin->options['timeformat'], $recent_thread[lastpost]);
$toutput .='<tr><td>

<table>
<tr>
<td class="'.$class.'" align="left"><b><font color="#98B5E2" size="1" face="verdana,arial"><a href="showthread.php?t='. $recent_thread[threadid].'">'. $recent_thread[title].'</a></font></b>';</td>
<td class="'.$class.'" align="right">$toutput .='<b><span style="color: #E1E1E2"><font size="1" face="verdana,arial">Last Post By: <a href="member.php?u='.$recent_thread[lastposterid].'">'.$recent_thread[lastposter].'</a></font><br/></span>'; </td>
</tr>
<tr>
<td class="'.$class.'" align="left">$toutput .='<font size="1" face="verdana,arial">Forum: <a href="forumdisplay.php?f='.$recent_thread[forumid].'">'.$recent_thread[forumtitle].'</a> | Replies: '.$recent_thread[replycount].'</font>'; </td>
<td class="'.$class.'" align="right">$toutput .='<font size="1" face="verdana,arial">Posted: <strong>'.$recent_thread[lastpostdate].'</strong> at: <strong>'. $recent_thread[lastposttime].'</strong></font><hr/></td>
</tr>
</table>

</td></tr>';
}
}
//End Thread Counts

//Sidebar - Begin Forum Threads
$sb_threads = '
<table class="tborder" cellpadding="'.$stylevar[cellpadding].'" cellspacing="'.$stylevar[cellspacing].'" border="0" width="100%" align="center"> <thead> <tr> <td class="tcat"></td> </tr> </thead> <tbody> <div class="smallfont"> <tr> <td>
'.$toutput.'
</td> </tr> </div> </tbody> </table>
';
//Sidebar - End Forum Threads
echo $sb_threads;
$db->free_result($recent_threads);
$output=ob_get_contents();
ob_end_clean();

rsuplido 10-20-2010 07:22 PM

It has something to do with the

';

at the end of lines 26, 27, and 30. Try removing them.

Ronseal 10-20-2010 07:46 PM

Quote:

Originally Posted by rsuplido (Post 2112135)
It has something to do with the ';

Tried removing them '; but still get the same error. Really stuck with this, it should be so easy!

rsuplido 10-20-2010 07:51 PM

Same exact error? Same line?

Ronseal 10-20-2010 08:06 PM

Same error but line 27 instead.

mmacrypt 11-20-2010 02:33 PM

Hey guys, with the .8 upgrade, this widget's colors don't flow with the rest of my site. I've tried finding the control in the StyleVars area but nothing effect it. Not very good at this stuff but can somebody point me in a direction.
As you can see, I have the left side working fine now but just don't know what controls the right widget.
https://vborg.vbsupport.ru/external/2010/11/33.png

cykelmyggen 12-09-2010 04:35 PM

Sorry for my ignorance, but is there a way to make this fine widget show pictures if listet as the first subject in the post? As for now it just shows the imagelink.

Joey Link 01-23-2011 10:56 PM

How do we change the color of the text?

HouseAddict 02-09-2011 08:14 PM

Has anyone figured out how to add the thumbnails to this? As in, beside each post you have the poster's thumbnail of some sort, just to add more "color" to this widget and liven up the actual CMS pages...

I'd kill for that!

MelH 03-17-2011 02:37 AM

Is this working in vB4.1.2?
And if it is did it work out of the box or are there changes required?

Thanks....

Videx 03-17-2011 02:14 PM

Mine still seems to be working after updating to 4.1.2. But let us know. Be sure to read the entire thread before you install it so you understand the later changes.

Gorgias 04-10-2011 01:41 PM

Quote:

Originally Posted by rsuplido (Post 2059510)
For those asking about going to the last post, 'newpost' is better, since it goes to the first reply that the member hasn't read.

Change:
Code:

$recent_thread[threadid].'">'
to
Code:

$recent_thread[threadid].'&goto=newpost">'

I have tested this, but it doesn't work for me (vB4.1.2). It goes to the page of the last post, but always on the top of the page. The link in the widget is

Code:

http://www.mydomain.com/forumo/showthread.php?t=7829&goto=newpost
and then redirects to
Code:

http://www.mydomain.com/forum/showthread.php?t=7829&p=316642
instead
Code:

http://www.mydomain.com/forum/showthread.php?t=7829&p=316642#post316642
or
http://www.mydomain.com/forum/showthread.php?p=316642#post316642

I have tried to add the correct address... but no one of my tests have work. Does anyone have any idea to fix it?

Thanks in advance.

Regards!!!

shuangddr 05-14-2011 12:28 AM

how to show Threads full content?

Videx 05-14-2011 02:58 AM

Quote:

Originally Posted by shuangddr (Post 2195403)
how to show Threads full content?

In a widget? That makes no sense. A single post could fill the whole box.

But if you're really determined, I bet you could edit the code to do that.

sticky 06-01-2011 04:50 AM

How do I change the color of "last post by" ?

LisaArnold 07-10-2011 04:14 AM

Quote:

Originally Posted by sqzdog (Post 1988981)
Hey Cory- nice widget. I would like to use this but have it show latest posts instead of threads. Is there an easy way to do this?

vB already has a widget for recent post ... in vB 4x anyway.

claystation 08-01-2011 09:19 PM

This is very nice, I am not a php programmer so I am looking of some help with how I might make it so only the threads show up with no reply posts. I am trying to create a widget that contains only unanswered posts.

Thanks

Wordplay 09-20-2011 12:24 PM

Quote:

Originally Posted by x626xblack (Post 1991931)
Difference between this and the New Addition to the CMS for 4.0.2 "Recent Threads"?
I do believe it is built in now and there are no permission issues.

where or how did you find a recent threads widget? i only have recent posts.

Videx 09-20-2011 06:29 PM

Quote:

Originally Posted by Wordplay (Post 2248190)
where or how did you find a recent threads widget? i only have recent posts.

Unless I'm mistaken, this thread is about a "recent threads" widget. Be careful though, as I think there are better versions than the one in the first post.


All times are GMT. The time now is 12:45 AM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01616 seconds
  • Memory Usage 1,830KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (9)bbcode_code_printable
  • (12)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (3)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (40)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete