public function ExportData::setPageOrder in Loft Data Grids 6.2
Same name and namespace in other branches
- 7.2 vendor/aklump/loft_data_grids/src/AKlump/LoftDataGrids/ExportData.php \AKlump\LoftDataGrids\ExportData::setPageOrder()
Set the order the pages appear in the data array
Parameters
string $page_id: Enter all page_ids in correct order as function arguments
Return value
$this
Overrides ExportDataInterface::setPageOrder
File
- vendor/
aklump/ loft_data_grids/ src/ AKlump/ LoftDataGrids/ ExportData.php, line 218
Class
Namespace
AKlump\LoftDataGridsCode
public function setPageOrder($page_id) {
$page_ids = func_get_args();
$temp = array();
foreach ($page_ids as $page_id) {
$temp[$page_id] = isset($this->data[$page_id]) ? $this->data[$page_id] : array();
}
$temp += $this->data;
$this->data = $temp;
return $this;
}