WordPress at a glance
function is not described

SimplePie::set_raw_data() public WP 1.0

Set the raw XML data to parse

Allows you to use a string of RSS/Atom data instead of a remote feed.

If you have a feed available as a string in PHP, you can tell SimplePie to parse that data string instead of a remote feed. Any set feed URL takes precedence.

{} It's a method of the class: SimplePie{}

No Hooks.

Return

null. Nothing.

Usage

$SimplePie = new SimplePie();
$SimplePie->set_raw_data( $data );
$data(string) (required)
RSS or Atom data as a string.

Notes

  • See: set_feed_url()

Changelog

Since 1.0 Introduced.
Since 1.0 Beta 3

Code of SimplePie::set_raw_data() WP 5.7.2

<?php
public function set_raw_data($data)
{
	$this->raw_data = $data;
}