WP_Screen::get_columns()

Gets the number of layout columns the user has selected.


Description Description

The layout_columns option controls the max number and default number of columns. This method returns the number of columns within that range selected by the user via Screen Options. If no selection has been made, the default provisioned in layout_columns is returned. If the screen does not support selecting the number of layout columns, 0 is returned.


Top ↑

Return Return

(int) Number of columns to display.


Top ↑

Source Source

File: wp-admin/includes/class-wp-screen.php

	public function get_columns() {
		return $this->columns;
	}


Top ↑

Changelog Changelog

Changelog
Version Description
3.4.0 Introduced.

Top ↑

User Contributed Notes User Contributed Notes

You must log in before being able to contribute a note or feedback.