Menu

PHP problem OR Apache 2.0 OR me being stupid?

Hilfe/Help
2003-01-21
2003-01-21
  • Johannes Boneschanscher

    I tried installing installing phpopenchat-2.3.0 but somehow i have done something wrong, as all the output of my apache server looks like: ->

    You don't read the INSTALL instructions!
    Use the PHPOpenChat-Installer to install and configure your chat. "; exit; } Error_Reporting(7); /* * Open a database connection * The following include returns a database handle */ include ("connect_db_inc.php"); $db_handle=connect_db($DATABASEHOST,$DATABASEUSER,$DATABASEPASSWD); if($db_handle<1){ exit; } include ("channels_inc.php"); if($HTTP_POST_VARS["nick"]){ if($ENABLE_SESSION){ @session_destroy(); } include("write_line_inc.php"); include ("login_inc.php"); $return = user_login($HTTP_POST_VARS["nick"],$HTTP_POST_VARS["password"],"",$HTTP_POST_VARS["entry"],$db_handle); if($return == TRUE){ if($ENABLE_SESSION){ $nick = $HTTP_POST_VARS["nick"]; $pruef=Crypt($nick,$salt_nick); $entry=$HTTP_POST_VARS["entry"]; $ii=0; session_register('pruef','nick','entry','vip','moderator','is_vip','is_como','is_moderator_for','ii','lastRow','BROWSER_NAME','salt_nick'); // create "join"-message $hellothere = ' '; $result=mysql_query("SELECT count(*) AS count FROM chat_data WHERE Online>=$onlinetime",$db_handle); $a=@mysql_fetch_array($result); if($a[count]>0){ //$join = "* ".$JOINING_IN." und sitzt auf dem ".mysql_result($result,0,"count").". Platz des Stammtisches *"; $join = "* $JOINING_IN *"; }else{ $join = "* $JOINING_IN *"; } schreib_zeile($hellothere.$join.'<\/font><\/i>',$entry); header('Status: 301'); header("Location: frame_set.".$FILE_EXTENSION."?".session_name()."=".session_id()); exit; }else{ $nick = $HTTP_POST_VARS["nick"]; $pruef=Crypt($nick,$salt_nick); $entry=$HTTP_POST_VARS["entry"]; header('Status: 301'); header("Location: frame_set.".$FILE_EXTENSION."?nick=".urlencode($nick)."&pruef=".urlencode($pruef)."&entry=".urlencode($entry)); exit; } } } $REMOTE_USER=strip_tags($PHPOPENCHAT_USER);//cookie if($PHPOPENCHAT_USER){ $date = date("H"); if ($date >= 5) { $gruss = $GREETINGS[1]; } if ($date >= 12) { $gruss = $GREETINGS[2]; } if ($date >= 14) { $gruss = $GREETINGS[3]; } if ($date >= 18) { $gruss = $GREETINGS[4]; } if ($date >= 22) { $gruss = $GREETINGS[5]; } switch (randomint(3)) { case 0: $hello_message = $COME_IN; break; case 1: $hello_message = $TELL_US; break; case 2: $hello_message = $WHATS_UP; break; default: $hello_message = $CHAT_WITH_US; } }else{ $entrylink = "
    $I_WANT_TO_CHAT!
    "; } $num_reg_chatters = mysql_result(mysql_query("SELECT count(Nick) AS count FROM chat_data",$db_handle),0,"count"); //count of chatters in the last 24 hours $num_last24h_chatters = mysql_result(mysql_query("SELECT count(Nick) AS count FROM chat_data WHERE Zeit>(UNIX_TIMESTAMP()-(60*60*24))",$db_handle),0,"count  |etc. etc. etc.

    And I don't like that :-) Because I did read the installation instructions!

    As I know nothing about php I just tried to test the php functionallity by making a test.php with this:

    <?
    phpinfo()
    ?>

    which did not work so after some tips it was changed into:

    <?php
    phpinfo()
    ?>

    And it produced a beautifull HTML site a supposed :-)

    But why doesn't than my phpopenchat work.

    I use Apache 2.0.40 and PHP 4.2.2 as being the default with RedHat 8.0 and I'm little stuck

    Anyone?

    Kind regards,

    Johannes Boneschanscher
    (Fuer die lause unter die Germans -> braucht nix zu uebersetzen - NL is ook welkom)

     
    • Johannes Boneschanscher

      OK it was me (being stupid, I mean)

      Please tell users to edit there /etc/php.ini cause for me with RedHat 8.0 etc. etc. (see above) the TAG <? and ?> where ignored because of the short_open_tag = Off settings :-(

      I hope this can help someone else being as stupid as I WAS

      Greetz,

      Johannes Boneschanscher

       

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.