Fork me on GitHub

PagerOptions.NavigationPagerItemsPosition property

Gets or sets the position of the first, previous, next and last pager items.

Syntax:

public PagerItemsPosition NavigationPagerItemsPosition {get; set;}

Default value:

PagerItemsPosition.BothSide

Example:

@Html.Pager(Model,new PagerOptions{NavigationPagerItemsPosition=PagerItemsPosition.Left})

This property value can also be set via the Options method as bellow:

HtmlPager:

@Html.Pager(Model).Options(o=>o.SetNavigationPagerItemsPosition(PagerItemsPosition.Left))

AjaxPager:

@Ajax.Pager(Model).Options(o=>o.SetNavigationPagerItemsPosition(PagerItemsPosition.Left)).AjaxOptions(a=>a.SetUpdateTargetId("target"))

Live demo:

@Html.Pager(Model,new PagerOptions{NavigationPagerItemsPosition=PagerItemsPosition.Left})
FirstPrevNextLast12345678910...

@Html.Pager(Model).Options(o=>o.SetNavigationPagerItemsPosition(PagerItemsPosition.Left))
12345678910...FirstPrevNextLast