Пример #1
0
 /**
  * (non-PHPdoc)
  * @see EGMapKMLNode::toXML()
  */
 public function toXML()
 {
     $icon = new EGMapKMLNode('Icon');
     if (!is_null($this->href)) {
         $icon->addChild(new EGMapKMLNode('href', $this->href));
     }
     $this->addChild($icon);
     $result = CHtml::openTag('Style', array('id' => $this->id));
     $result .= parent::toXML();
     $result .= CHtml::closeTag('Style');
     return $result;
 }
Пример #2
0
 /**
  * (non-PHPdoc)
  * @see EGMapKMLNode::toXML()
  */
 public function toXML()
 {
     $node = new EGMapKMLNode('LinearRing');
     $node->addChild(new EGMapKMLNode('coordinates', $this->coordinates));
     $parentNode = new EGMapKMLNode($this->boundary ? 'outerBoundaryIs' : 'innerBoundaryIs');
     $parentNode->addChild($node);
     $this->addChild($parentNode);
     return parent::toXML();
 }