Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 3.0 > vBulletin 3.0 Full Releases
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
Additional external.php feed format Details »»
Additional external.php feed format
Version: 1.00, by okrogius okrogius is offline
Developer Last Online: Dec 2005 Show Printable Version Email this Page

Version: 3.0.0 Rating:
Released: 01-02-2004 Last Update: Never Installs: 10
 
No support by the author.

Those of you who integrate your feed in a PHP page will appreciate the simplicity of working with this .

Once installed you can just include your therads on your site's pages (example) via simply reading contents of external.php?type=php (be it via fopen, etc), and then processing the results through an unserialize() call.

Show Your Support

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

Comments
  #12  
Old 02-09-2004, 04:40 AM
Myr7h Myr7h is offline
 
Join Date: Jan 2004
Posts: 1
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by okrogius
sure, using this getitng yoru threads can be as simple as:

PHP Code:
<?php

$threads 
unserialize(file_get_contents('http://www.example.com/external.php?type=php'));

for (
$i=0; $<count($threads); $i++) {
 echo 
'thread: '.$threads[$i]['title'].'<br />';
}

?>
its not as simple as that other wise i wouldn't get this error message:
Parse error: parse error, unexpected '<', expecting T_VARIABLE or '$' in G:\wampp2\htdocs\mnracing\index.php on line 230
Reply With Quote
  #13  
Old 03-03-2004, 10:42 PM
Mr. Brian's Avatar
Mr. Brian Mr. Brian is offline
 
Join Date: Jan 2003
Location: Internet
Posts: 300
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Did you change the URL to your's instead??

Quote:
Originally Posted by Myr7h
its not as simple as that other wise i wouldn't get this error message:
Parse error: parse error, unexpected '<', expecting T_VARIABLE or '$' in G:\wampp2\htdocs\mnracing\index.php on line 230
Reply With Quote
  #14  
Old 03-04-2004, 10:31 PM
Geographic2 Geographic2 is offline
 
Join Date: Apr 2003
Location: On the map
Posts: 81
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Same error here:

on this line:

for ($i=0; $<count($threads); $i++) {


Are you sure that is right?

ok now I see it needs to be

for ($i=0; $i<count($threads); $i++) {


I see the application of this, very nice. Quick way to flip things across. Damn I love this external.php
Reply With Quote
  #15  
Old 11-30-2004, 08:58 PM
andor andor is offline
 
Join Date: May 2004
Posts: 16
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hey, this is a great simple mod - love it. Thanks!
Reply With Quote
  #16  
Old 11-30-2004, 11:12 PM
Mosh's Avatar
Mosh Mosh is offline
 
Join Date: Aug 2004
Location: Melbourne, Australia
Posts: 1,968
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

To get this Mod to work with KW802's replacement for external.php in this thread "FPS_EXTERNAL.PHP -- New options added & RSS compliant version of external.php" - https://vborg.vbsupport.ru/showthread.php?t=69834, use the following instructions instead of the ones attached here:

Open fps_external.php (or whatever you renamed it to).

Find:
PHP Code:
case 'JS':
     break;
case 
'XML':
     break;
case 
'RSS1':
     break;
case 
'RSS2':
     break; 
Under it add:
PHP Code:
case 'PHP':
     break; 
Find:
PHP Code:
// +=============================================================+
// | Build the RSS feeds                                         |
// +=============================================================+
else if (($_REQUEST['type'] == 'RSS' OR $_REQUEST['type'] == 'RSS1' OR $_REQUEST['type'] == 'RSS2') AND $vboptions['externalrss']) 
Above it add:
PHP Code:
else if ($_REQUEST['type'] == 'PHP')
// PHP output
    
echo serialize($threadcache);

Hope this helps,

jd
Reply With Quote
  #17  
Old 12-03-2004, 07:55 PM
KW802's Avatar
KW802 KW802 is offline
 
Join Date: Jul 2003
Location: A galaxy far, far away...
Posts: 1,450
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

If there are no objections I'll incorporate that into the next round of changes I'm working on.
Reply With Quote
  #18  
Old 12-05-2004, 09:46 PM
Natch's Avatar
Natch Natch is offline
 
Join Date: Nov 2002
Location: Australia
Posts: 851
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Good idea Kev
Reply With Quote
  #19  
Old 03-28-2005, 02:33 AM
Mosh's Avatar
Mosh Mosh is offline
 
Join Date: Aug 2004
Location: Melbourne, Australia
Posts: 1,968
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by jdsinclair
To get this Mod to work with KW802's replacement for external.php in this thread "FPS_EXTERNAL.PHP -- New options added & RSS compliant version of external.php" - https://vborg.vbsupport.ru/showthread.php?t=69834, use the following instructions instead of the ones attached here:

Open fps_external.php (or whatever you renamed it to).

Find:
PHP Code:
case 'JS':
     break;
case 
'XML':
     break;
case 
'RSS1':
     break;
case 
'RSS2':
     break; 
Under it add:
PHP Code:
case 'PHP':
     break; 
Find:
PHP Code:
// +=============================================================+
// | Build the RSS feeds                                         |
// +=============================================================+
else if (($_REQUEST['type'] == 'RSS' OR $_REQUEST['type'] == 'RSS1' OR $_REQUEST['type'] == 'RSS2') AND $vboptions['externalrss']) 
Above it add:
PHP Code:
else if ($_REQUEST['type'] == 'PHP')
// PHP output
    
echo serialize($threadcache);

Hope this helps,

jd
Quote:
Originally Posted by KW802
If there are no objections I'll incorporate that into the next round of changes I'm working on.
Sorry it took so long to respond, I have only just rechecked this thread. I have no probs you using my instructions, it was just to get okrogius's code to work with your version instead of the original external.php.

The only problem I see with okrogius's code is that there is no mechanism to turn off the php feed in the ACP (whereas you can switch off the others), that needs to be factored in when adding the php feed if okrogius gives permission to use his code.

jd
Reply With Quote
Reply


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 09:26 PM.


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.07672 seconds
  • Memory Usage 2,307KB
  • Queries Executed 23 (?)
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
  • (9)bbcode_php
  • (4)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
  • (1)pagenav_pagelink
  • (9)post_thanks_box
  • (9)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (9)post_thanks_postbit_info
  • (8)postbit
  • (9)postbit_onlinestatus
  • (9)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