piwik/plugins/SitesManager/API.php
/**
     * Add a list of alias Urls to the given idSite
     *
     * If some URLs given in parameter are already recorded as alias URLs for this website,
     * they won't be duplicated. The 'main_url' of the website won't be affected by this method.
     *
     * @param int $idSite
     * @param array|string $urls
     * @return int the number of inserted URLs
     */
Add a list of alias Urls to the given idSite
If some URLs given in parameter are already recorded as alias URLs for this website,
they won't be duplicated. The 'main_url' of the website won't be affected by this method.

@param int $idSite
@param array|string $urls
@return int the number of inserted URLs
Add a list of alias Urls to the given idSite If some URLs given in parameter are already recorded as alias URLs for this website they won ' t be duplicated . The ' main_url ' of the website won ' t be affected by this method . @param int $idSite @param array|string $urls @return int the number of inserted URLs
public function addSiteAliasUrls($idSite, $urls)
    {
        Piwik::checkUserHasAdminAccess($idSite);
        $urls = $this->cleanParameterUrls($urls);
        $this->checkUrls($urls);
        $urlsInit = $this->getSiteUrlsFromId($idSite);
        $toInsert = array_diff($urls, $urlsInit);
        $this->insertSiteUrls($idSite, $toInsert);
        $this->postUpdateWebsite($idSite);
        return count($toInsert);
    }
public function addSiteAliasUrls ( $ idSite , $ urls ) { Piwik :: checkUserHasAdminAccess ( $ idSite ) ; $ urls = $ this -> cleanParameterUrls ( $ urls ) ; $ this -> checkUrls ( $ urls ) ; $ urlsInit = $ this -> getSiteUrlsFromId ( $ idSite ) ; $ toInsert = array_diff ( $ urls , $ urlsInit ) ; $ this -> insertSiteUrls ( $ idSite , $ toInsert ) ; $ this -> postUpdateWebsite ( $ idSite ) ; return count ( $ toInsert ) ; }
Add a list of alias Urls to the given idSite
 If some URLs given in parameter are already recorded as alias URLs for this website,
 they won't be duplicated.
Add a list of alias Urls to the given idSite If some URLs given in parameter are already recorded as alias URLs for this website they won ' t be duplicated .