#!/usr/bin/perl -w # yChat - Copyright by Paul C. Bütow use CGI; CGI->compile(':all'); $q = new CGI; print $q->header; require config; $alias = $q->param("alias"); $tmpid = $q->param("tmpid"); &secure_checkid($alias); ######################################## ##ANFANG DER ZU STREAMENDEN HTML-DATEI## ######################################## print < END ############################# ##BEGRÜSSUNGSTEXT SCHREIBEN## ############################# my $msgfile; print $q->font( { -size=>1, -color=>"ffffff", -face=>"arial"}, "$title - Created & Copyright by Paul C. Bütow $tmp\n"); if (-f "data/user/memos/$alias") { print "\n
"; open(MEMOS,"; close MEMOS; print $memos; unlink("data/user/memos/$alias"); } my $msgfile = "data/msgs/$alias"; open(MSG,">$msgfile"); print MSG $q->br; close MSG; print $q->br; ############################### ##ENDLOSSCHLEIFE FÜR DEN PUSH## ############################### my ($times,$online) = (0,"false"); open(MSGFILE,$msgfile); for (;;) { for ($curpos = tell(MSGFILE); ; $curpos = tell(MSGFILE)) { print $_ ; } $times++; if ($times > 14) { print "\n"; $times = 0; $online = "true" if (-e "data/online/users/$alias"); if ($online eq "false") { print "Aus technischen Gründen bitte auf Weiterchatten klicken."; exit; } $online = "false" } sleep 1; seek(MSGFILE, $curpos, 0); # Position wiederherstellen }