protected function doPing($bAddInDirectory)
 {
     //here, url is passed in any case for verification purpose
     //but don't worry, it's stored on server side only when 'addindirectory' is true
     $sPingTarget = ANWIKI_WEBPING . 'newinstall?' . 'siteurl=' . urlencode(AnwComponent::globalCfgUrlRoot()) . '&sitelang=' . urlencode(AnwComponent::globalCfgLangDefault()) . '&lang=' . urlencode(AnwCurrentSession::getLang()) . '&addindirectory=' . ($bAddInDirectory ? '1' : '0') . '&versionid=' . urlencode(ANWIKI_VERSION_ID) . '&nocache=' . time();
     $this->out .= $this->tpl()->doPing($sPingTarget, $this->linkMe() . '&pingdone=1');
 }
Beispiel #2
0
 static function cfgUrlStaticSetup($bFullUrl = false)
 {
     if (AnwComponent::globalCfgStaticsSetupEnabled()) {
         $sUrlStatic = AnwComponent::globalCfgStaticsSetupUrl();
     } else {
         if (!$bFullUrl) {
             $sUrlStatic = AnwUtils::linkRelative();
         } else {
             $sUrlStatic = AnwComponent::globalCfgUrlRoot();
         }
     }
     return $sUrlStatic;
 }
Beispiel #3
0
 static function mail($sEmail, $sSubject, $sBody)
 {
     $sSubject = "[" . AnwComponent::globalCfgWebsiteName() . "] " . $sSubject;
     $sBody .= "\n\n" . AnwComponent::globalCfgWebsiteName() . "\n";
     $sBody .= AnwComponent::globalCfgUrlRoot();
     @mail($sEmail, $sSubject, $sBody);
     self::debug("(AnwUtils) Sent a mail to " . $sEmail . " : " . $sSubject);
 }