View Single Post
  #5  
Old 01-07-2004, 09:04 PM
jancarlo jancarlo is offline
 
Join Date: Feb 2003
Location: Italia
Posts: 97
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

excuse is mistaken to me.

I have put in phpinclude_start the script:

//Whois on line in irc code - remote http, no db access beta 2.0.0

//check the url exists to save crashing or end of the world

//main routine

$onlinefile = "http://www.pennyshell.net/~playanueva/chat.txt"; //path to online users file

$killname = array("PlayaBoT", "PlayaBoT_"); //kill name array to hide users online - all users name with 'bot' and '_' at the end wont display

$httpfaulttime = 5; //number of seconds before vB decides the bots web server has died

function urlExists($url)

{

$url = ereg_replace("http://", "", $url);

list($domain, $file) = explode("/", $url, 2);

// change the last number below to the timeout you prefer for contacting the server

$fid=fsockopen($domain,80, $errno1, $errstr1,$httpfaulttime);

@fputs($fid,"GET /$file HTTP/1.0\r\nHost: $domain\r\n\r\n");

@$gets = fgets($fid, 1024);

@fclose($fid);

if (ereg("HTTP/1.1 200 OK", $gets)) return TRUE;

else return FALSE;

}

//main routine

if (!urlExists($onlinefile)) {

$chatterson ="IRC Server Fault.\n";

$onlineirc="0";

}

else {

$file = fopen($onlinefile, "r");

while (!feof($file)) {

$buffer .= fgets($file, 4096);

}

fclose($file);

$buffer = strip_tags ($buffer); //get rid of any php or html tags etc

$buffer = chop($buffer); //get rid of the white space

$chatterson ="";

/// routine for placeing the user details into an array and getting online numbers

$temparray = explode ("%20", $buffer);

$temparraysize = sizeof ($temparray);

$k = 0;

for ($i = 0; $i < $temparraysize; $i+=3) {

$bufferarray[handle1][$k] = ($temparray[$i]);

$bufferarray[host][$k] = ($temparray[$i+1]);

$bufferarray[nick][$k] = ($temparray[$i+2]);

$k+=1;

}

$bufferarraysize = (sizeof ($temparray)/3);

$onlineirc = ($bufferarraysize);

$buffercount=0;

//setting the user modes according to the flags set in the nick

for ($buffercount=0; $buffercount < $bufferarraysize; $buffercount++) {

$tempbuff=$bufferarray[nick][$buffercount];

foreach ($killname as $kilvalue) {

if (eregi($kilvalue, $tempbuff)) {

$onlineirc=$onlineirc-1;

$bufferarray[nick][$buffercount] = "";

continue ;

} } }

unset($chatterson);

for ($i = 0; $i < $bufferarraysize; $i++) {

if (!$bufferarray[nick][$i] == "") {

if (!$chatterson == "") {

$chatterson = $chatterson.", ".$bufferarray[nick][$i];

}

else { $chatterson = $bufferarray[nick][$i]; }

}}

}

but nothing to make in the window does not appear the user of
the chat.txt

thanks
jancarlo

Italian

scusa mi sono sbagliato.

ho messo in phpinclude_start lo script:

*****************************

ma niente da fare nella finestra non compaiono gli user del chat.txt

grazie
jancarlo
Reply With Quote
 
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.02018 seconds
  • Memory Usage 1,765KB
  • Queries Executed 11 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD_SHOWPOST
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_box
  • (1)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (1)post_thanks_postbit_info
  • (1)postbit
  • (1)postbit_onlinestatus
  • (1)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • reputationlevel
  • showthread
Included Files:
  • ./showpost.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_postinfo_query
  • fetch_postinfo
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showpost_start
  • bbcode_fetch_tags
  • bbcode_create
  • postbit_factory
  • showpost_post
  • 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
  • showpost_complete