month_link WordPress Filter Hook

In WordPress, the month_link hook is used to modify the month link created by the get_month_link() function. This hook can be useful for creating a custom link structure for your archives, or for changing the way in which months are displayed.

apply_filters( 'month_link', string $monthlink, int $year, int $month ) #

Filters the month archive permalink.


Parameters

$monthlink

(string)Permalink for the month archive.

$year

(int)Year for the archive.

$month

(int)The month for the archive.


Top ↑

Source

File: wp-includes/link-template.php

View on Trac



Top ↑

Changelog

Changelog
VersionDescription
1.5.0Introduced.

The content displayed on this page has been created in part by processing WordPress source code files which are made available under the GPLv2 (or a later version) license by theĀ Free Software Foundation. In addition to this, the content includes user-written examples and information. All material is subject to review and curation by the WPPaste.com community.

Show More
Show More