public function getPartitionedHolderForArticle($article) {
		if ($this->FileBy == 'Published' && $article->OriginalPublishedDate) {
			$date = $article->OriginalPublishedDate;
		} else if ($this->hasField($this->FileBy)) {
			$field = $this->FileBy;
			$date = $this->$field;
		} else {
			$date = $article->Created;
		}

		$year = date('Y', strtotime($date));
		$month = date('M', strtotime($date));
		$day = date('d', strtotime($date));

		$yearFolder = $this->dateFolder($year);
		if (!$yearFolder) {
			throw new Exception("Failed retrieving folder");
		}

		if ($this->FilingMode == 'year') {
			return $yearFolder;
		}

		$monthFolder = $yearFolder->dateFolder($month);
		if (!$monthFolder) {
			throw new Exception("Failed retrieving folder");
		}
		
		if ($this->FilingMode == 'month') {
			return $monthFolder;
		}

		$dayFolder = $monthFolder->dateFolder($day);
		if (!$dayFolder) {
			throw new Exception("Failed retrieving folder");
		}

		return $dayFolder;
	}
public function getPartitionedHolderForArticle($article) {
		if ($this->FileBy == 'Published' && $article->OriginalPublishedDate) {
			$date = $article->OriginalPublishedDate;
		} else if ($this->hasField($this->FileBy)) {
			$field = $this->FileBy;
			$date = $this->$field;
		} else {
			$date = $article->Created;
		}

		$year = date('Y', strtotime($date));
		$month = date('M', strtotime($date));
		$day = date('d', strtotime($date));

		$yearFolder = $this->dateFolder($year);
		if (!$yearFolder) {
			throw new Exception("Failed retrieving folder");
		}

		if ($this->FilingMode == 'year') {
			return $yearFolder;
		}

		$monthFolder = $yearFolder->dateFolder($month);
		if (!$monthFolder) {
			throw new Exception("Failed retrieving folder");
		}
		
		if ($this->FilingMode == 'month') {
			return $monthFolder;
		}

		$dayFolder = $monthFolder->dateFolder($day);
		if (!$dayFolder) {
			throw new Exception("Failed retrieving folder");
		}

		return $dayFolder;
	}
public function getPartitionedHolderForArticle ( $ article ) { if ( $ this -> FileBy == 'Published' && $ article -> OriginalPublishedDate ) { $ date = $ article -> OriginalPublishedDate ; } else if ( $ this -> hasField ( $ this -> FileBy ) ) { $ field = $ this -> FileBy ; $ date = $ this -> $ field ; } else { $ date = $ article -> Created ; } $ year = date ( 'Y' , strtotime ( $ date ) ) ; $ month = date ( 'M' , strtotime ( $ date ) ) ; $ day = date ( 'd' , strtotime ( $ date ) ) ; $ yearFolder = $ this -> dateFolder ( $ year ) ; if ( ! $ yearFolder ) { throw new Exception ( "Failed retrieving folder" ) ; } if ( $ this -> FilingMode == 'year' ) { return $ yearFolder ; } $ monthFolder = $ yearFolder -> dateFolder ( $ month ) ; if ( ! $ monthFolder ) { throw new Exception ( "Failed retrieving folder" ) ; } if ( $ this -> FilingMode == 'month' ) { return $ monthFolder ; } $ dayFolder = $ monthFolder -> dateFolder ( $ day ) ; if ( ! $ dayFolder ) { throw new Exception ( "Failed retrieving folder" ) ; } return $ dayFolder ; }
Gets an appropriate sub article holder for the given article page

@param Page $article
Gets an appropriate sub article holder for the given article page