vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 2.x Full Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=4)
-   -   Latest Threads on Your Desktop (https://vborg.vbsupport.ru/showthread.php?t=36008)

N!ck 03-10-2002 10:00 PM

Latest Threads on Your Desktop
 
This hack will show the 30 latest threads on your desktop, ordered descending by the latest post. Somebody please post a screenshot; my screenshot program can't get my desktop.

There is no file editing and no template editing. It's very easy to install, even for a novice.

Click here for a screenshot!

Current Version: 3.0 (update recommended if you have 1.0)
Version 3.0 is not what I would call a "fix", but it adds an option to prevent threads in private forums from being viewed unless the viewer is allowed to access private forums (guests ARE allowed by default). It also allows you to change the number of latest threads to be viewed.

Have fun, and post your comments if you use this, please!

N!ck 03-11-2002 09:36 PM

Latest Threads on Your Desktop SE

It's done!!!

See this thread: https://vborg.vbsupport.ru/showthrea...threadid=36189

nafae 03-11-2002 09:47 PM

So how does this show the latest threads on your desktop? Could you be more specific in what exactly it does?

Thanks,

Nafae

wooolF[RM] 03-11-2002 10:05 PM

taskbar ticker?

N!ck 03-11-2002 10:07 PM

no - it displays on your DESKTOP

this is ideal for those who don't want to hog up their taskbar space

okrogius 03-11-2002 10:24 PM

Great job!

TECK 03-11-2002 10:47 PM

can we have a screenshoot?

JulianD 03-11-2002 11:24 PM

A screenshot would be nice :)

Recon_Boy 03-11-2002 11:57 PM

Well basically it's a list of threads, last poster, replies and views that refreshes every so often.

Problem is, it shows all threads from all forums including private ones, so I'm gonna have to see about narrowing that down a bit unless the author gets to it first.

N!ck 03-11-2002 11:57 PM

you're all so...persistent! lol

here's a screenshot (i got a program that does the desktop and not just windows!)

N!ck 03-12-2002 12:00 AM

thanks for the kind comments, codename49

Recon_Boy 03-12-2002 12:15 AM

p.s. it IS rather cool :D

N!ck 03-12-2002 12:42 AM

oooh...i need to put in a variable to toggle private forum thread display...

give me ten minutes and i'll have it done

Recon_Boy 03-12-2002 12:45 AM

*starts timer* ;)

N!ck 03-12-2002 01:10 AM

i need a little help with the query...it's posted in the 'help!' forum

x28 03-12-2002 01:11 AM

U the man!!! for 2002

N!ck 03-12-2002 01:21 AM

thx

MrLister 03-12-2002 02:17 AM

when is special edition coming?

TECK 03-12-2002 03:31 PM

wow.. great job nick. congrats on your good work. i really like it. i will install it. :)
i will look right now for the query problem. now i understand your question. i apologise if i offended you in any way.

all the best,
nakkid.

TECK 03-12-2002 04:38 PM

nick i just looked at your code. it's simple, but perfect. what do you try to add extra? i still dont understand your query.. :(

please post more details on the thread you started in Help.

TECK 03-12-2002 05:38 PM

nick, try something like that to. let me know if it worked.
PHP Code:

<?php
error_reporting
(7);

$templatesused "home_newthreads,home_latestthreads";
require(
"./global.php");

$maxthreads=30;

$doforumperms=$DB_site->query("SELECT forumid FROM forum");
$forumslist="";
while (
$forumperms=$DB_site->fetch_array($doforumperms)) {
  
$forumid=$forumperms[forumid];
  
$getperms=getpermissions($forumid);
  if (
$getperms[canview]) {
    
$forumslist.=",$forumid";
  }
}

$newsql=$DB_site->query("SELECT * FROM thread WHERE forumid IN (0$forumslist) AND visible=1 ORDER BY lastpost ASC LIMIT 0,$maxthreads");
while (
$new=$DB_site->fetch_array($newsql)) {
  
$getforumid=$new[forumid];
  
$getnewsql=$DB_site->query_first("SELECT * FROM post WHERE forumid=$getforumid");
  
$forumname=$DB_site->fetch_array($getnewsql);
  
$geticonid=$new[iconid];

  if (
$new[iconid]==0) {
    
$newicon="<img src=\"{imagesfolder}/icons/icon1.gif\" border=\"0\">";
  } else {
    
$newicon="<img src=\"{imagesfolder}/icons/icon$newconid.gif\" border=\"0\">";
  }

  
$getthreadid=$new[threadid];
  
$gettitle=$new[title];
  
$getforumname=$forumname[title];
  
$getreplycount=$new[replycount];
  
$getusername=$new[postusername];
  
$getuserid=$new[postuserid];
  
$gettime=vbdate($timeformat,$new[dateline]);
  
$getdate=vbdate($dateformat,$new[dateline]);

  eval(
"\$newthreads .= \"".gettemplate('home_newthreads')."\";");
}

eval(
"dooutput(\"".gettemplate('home_latestthreads')."\");");
?>


mondaynightmike 03-12-2002 09:21 PM

wow this is a good idea.

N!ck 03-12-2002 09:25 PM

nakkid,
i think i might have a solution looking at your code. i didn't even THINK about using the getpermissions() function!

MrLister,
the "special edition" is going to have a bunch of features that some might consider "bloatware" - so that's why it's not going to be an "ordinary" release.
expect it sometime this weekend, i'd say. it will include almost all the features of the Forum Display page, will show announcements, and will have some other options that i don't even know of yet!!! :)

