Sulu\Component\Webspace\Portal::setName PHP Method

setName() public method

Sets the name of the portal.
public setName ( string $name )
$name string The name of the portal
    public function setName($name)
    {
        $this->name = $name;
    }

Usage Example

Esempio n. 1
0
 /**
  * Generate all the portals for the webspace.
  */
 protected function generatePortals()
 {
     foreach ($this->xpath->query('/x:webspace/x:portals/x:portal') as $portalNode) {
         /** @var \DOMNode $portalNode */
         $portal = new Portal();
         $portal->setName($this->xpath->query('x:name', $portalNode)->item(0)->nodeValue);
         $portal->setKey($this->xpath->query('x:key', $portalNode)->item(0)->nodeValue);
         // set localization on portal
         $this->generatePortalLocalizations($portalNode, $portal);
         $this->webspace->addPortal($portal);
         $portal->setWebspace($this->webspace);
         // set environments
         $this->generateEnvironments($portalNode, $portal);
     }
 }
All Usage Examples Of Sulu\Component\Webspace\Portal::setName