W3cubDocs

/WordPress

WP_Rewrite::using_permalinks()

Determines whether permalinks are being used.

Description

This can be either rewrite module or permalink in the HTTP query string.

Return

(bool) True, if permalinks are enabled.

Source

File: wp-includes/class-wp-rewrite.php

public function using_permalinks() {
		return ! empty( $this->permalink_structure );
	}

Changelog

Version Description
1.5.0 Introduced.

© 2003–2019 WordPress Foundation
Licensed under the GNU GPLv2+ License.
https://developer.wordpress.org/reference/classes/wp_rewrite/using_permalinks