Loading ...
Sorry, an error occurred while loading the content.

problems running php with apache

Expand Messages
  • nerdboy
    hi, i end up having problems running php scripts in apache web server like i tried executing this mike mew script but it doesnt work for me. i use red hat 8.0
    Message 1 of 1 , Feb 8, 2003
    • 0 Attachment
      hi,

      i end up having problems running php scripts in apache web server
      like i tried executing this mike mew script
      but it doesnt work for me.
      i use red hat 8.0 and put this file titled y.php and tried invoking it thru
      the browser by typing http://127.0.0.1/y.php
      where could i have gone wrong ?

      thanks in advance
      nerd
      ----------------------
      http://www.mikenew.net/yahoofetchIM.php
      ----------
      <?php
      /* Yahoo Fetch IM Status
      Copyright MikeNew.net */
      $userID = "nerdboy";
      $statusOn="<font size=\"1\">Currently online with Yahoo! IM.<br /><a
      href=\"ymsgr:sendIM?$userID\"><img
      src=\"http://us.i1.yimg.com/us.yimg.com/i/ppl/ltn.gif\" alt=\"Yahoo users,
      CLICK HERE to instant-message me.\" border=0 align=\"left\" /></a> <a
      href=\"ymsgr:sendIM?$userID\">Click here to chat.</a> <br /> <a
      href=\"http://www.mikenew.net/yahoofetchIM.php\"><br><img
      src=\"http://us.i1.yimg.com/us.yimg.com/i/mesg/themes/onlineskin.gif\"
      alt=\"Display your own Yahoo User-status from a webpage with a free script.\"
      width=\"15\" height=\"16\" border=\"0\" align=\"texttop\" /></a></p></font>";
      $statusOff="<font size=\"1\">Although I'm offline at the moment, you can
      click to send a Yahoo! message:<br /></font><a
      href=\"ymsgr:sendIM?$userID\"><img
      src=\"http://us.i1.yimg.com/us.yimg.com/i/ppl/ltn.gif\" alt=\"Yahoo users can
      leave an instant message.\" border=\"0\" /></a> <br><a
      href=\"http://www.mikenew.net/yahoofetchIM.php/\"><img
      src=\"http://us.i1.yimg.com/us.yimg.com/i/mesg/themes/offlineskin.gif\"
      alt=\"Display your own Yahoo User-status from a webpage with a free script.\"
      width=\"15\" height=\"16\" border=\"0\" align=\"absmiddle\" align=\"texttop\"
      /></a> </p>";
      $query = "http://opi.yahoo.com/online?u=";
      $page = fopen("$query"."$userID", "rb");
      $view = fread($page, 400);
      $view = ereg_replace($userID, "", $view);
      if ($answer = strstr ($view, "NOT")) {
      $output = "$statusOff";
      }
      elseif ($answer = strstr ($view, "ONLINE")) {
      $output = "$statusOn";
      }
      echo ("$output");
      flush (); //force
      fclose($page);
      ?>
    Your message has been successfully submitted and would be delivered to recipients shortly.