MagpieRSS::normalize() WordPress Method
The MagpieRSS::normalize() method is used to normalize a string for use in XML. This includes converting all non-ASCII characters to their corresponding XML entities.
MagpieRSS::normalize() #
Source
File: wp-includes/rss.php
function normalize () { // if atom populate rss fields if ( $this->is_atom() ) { $this->channel['descripton'] = $this->channel['tagline']; for ( $i = 0; $i < count($this->items); $i++) { $item = $this->items[$i]; if ( isset($item['summary']) ) $item['description'] = $item['summary']; if ( isset($item['atom_content'])) $item['content']['encoded'] = $item['atom_content']; $this->items[$i] = $item; } } elseif ( $this->is_rss() ) { $this->channel['tagline'] = $this->channel['description']; for ( $i = 0; $i < count($this->items); $i++) { $item = $this->items[$i]; if ( isset($item['description'])) $item['summary'] = $item['description']; if ( isset($item['content']['encoded'] ) ) $item['atom_content'] = $item['content']['encoded']; $this->items[$i] = $item; } } }
Expand full source codeCollapse full source codeView on TracView on GitHub