MagicCMS Documentation

MagicPost..::..GetByType Method (array<Int32>[]()[][], String, Boolean, Int32, Boolean, MagicSearchActive)

Gets a collection of MagicPost filtered by type.

Namespace:  MagicCMS.Core
Assembly:  MagicCMS.4.5 (in MagicCMS.4.5.dll)

Syntax


public static MagicPostCollection GetByType(
	int[] types,
	string order,
	bool inclusive,
	int max,
	bool escludiScaduti,
	MagicSearchActive active
)

Parameters

types
Type: array<Int32>[]()[][]
The types array.
order
Type: String
Order in which the posts are sorted.
inclusive
Type: Boolean
If set to true include filtered otherwise exclude.
max
Type: Int32
Maximum number of posts returned.
escludiScaduti
Type: Boolean
If true filter post expired (expiration date prior to today).
active
Type: MagicCMS.Core..::..MagicSearchActive
Filter by Active flag.

Return Value

Fetched post collection

Remarks


This method is useful to make a rapid query filtered by various fields.