Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 2.x > vBulletin 2.x Full Releases

Reply
 
Thread Tools
RDF-Feed from your Forums Details »»
RDF-Feed from your Forums
Version: 1.00, by Dontom Dontom is offline
Developer Last Online: Nov 2013 Show Printable Version Email this Page

Version: 2.2.x Rating:
Released: 01-26-2003 Last Update: Never Installs: 7
 
No support by the author.

Just change db-details and drop this file into your forums directory - it will output a RDF-file with the last x posts on your forums...

As '&' in URLs is not allowed in RDF put this rewrite rule into the directory you put this script.

RewriteEngine on
RewriteRule ^tl([0-9]+)\.html$ showthread.php?s=&goto=lastpost&threadid=$1[L]

it will send the user to the lastpost of the thread.

Demo:
you need a rdf- parser to view it . Knews under KDE or Netscape > 6, PHP-Nuke, Post-Nuke...
http://www.mtb-news.de/forum/rdf.php

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.

Comments
  #12  
Old 01-28-2003, 04:58 AM
Minots's Avatar
Minots Minots is offline
 
Join Date: Jan 2002
Location: Germany
Posts: 59
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

@ Dontom
Ich finde es klasse, dass Du Dir auch die M?he gemacht hast,
etwas derartiges zu coden. Darum sehe mein Posting bitte
nicht als Konkurenz-Angebot, sondern vielmehr als
eine weitere m?gliche L?sung, die Dir frei zur Verf?gung steht.

Liebe Gr??e,
Reply With Quote
  #13  
Old 01-28-2003, 08:25 AM
djr's Avatar
djr djr is offline
 
Join Date: Nov 2001
Location: Amsterdam
Posts: 220
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

It probably adds another query, but how can I also add the forum title to it? Do I also need an extra LEFT JOIN on forum USING(forumid)? Can someone point me in the right direction?

Thanks!
- djr
Reply With Quote
  #14  
Old 01-28-2003, 08:44 AM
pogo's Avatar
pogo pogo is offline
 
Join Date: Oct 2001
Posts: 74
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally posted by djr
It probably adds another query, but how can I also add the forum title to it? Do I also need an extra LEFT JOIN on forum USING(forumid)? Can someone point me in the right direction?

Thanks!
- djr
It is already in there!

PHP Code:
...votetotalforum.title AS forumname FROM thread... 
You can use it as $rows[forumname].
Reply With Quote
  #15  
Old 01-28-2003, 08:52 AM
djr's Avatar
djr djr is offline
 
Join Date: Nov 2001
Location: Amsterdam
Posts: 220
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Sorry, wasn't clear I use your version, because it's easier to work with. But you use a LEFT JOIN on forumpermission instead of forum.

- djr
Reply With Quote
  #16  
Old 01-28-2003, 09:41 AM
pogo's Avatar
pogo pogo is offline
 
Join Date: Oct 2001
Posts: 74
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Then you should have asked in the other thread.

PHP Code:
$threads=$DB_site->query("SELECT threadid,thread.title AS title,thread.lastpost,thread.replycount,postusername,thread.forumid,forum.title AS forumtitle
                          FROM thread
                          LEFT JOIN forumpermission USING(forumid)
                          LEFT JOIN forum ON forum.forumid = thread.forumid
                          WHERE forumpermission.forumid IS NULL
                          ORDER BY lastpost DESC LIMIT "
.$showthreadnumber); 
Reply With Quote
  #17  
Old 01-28-2003, 10:07 AM
djr's Avatar
djr djr is offline
 
Join Date: Nov 2001
Location: Amsterdam
Posts: 220
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

You should also release yours as hack. Nothing against Dontom's one, but I feel a 'lil insecure when I have to include my db-details in a seperate php-file. I'd rather use a version which uses global.php.

Again, sorry for posting in the wrong thread and muchos thanks for the update query. Works like a charm!

- djr
Reply With Quote
  #18  
Old 01-28-2003, 05:29 PM
Sketch Sketch is offline
 
Join Date: Apr 2002
Location: Baltimore, Maryland
Posts: 135
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally posted by Areku
Excuse me, but what's a RDF file?


http://www.google.com/search?hl=en&i...%22RDF+file%22
Reply With Quote
  #19  
Old 02-01-2003, 07:39 PM
roxics's Avatar
roxics roxics is offline
 
Join Date: Jan 2002
Location: Detroit Area
Posts: 177
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Three questions.

1. How does RDF differ from RSS? I'm foggy on these XML filetypes. Or are they pretty much the same thing.

2. Is there a way to get it to just take news from one forum rather then all of them?

3. Why does this hack seem so much simpler then the vbsyndicate hack available?

Here's what I'm looking to do. I have my forums located at one URL and my main site at another. I want to get news from one forum onto the main page of my site. I figured RSS/RDF might be the best (only) way. It would also be a bonus if others could get that news on their site.

If I understand this hack correctly that is what this does right?
Reply With Quote
  #20  
Old 02-01-2003, 08:06 PM
Dontom Dontom is offline
 
Join Date: Oct 2001
Location: Germany
Posts: 115
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally posted by roxics
Three questions.

1. How does RDF differ from RSS? I'm foggy on these XML filetypes. Or are they pretty much the same thing.
### ahem - no idea very foggy here, too

2. Is there a way to get it to just take news from one forum rather then all of them?
### sure, just change the select -statement to below and change 999 to the forum you want to use

SELECT thread.title AS threadtitle, threadid, dateline, postusername, postuserid, thread.replycount, thread.lastposter, views, thread.forumid AS threadforumid, thread.lastpost AS lastpost, votenum, votetotal, forum.title AS forumname FROM thread LEFT JOIN forum ON forum.forumid = thread.forumid WHERE thread.visible = 1 AND thread.open AND forum.forumid = 999 ORDER BY LASTPOST DESC LIMIT 15


3. Why does this hack seem so much simpler then the vbsyndicate hack available?

### vbsyndicate generates afaik a javascript output, which is written periodically to you server

Here's what I'm looking to do. I have my forums located at one URL and my main site at another. I want to get news from one forum onto the main page of my site. I figured RSS/RDF might be the best (only) way. It would also be a bonus if others could get that news on their site.

### this hack should do this perfectly

If I understand this hack correctly that is what this does right?
Reply With Quote
  #21  
Old 02-01-2003, 11:31 PM
roxics's Avatar
roxics roxics is offline
 
Join Date: Jan 2002
Location: Detroit Area
Posts: 177
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Ok the feed works. My only problem is that if you look at the feed on another site it shows up. But when you click on the headline it takes you to a 404 error on my site.

Here is the feed on another site (ve news up top)

Here is my board

The forum it's drawing from is called Announcements & Classifieds
Reply With Quote
Reply

Thread Tools

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


All times are GMT. The time now is 05:40 AM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.05069 seconds
  • Memory Usage 2,307KB
  • Queries Executed 25 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (2)bbcode_php
  • (3)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (6)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (3)pagenav_pagelink
  • (11)post_thanks_box
  • (11)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (11)post_thanks_postbit_info
  • (10)postbit
  • (11)postbit_onlinestatus
  • (11)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.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/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.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
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete