Results 1 to 2 of 2

Thread: Find last line in a file

  1. #1
    Join Date
    Oct 2006
    Location
    UK - Wales
    Posts
    72

    Find last line in a file

    hi, i need to some data to a file before the end of it.

    im using xml and php to (at the moment) make a news posting thingy. anyway:

    the end of my file looks like this:

    Code:
    		</CONTENT>
    	</POST>
    	
    </ARCHIVE>
    </ARCHIVE> being the last line. i need to add the data between </POST> and </ARCHIVE> but i can't find the last line which i'm guessing is what i need to do to add data to the line before it.

    if anyone can post a script which can find the line i need or find the line and add some data i'd REALY appreciate it.

    thanks.

  2. #2
    Join Date
    Oct 2006
    Location
    UK - Wales
    Posts
    72
    ok forget it i got something now - forum guy you can delete this thread i dont need it anymore

Posting Permissions

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