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
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
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

Add a Patch

Pull Requests

Add a Pull Request

 
PHP Copyright © 2001-2017 The PHP Group
All rights reserved.
Last updated: Sun Nov 19 01:31:42 2017 UTC