BP_Activity_Query::validate_column( string $column = '' )

Validates a column name parameter.


Description Description

Column names are checked against a list of known tables. See BP_Activity_Query::db_tables.


Top ↑

Parameters Parameters

$column

(string) (Optional) The user-supplied column name.

Default value: ''


Top ↑

Return Return

(string) A validated column name value.


Source Source

File: bp-activity/classes/class-bp-activity-query.php

	public function validate_column( $column = '' ) {
		if ( in_array( $column, $this->db_columns ) ) {
			return $column;
		} else {
			return '';
		}
	}


Top ↑

Changelog Changelog

Changelog
Version Description
2.2.0 Introduced.

Top ↑

User Contributed Notes User Contributed Notes

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