maintenance/runStatistics.php
private function getStatisticSites() {
		$result = [ ];
		
		$StatistikQuery = new \SMWPrintRequest ( \SMWPrintRequest::PRINT_PROP, "StatistikQuery",
				\SMWPropertyValue::makeUserProperty ( 'StatistikQuery' ) );
		$StatistikTemplate = new \SMWPrintRequest ( \SMWPrintRequest::PRINT_PROP, "StatistikTemplate",
				\SMWPropertyValue::makeUserProperty ( 'StatistikTemplate' ) );
		
		$pages = QueryUtils::executeBasicQuery ( '[[Category:Statistik]]', [$StatistikQuery, $StatistikTemplate ], [] );
		
		while ( $res = $pages->getNext () ) {
			$pageID = $res [0]->getNextText ( SMW_OUTPUT_WIKI );
			$StatistikQuery = $res [1]->getNextText ( SMW_OUTPUT_WIKI );
			$StatistikTemplate = $res [2]->getNextText ( SMW_OUTPUT_WIKI );
			$mwTitle = \Title::newFromText ( $pageID );
			$result [] = [ 'title' => $mwTitle,
						   'statistikQuery' => urldecode($StatistikQuery),
						   'statistikTemplate' => urldecode($StatistikTemplate)
			];
		}
		
		return $result;
	}
private function getStatisticSites() {
		$result = [ ];
		
		$StatistikQuery = new \SMWPrintRequest ( \SMWPrintRequest::PRINT_PROP, "StatistikQuery",
				\SMWPropertyValue::makeUserProperty ( 'StatistikQuery' ) );
		$StatistikTemplate = new \SMWPrintRequest ( \SMWPrintRequest::PRINT_PROP, "StatistikTemplate",
				\SMWPropertyValue::makeUserProperty ( 'StatistikTemplate' ) );
		
		$pages = QueryUtils::executeBasicQuery ( '[[Category:Statistik]]', [$StatistikQuery, $StatistikTemplate ], [] );
		
		while ( $res = $pages->getNext () ) {
			$pageID = $res [0]->getNextText ( SMW_OUTPUT_WIKI );
			$StatistikQuery = $res [1]->getNextText ( SMW_OUTPUT_WIKI );
			$StatistikTemplate = $res [2]->getNextText ( SMW_OUTPUT_WIKI );
			$mwTitle = \Title::newFromText ( $pageID );
			$result [] = [ 'title' => $mwTitle,
						   'statistikQuery' => urldecode($StatistikQuery),
						   'statistikTemplate' => urldecode($StatistikTemplate)
			];
		}
		
		return $result;
	}
private function getStatisticSites ( ) { $ result = [ ] ; $ StatistikQuery = new \ SMWPrintRequest ( \ SMWPrintRequest :: PRINT_PROP , "StatistikQuery" , \ SMWPropertyValue :: makeUserProperty ( 'StatistikQuery' ) ) ; $ StatistikTemplate = new \ SMWPrintRequest ( \ SMWPrintRequest :: PRINT_PROP , "StatistikTemplate" , \ SMWPropertyValue :: makeUserProperty ( 'StatistikTemplate' ) ) ; $ pages = QueryUtils :: executeBasicQuery ( '[[Category:Statistik]]' , [ $ StatistikQuery , $ StatistikTemplate ] , [ ] ) ; while ( $ res = $ pages -> getNext ( ) ) { $ pageID = $ res [ 0 ] -> getNextText ( SMW_OUTPUT_WIKI ) ; $ StatistikQuery = $ res [ 1 ] -> getNextText ( SMW_OUTPUT_WIKI ) ; $ StatistikTemplate = $ res [ 2 ] -> getNextText ( SMW_OUTPUT_WIKI ) ; $ mwTitle = \ Title :: newFromText ( $ pageID ) ; $ result [ ] = [ 'title' => $ mwTitle , 'statistikQuery' => urldecode ( $ StatistikQuery ) , 'statistikTemplate' => urldecode ( $ StatistikTemplate ) ] ; } return $ result ; }
Returns array of statistic site with StatistikQuery, StatistikTemplate annotations
@return array of [ title, statistikQuery, statistikTemplate ]
Returns array of statistic site with StatistikQuery StatistikTemplate annotations