---
title: "pageViewController(_:spineLocationFor:)"
framework: uikit
role: symbol
role_heading: Instance Method
path: "uikit/uipageviewcontrollerdelegate/pageviewcontroller(_:spinelocationfor:)"
---

# pageViewController(_:spineLocationFor:)

Returns the spine location for the given orientation.

## Declaration

```swift
optional func pageViewController(_ pageViewController: UIPageViewController, spineLocationFor orientation: UIInterfaceOrientation) -> UIPageViewController.SpineLocation
```

## Parameters

- `pageViewController`: The page view controller
- `orientation`: The new orientation.

## Return Value

Return Value The spine location.

## Discussion

Discussion Use this method to change the spine location when the device orientation changes, as well as setting new view controllers and changing the double-sided state. This method is called only if the transition style is UIPageViewController.TransitionStyle.pageCurl.

## See Also

### Responding to Page View Controller Events

- [pageViewController(_:willTransitionTo:)](uikit/uipageviewcontrollerdelegate/pageviewcontroller(_:willtransitionto:).md)
- [pageViewController(_:didFinishAnimating:previousViewControllers:transitionCompleted:)](uikit/uipageviewcontrollerdelegate/pageviewcontroller(_:didfinishanimating:previousviewcontrollers:transitioncompleted:).md)
