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)
-   -   vBindex (https://vborg.vbsupport.ru/showthread.php?t=37021)

indiamike 04-19-2002 08:54 AM

Quote:

Originally posted by NTLDR
What is on, or around line 371 in newindex.php? And did you copy the code from an unhacked origional vBulletin index.php that is the same version as you use on your board?
Hmmm...I will check this over the weekend. Since I used a version that is on my forum, but the index is slightly hacked up. I will check there first and compare an old and new version and see if there is anything different.

Mike

indiamike 04-19-2002 09:00 AM

Quote:

Originally posted by hkim
This is probably totally newbie kind of question, but:

After installing vBindex 1.3 as instructed, I find myself with the fact that news and polls are not showing. I have created a forum calles newsforum and a forum called pollforum with normal permissions. Although the threads are viewing all right, I cannot view news or polls.

Any help will be appreciated.

Best regards,


Though I haven't sucessfully installed this hack yet, I would probably check the index.php that you uploaded from this hack. Did you change the variables in the first few lines to match up with the forum id numbers?

Quote:

// news forum
$newsforum=3;

// polls forum
$pollsforum=4;
These two numbers are generic numbers and should be changed to the value of that forum id.
I would check that first.

Mike

hkim 04-19-2002 09:31 AM

Aha...Thanks, Mike! I think that should do the trick!

Best regards,
H.Kim

indiamike 04-19-2002 10:03 AM

Quote:

Originally posted by NTLDR
What is on, or around line 371 in newindex.php? And did you copy the code from an unhacked origional vBulletin index.php that is the same version as you use on your board?

Aha....I figured it out finally. My cookies were messing with it because I used differant styles and didn't add all the new templates to the style that I was using. I just added them to the default template, not the templates for the style that I had chosen to view my board in.

Okay.....works now....time to hack it up and add my own stuff.

Mike

hkim 04-19-2002 11:56 AM

Dear NTLDR/Lee,

Thanks for the info. With risk of sounding somewhat lame, could you please give me some more specific information on how to implement this? E.g.

1. Do I have to rename the index.php to vbindex.php?
2. The new pages, do I create them within the vbulletin control panel?
3. How can a new template page look like? What do I have to include? Specific example would be great.

Best regards,


Quote:

Originally posted by NTLDR


This is why I've chosen not to use a portal system, because it looks the same as everyone elses site and is mean't for a lot of things I don't need or want to do, this way I can fully integrate with my forums and have a common design thoughout my site.

Here is the code you need to find and change for a muli-paged vBindex:

In the vbindex php file change (its right at the end):

PHP Code:

eval("dooutput(\"".gettemplate('home')."\");"); 

To:
PHP Code:

if (!$page)
// no page specified
{
eval(
"dooutput(\"".gettemplate('home')."\");");
}
else
eval(
"dooutput(\"".gettemplate("$page")."\");");
//eval("dooutput(\"".gettemplate('home')."\");"); 

to get the homepage use http://mysiteurl/forumsdir/vbindex.php to get any other page use http://mysiteurl/forumsdir/vbindex.p...=template_name

Where:

vbindex.php is what you have called the index.php file included with vBindex

and

template_name is the name of the template that contains the page.

Let me know if you have any problems,

Regards,
Lee (NTLDR)


hkim 04-19-2002 12:09 PM

Well, it was a stupid request when you gave so clear information at the first place. I found it out by myself after a few minutes.

Thanks anyway! :p

NTLDR 04-19-2002 01:44 PM

Quote:

Originally posted by hkim
Well, it was a stupid request when you gave so clear information at the first place. I found it out by myself after a few minutes.

Thanks anyway! :p

lol!

No problem hkim, if you run into problems let me know, I wouldn't say your question was lame, everyone has different abilities here and I'm quite happy to help anyone who has any problems with anything I've produced.

I hope everything works fine when you impliment the changes.

Juanito 04-19-2002 02:56 PM

Nice work here, this is what I was looking for and it work really great! I'Ve first setup vbhome light but this one fits my needs a lot more as I'm not a programmer and vbhome is almost impossible for me to custumize the way I want.

Got 2 more things I need to ask:

1- Is there a way to use the usergroups permissions of the forum for the threads display?

2- Is is complicated to add a block with the latest 5 thread titles of a specific forum ? (with links to the thread)

Hope those 2 requests will not be too complicated to do...

Thanks a lot!

el3m3nt 04-19-2002 05:25 PM

1- you mean the threads display of the latest threads? in v1.3 of vbindex you can only see these threads on the index-site which you have permission to see.


2- nope, no problem :). add anywhere in the index-file (but before the output of the home-template)!

PHP Code:

$forumid='forumid of the specific forum';
$limit=5;
$query $DB_site->query("SELECT threadid,title FROM thread WHERE visible=1 AND forumid='$forumid' order by lastpost desc limit $limit");

while (
$last5array $DB_site->fetch_array($query)) {
  
$threadid=$last5array[threadid];
  
$threadtitle=$last5array[title];

  
$last5.='<a href=\"showthread.php?s=$session[sessionhash]&threadid=$threadid\">$threadtitle</a><br>';


now just add the variable $last5 anywhere in the right or left-template.

Juanito 04-19-2002 05:52 PM

Thanks a lot, I think something must be messed up then because threads of private forums are seen by everyone in the latest threads column. Not the threads themselves but the titles and it can reveal some sensitive content so...

Where should I look to try finxing this out?

BTW thanks a lot for your fast response, very kind from you ;)

For the code above, I've tried it without success. I forget something maybe?

Code:

$forumid=6;
$limit=5;
$query = $DB_site->query("SELECT threadid,title FROM thread WHERE visible=1 AND forumid='$forumid' order by lastpost desc limit $limit");

while ($last5array = $DB_site->fetch_array($query)) {
  $threadid=$last5array[threadid];
  $threadtitle=$last5array[title];

  $last5.='<a href=\"showthread.php?s=$session[sessionhash]&threadid=$threadid\">$threadtitle</a><br>';
}

I put this in my index file right bellow the variables settings then I've put $last5. I have the link displayed as it it in the code, showing me this: $threadtitle with the code in the link! ("showthread.php?s=$session[sessionhash]&threadid=$threadid\")

Grrr, I'm not a coder sorry! lol


All times are GMT. The time now is 09:28 PM.

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.02420 seconds
  • Memory Usage 1,761KB
  • 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
  • (1)bbcode_code_printable
  • (3)bbcode_php_printable
  • (6)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (2)pagenav_pagelinkrel
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)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