The vB Geek

Go Back   The vB Geek > vB Geek Modifications > Add-ons

Add-ons Modifications and add-ons for vB Geek stuff.

Advertisement
  Learn how to remove ads

Comment
 
Release Tools Display Modes
 
Old 09-13-2006, 09:00 AM
The Geek's Avatar
The Geek The Geek is offline
Senior Member
 
Join Date: Aug 2005
Posts: 6,717
Geek Article and Review System License Holder GeekMart License Holder Geek Auto-Linker Pro License Holder Geek Advertising Banner License Holder Geek Gazette License Holder 
Default Member Info Top X

This was whipped together for Trana who has been asking for a few weeks for it.
...

Last edited by The Geek; 01-23-2007 at 02:24 PM..
Reply With Quote
  #20  
By trana on 09-26-2006, 06:58 PM
Default

Quote:
Originally Posted by The Geek
Any forums you want to pull from need to be in the list. It doesnt do any searching of child forums or anything.
No, what I meant was that it appears that a subforum that was listed in the admincp options would not be searched unless the parent is also listed. Does that sound possible?

It is working now, so thank you again.
Reply With Quote
  #21  
By The Geek on 09-27-2006, 09:43 PM
Default

Shouldnt be the case. Couldnt for the life of me figure out why that would be... anyway... as long as its sorted for now
Reply With Quote
  #22  
By trana on 10-05-2006, 04:16 AM
Default

Can you help me get the code straightened out for displaying the header image next to the title?

I see you have this:

Code:
$results = $db->query_read("SELECT t.title, t.views, t.replycount, t.threadid FROM " . TABLE_PREFIX . "thread t WHERE t.visible=1 " . ($forumid ? " AND t.forumid in (-1$forumid) " : "") . "AND t.postuserid = $userinfo[userid] $orderby LIMIT " . (intval($limit) ? $limit : "5"));


        $bits = "";
        while ($result = $db->fetch_array($results))
        {
            $bits .= "<div class=\"smallfont\">
			    <a href='showthread.php?t=$result[threadid]' title='$result[title]'>$result[title]</a></div>";
	}
        if ($bits)
        {
            eval('$GARS_addon_member_top .="' . fetch_template('GARS_addon_member_top') . '";');
        }
Do I need to do a separate SELECT to load the header images from the gars table or can it all be included on the one $results?

Thanks.
Reply With Quote
  #23  
By The Geek on 10-05-2006, 06:46 AM
Default

No, however your query should be more like this one:

PHP Code:
$results $db->query_read("SELECT g.header_image, t.title, t.views, t.replycount, t.threadid FROM " TABLE_PREFIX "thread t INNER JOIN " TABLE_PREFIX "gars g ON t.threadid = g.threadid WHERE t.visible=1 " . ($forumid " AND t.forumid in (-1$forumid) " "") . "AND t.postuserid = $userinfo[userid] $orderby LIMIT " . (intval($limit) ? $limit "5")); 
Havent tested it, but it should be fine.
Reply With Quote
  #24  
By trana on 10-05-2006, 10:13 PM
Default

Quote:
Originally Posted by The Geek
No, however your query should be more like this one:

PHP Code:
$results $db->query_read("SELECT g.header_image, t.title, t.views, t.replycount, t.threadid FROM " TABLE_PREFIX "thread t INNER JOIN " TABLE_PREFIX "gars g ON t.threadid = g.threadid WHERE t.visible=1 " . ($forumid " AND t.forumid in (-1$forumid) " "") . "AND t.postuserid = $userinfo[userid] $orderby LIMIT " . (intval($limit) ? $limit "5")); 
Havent tested it, but it should be fine.
But then I need to point to the proper forum right?

Like here?

Code:
<img alt=\"\" src='forum/" . ($info[$result['threadid']]['header'] == "" ? $this->settings['url_to_header_images'] . '/' . $this->type['default_image'] : $info[$result['threadid']]['header']) . "' style='border: 0px #000000;padding:0px;' />
Reply With Quote
  #25  
By The Geek on 10-06-2006, 06:23 AM
Default

How are you trying to make it look?
Reply With Quote
  #26  
By trana on 10-06-2006, 07:28 PM
Default

I just want to show the header image in a row next to the title. I can work out the formatting of the $bits to get it to look like the rest of my page, but I can't seem to merge how you derived the location of the header files. It would be easy if I could just call it like I can do with $avatar.
Last edited by trana; 10-06-2006 at 07:30 PM..
Reply With Quote
  #27  
By The Geek on 10-07-2006, 10:57 PM
Default

oh... hold on... you're not after the forum name, but after the header image? The header image is called header_image not header. Try that.
Reply With Quote
  #28  
By trana on 10-08-2006, 01:49 AM
Default

Quote:
Originally Posted by The Geek
oh... hold on... you're not after the forum name, but after the header image? The header image is called header_image not header. Try that.
Right, but the header images are based on your own directory structure right? So I need to put in the directory name as well? I'm using the CMPS GARS block as an example of how to call the header image and it has a whole bunch of stuff with the admin settings and $this (???) which are required to point to the actual header image. Is there another way?

Thanks Geek!
Reply With Quote
  #29  
By The Geek on 10-08-2006, 10:12 AM
Default

Hang fire and Ill retweak this to include the option to display a header image
Reply With Quote
Comment

Release Tools
Display Modes

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

Forum Jump

Similar Threads
Release Release Starter Category Comments Last Post
new user need info jskoh Geek Article and Review System 1 10-13-2009 06:58 PM
Info Block abrecher Geek Gazette 1 06-06-2009 08:41 AM
Please Info AES Geek Article and Review System 3 06-09-2006 02:15 PM
Featured/Latest/Top Active/Top Read Tutorials showing wrong thing Azhria Lilu Geek Article and Review System 5 05-22-2006 08:28 PM
How do I show top X by ratings (top.php) fyjpm Geek Article and Review System 1 03-22-2006 05:51 PM


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


Powered by vBulletin® Version 3.8.5
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.

Release powered by GARS 2.1.9 ©2005-2006