php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #16531 XML_RSS produces some warnings
Submitted: 2002-04-10 10:46 UTC Modified: 2002-04-11 01:35 UTC
From: M dot Hankus at ce3 dot pl Assigned:
Status: Closed Package: PEAR related
PHP Version: 4.1.2 OS: Linux
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: M dot Hankus at ce3 dot pl
New email:
PHP Version: OS:

 

 [2002-04-10 10:46 UTC] M dot Hankus at ce3 dot pl
I've just installed XML/RSS module from PEAR. It produces
some warnings because .= operator is used on uninitialised value. Solution below (DC:CREATOR, DC:DATE are some additional elements from Dublin Core http://dublincore.org/2001/08/14/dces which I use - which  might also be added to a module)


206c206,208
<                     case "DESCRIPTION" :
---
>                     case "DESCRIPTION" :
>                     case "DC:CREATOR":
>                     case "DC:DATE":
267,268c269,273
<     {
<         $this->{$type}[$field] .= $value;
---
>     {
> 	if(empty($this->{$type}) || empty($this->{$type}[$field])) 
> 	    $this->{$type}[$field] = $value;
> 	else 
>     	    $this->{$type}[$field] .= $value;

Patches

Pull Requests

 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sun Dec 22 11:01:30 2024 UTC