Results 1 to 2 of 2
  1. #1
    Join Date
    Jan 2004
    Location
    India
    Posts
    168

    Unanswered: File contents to a script

    Hi All
    I am trying to store the contents of a file to a string through file_get_contents(). But i am getting a error saying
    file_get_contents() expects parameter 1 to be string, resource given in /varr/www/html/test/testget.php on line 16

    I want to get the contents of the file and the replace cretain lie with a new line and the copy it to the file. So I am trying to get the contents from the file and the perform a string replace function and then write to it.

    If this is not a better method please suggest me a good one. Else if any one have a solution please help me out

    Thankx
    Any help will be appriciated

    Regards
    Rajesh

  2. #2
    Join Date
    Jan 2004
    Location
    India
    Posts
    168
    I have tried this with arrays but i am not able to replace a perticular value or line in this. Can any one help me to this.

    Thankx
    Regards
    Rajesh

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •