The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
Simple newsportal / thread overview to add to your board... Details »» | |||||||||||||||||||||||||||
Simple newsportal / thread overview to add to your board...
Developer Last Online: Nov 2023
Okay, this isn't really a hack, since you don't have to modify any vb-files really, but I figured this was the best place to make it public anyhow. I found it rather useful myself, so I figured others might, too.
Last update: April 28th, 2003! ** Update summary: ** The bug that could occur due to MySQL stupidity has been fixed. Version 2 of the Newsportal script is now attached in this post, you can simply overwrite the newsportal.php on your site with the one from the attached zipfile to upgrade. From now on, no more vB files need to be adjusted nor do you have to make any database changes. If you've already done all that due to the mysql-bug in a previous stage of this hack, you can just leave it like that, it won't do any harm. If you're intent on 'cleaning' your files again, let me know if you can't get it done yourself. Q&A: What does this 'hack' do? http://www.kurafire.com/newsportal.php That's a live example of the fully functional version of the Hack (version 2). I think it speaks for itself. The amount of newsposts & threads on the right is set in a variable at the beginning. Is this hack hard to install? Absolutely not. You upload the newsportal.php, you add the new templates (see zipfile), and you place a link to newsportal.php wherever you want it on your site. That's it. You don't have to modify any vB files, nor your database. Does this hack include my style and everything? Yes, the newsportal page will use your headinclude, header, footer and style-colors (pagebgcolor, tableouterwidth, linkcolor, etc.) and all these settings are easily configureable. You just edit the templates like you're (hopefully) used to with all the normal vB Templates. Version 2: The newsportal script now uses 2 queries to get the necessary information for your News posts. One for all thread info and the postid's of the starting posts, and one for the pagetext (ie. post contents) of all those postid's. You can use 2, 20 or 200 newsposts, that won't matter, it'll always be 2 queries (though I discourage using more than 20 newsposts ). ^_^ That's it, you're all done. Have fun with the newsportal! ^_^ Show Your Support
|
Comments |
#62
|
|||
|
|||
Great work KuraFire
I like to be able to pull info from my vB forum database onto my webpages, but I don't want to use a portal system. I write the website in HTML, and use PHP scripts for certain areas by having "include" statements in those HTML pages (named with .php extensions rather than .html). The portals I've looked at require you to write your webpages via vB templates, which I don't want to do. I've got your hack working on a non-vB webpage. Had to alter the templates to suit my needs (I use Tubedog's hack for the latest threads), and had to tinker a small amount with the newsportal.php script to make it work OK outside of the vB forums directory. No modifications to any of vB's own php file needed I'm trying to teach myself php, and a lot of what I learn is by looking at how other people have done things, and reading these forums a lot. If anyone's interested, and as long as KuraFire doesn't mind, I'll post the "modifications" to get it working on a non-vB page. I've had another idea of using your script to preview the latest book review on the website homepage too. The reviews are in their own forum, so could be pulled as for a news item. The only thing that concerns me is the "bug" that you mention. I haven't noticed it yet. Thanks. Darren. |
#63
|
|||
|
|||
Quote:
|
#64
|
||||
|
||||
Quote:
At any rate, nice hack |
#65
|
||||
|
||||
Okay, I have the bug fixed, people!
I will edit the first post later tonight or tomorrow, I don't have time right now but I can say this: it requires some database work; more importantly: if you don't want to wait X newsthreads before it'll work entirely, you will have to do some search-find-and-query work on the newsthreads you already have. But, I can safely say that once done, not a single random post will ever appear, anymore. Ever! |
#66
|
|||
|
|||
Sweet
|
#67
|
||||
|
||||
It's fixed! Check the first post:
https://vborg.vbsupport.ru/showthrea...547#post248547 to see how to patch your board to remove the random bug! :up: |
#68
|
|||
|
|||
The first version didn't require any MySQL modification right?
So I can just upload your new file and re-add the template. Then run the query? |
#69
|
||||
|
||||
Upload new file;
Template: wha? there's no template adjusting with the bug-fix... hack newthread.php; hack newreply.php; upload both files alter your database to set the existing threads' "isfirst" column to 'Y'; done. |
#70
|
||||
|
||||
I got it working outside the vb directory, that was easy. But how would I call it to my index.php page?
If you could include that feature it would be great! |
#71
|
||||
|
||||
Nevermind I was able to do it myself!
|
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|