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

file_get_contents PROBLEM please HELP

Expand Messages
  • thisistrinath
    My code: $content=file_get_contents( http://infolab.stanford.edu/pub/papers/google.pdf ); echo $content; the above code works perfectly well but when I try the
    Message 1 of 1 , Apr 6, 2007
    • 0 Attachment
      My code:
      $content=file_get_contents("http://infolab.stanford.edu/pub/papers/google.pdf");
      echo $content;
      the above code works perfectly well but when I try the similar
      following code it doesn't work at all.
      $_nick=file_get_contents("http://google.com"); line 1
      echo $_nick; line 2
      it shows the following error
      Parse error: parse error, unexpected T_VARIABLE, expecting ',' or ';'
      in C:\Program Files\Abyss Web Server\htdocs\file1.php on Line 1

      I am completely unable to find the problem. Please tell me where the
      problem lies.
      Thank you
    Your message has been successfully submitted and would be delivered to recipients shortly.