I am trying to edit this xml-file:
I want to change one of the li-nodes.
<?xml version="1.0"?>
I have tryed to read and explode on "</li>"
$fd = fopen($filename, "r");
$string = fread($fd, filesize($filename));
$fru = explode ("</li>", $string);
for ($i=0;$fru[$i];++$i) {
$newfru = ("$fru[$i]"."</li>");
$newfru = str_replace("</kund>"."\r\n"."</li>","</kund>",$newfru);
print $newfru;
How to replace one of the $fru[i], I have tryed inside the forloop but
than it replaces all.

Thanks in advance for any help.

PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to