protected function addMagicEndTag(Tag $startTag, $tagPos, $prio = 0)
	{
		$tagName = $startTag->getName();

		// Adjust the end tag's position if whitespace is to be minimized
		if (($this->currentTag->getFlags() | $startTag->getFlags()) & self::RULE_IGNORE_WHITESPACE)
		{
			$tagPos = $this->getMagicEndPos($tagPos);
		}

		// Add a 0-width end tag that is paired with the given start tag
		$endTag = $this->addEndTag($tagName, $tagPos, 0, $prio);
		$endTag->pairWith($startTag);

		return $endTag;
	}
protected function addMagicEndTag(Tag $startTag, $tagPos, $prio = 0)
	{
		$tagName = $startTag->getName();

		// Adjust the end tag's position if whitespace is to be minimized
		if (($this->currentTag->getFlags() | $startTag->getFlags()) & self::RULE_IGNORE_WHITESPACE)
		{
			$tagPos = $this->getMagicEndPos($tagPos);
		}

		// Add a 0-width end tag that is paired with the given start tag
		$endTag = $this->addEndTag($tagName, $tagPos, 0, $prio);
		$endTag->pairWith($startTag);

		return $endTag;
	}
protected function addMagicEndTag ( Tag $ startTag , $ tagPos , $ prio = 0 ) { $ tagName = $ startTag -> getName ( ) ; // Adjust the end tag's position if whitespace is to be minimized if ( ( $ this -> currentTag -> getFlags ( ) | $ startTag -> getFlags ( ) ) & self :: RULE_IGNORE_WHITESPACE ) { $ tagPos = $ this -> getMagicEndPos ( $ tagPos ) ; } // Add a 0-width end tag that is paired with the given start tag $ endTag = $ this -> addEndTag ( $ tagName , $ tagPos , 0 , $ prio ) ; $ endTag -> pairWith ( $ startTag ) ; return $ endTag ; }
Create and add an end tag for given start tag at given position

@param  Tag     $startTag Start tag
@param  integer $tagPos   End tag's position (will be adjusted for whitespace if applicable)
@param  integer $prio     End tag's priority
@return Tag
Create and add an end tag for given start tag at given position