so yeah, this weekend...thanks for the suggestion nakkid...

cditty 03-12-2002 09:43 PM

How would I go about adding a refresh button to force a refresh within the same window? I added a simple refresh and it opens a full sized window.

Also, how would I go about adding the current users on the very bottom? I looked at a few existing templates but couldn't figure it out.

Chris

N!ck 03-12-2002 10:16 PM

add target="_self" to the <a> tag.

cditty 03-12-2002 10:19 PM

Oh gesh.....I can't believe it was that. I'm gonna go crawl under my rock. Call me when the new version is ready. :)

Chris

lordofgun 03-13-2002 02:42 AM

AWESOME JOB!

Quick question: This might sound stupid, but is there any way to get this to auto-refresh every few minutes or so?

lordofgun 03-13-2002 03:34 AM

NEVER MIND! I am a retard...found it in the "latest" template.

MrLister 03-13-2002 03:59 AM

lol is it just me or is everybody pposting multiple threads in a row. first sayan guy, then another one, then in this topic two more people

MrLister 03-13-2002 04:01 AM

just like this

MrLister 03-13-2002 04:01 AM

oh btw great hack

TECK 03-13-2002 06:17 AM

Quote:

Originally posted by nicksaunders
nakkid,
i think i might have a solution looking at your code.

i try to help as much as i can, even if my php knowledge is limited ;)
let us all know what's new with your hack.. btw, that solved your query problem?

N!ck 03-13-2002 11:40 AM

solved it...i used the getpermissions() thing to make sure each thread is viewable by the user - no private threads are shown except to admins and mods.

the only downside is that it may show a few less threads than set with private thread viewing for regular users off. you can change the settings, though, for the max number of latest threads to show and whether you want to restrict viewing of threads in private forums.

your post DID help me though !! :) i didn't even THINK of using the getpermissions() function. thanks

cditty 03-13-2002 11:47 AM

Is the attachment updated for this change? Also, any tips on adding online users to the page?

Chris

N!ck 03-13-2002 09:31 PM

chris,
the attachment is updated, yes...

now, as far as online users go, i hadn't considered this feature, but i will probably (unless i have difficulties ;) ) add the option to the special edition. check on it this weekend...i plan to write the special edition THEN ;)

school of course gets in the way, but spring break is next week ;)

cditty 03-13-2002 09:36 PM

Thanks man.

Chris

wooolF[RM] 03-13-2002 10:42 PM

]just installed :) looks very nice...

An option that could be implemented in to your new special edition - when user have seen all new messages or have marked them as read, on.gif should change to off.gif. How to do it?
[cough] Taskbar Ticker have this feature [/cough] ;)

and another thing... to take one line less from finish php page on your desktop use this
PHP Code:

<td><normalfont><b>&nbsp;&nbsp;$bbtitle&nbsp;&nbsp;&nbsp;Latest Topics</b></normalfont></td

instead of this
PHP Code:

<td><normalfont><b>$bbtitle<br>Latest Topics</b></normalfont></td

Gives a better look and as said takes one line away (more space to new threads ;) )

Here's mine "LATEST" template (modified a lil bit as many users have long nicknames and thus makes many new threads on two lines instead of one)
PHP Code:

<HTML>
<
HEAD>
$headinclude
<META HTTP-EQUIV=Refresh CONTENT="1800;latest.php">
<
META HTTP-EQUIV=Pragma CONTENT=no-cache>
<
TITLE>$bbtitleLatest Topics</TITLE>
</
HEAD>
<
body>
<
table border=0 cellpadding=0 cellspacing=1>
<
tr>
  <
td valign="top"><img src="{imagesfolder}/on.gif" width="15" height="15"></td>
  <
td><normalfont><b>&nbsp;&nbsp;$bbtitle&nbsp;&nbsp;&nbsp;Latest Topics</b></normalfont></td>
</
tr></table>
<
table border="0" width="450" cellpadding="2" cellspacing="1" bordercolor="{tablebordercolor}" bordercolordark="{tablebordercolor}">
<
tr>
  <
td bgcolor="{tableheadbgcolor}" align="center" width="290"><smallfont color="{tableheadtextcolor}"><b>Thread</b></smallfont></td>
  <
td bgcolor="{tableheadbgcolor}" align="center" width="100"><smallfont color="{tableheadtextcolor}"><nobr><b>Last Poster</b></nobr></smallfont></td>
  <
td bgcolor="{tableheadbgcolor}" align="center" width="30"><smallfont color="{tableheadtextcolor}"><b>Replies</b></smallfont></td>
  <
td bgcolor="{tableheadbgcolor}" align="center" width="30"><smallfont color="{tableheadtextcolor}"><b>Views</b></smallfont></td>
</
tr>
$latest
</table>
</
BODY>
</
HTML

:)

have a nice day/eve :)

wooolF[RM] 03-13-2002 10:44 PM

]weird... but all codes like this one { tableheadbgcolor } have changed to ones that vb.org uses... well... I think u've got the main idea ;) if not - pm me

N!ck 03-13-2002 11:11 PM

those must be your settings then ;)

again, the unread/read thing *may* appear in the special edition :) if i'm unable to do it myself, i can always look at the taskbar ticker code for inspiration.

anyhow....................................
glad y'all like it.

N!ck 03-14-2002 10:44 PM

[tease]the special edition is coming soon :D[/tease]


All times are GMT. The time now is 02: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.01244 seconds
  • Memory Usage 1,851KB
  • 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
  • (4)bbcode_php_printable
  • (1)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (1)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