src/Elements.php
public function multiFetchElements($element, $params)
	{
		if ($element != 'nodes' && $element != 'ways' && $element != 'relations')
		{
			throw new \DomainException('Element should be nodes, ways or relations');
		}

		// Get singular word
		$singleElement = substr($element, 0, \strlen($element) - 1);

		// Set the API base, $params is a string with comma seperated values
		$base = $element . '?' . $element . '=' . $params;

		// Build the request path.
		$path = $this->getOption('api.url') . $base;

		// Send the request.
		$xmlString = $this->sendRequest($path);

		return $xmlString->$singleElement;
	}
public function multiFetchElements($element, $params)
	{
		if ($element != 'nodes' && $element != 'ways' && $element != 'relations')
		{
			throw new \DomainException('Element should be nodes, ways or relations');
		}

		// Get singular word
		$singleElement = substr($element, 0, \strlen($element) - 1);

		// Set the API base, $params is a string with comma seperated values
		$base = $element . '?' . $element . '=' . $params;

		// Build the request path.
		$path = $this->getOption('api.url') . $base;

		// Send the request.
		$xmlString = $this->sendRequest($path);

		return $xmlString->$singleElement;
	}
public function multiFetchElements ( $ element , $ params ) { if ( $ element != 'nodes' && $ element != 'ways' && $ element != 'relations' ) { throw new \ DomainException ( 'Element should be nodes, ways or relations' ) ; } // Get singular word $ singleElement = substr ( $ element , 0 , \ strlen ( $ element ) - 1 ) ; // Set the API base, $params is a string with comma seperated values $ base = $ element . '?' . $ element . '=' . $ params ; // Build the request path. $ path = $ this -> getOption ( 'api.url' ) . $ base ; // Send the request. $ xmlString = $ this -> sendRequest ( $ path ) ; return $ xmlString -> $ singleElement ; }
Method to get data about multiple ids of an element [node|way|relation]

@param   string  $element  [nodes|ways|relations] - use plural word
@param   string  $params   Comma separated list of ids belonging to type $element

@return  array   The XML response

@since   1.0
@throws  \DomainException
Method to get data about multiple ids of an element [ node|way|relation ]