_customizer_mobile_viewport_meta() WordPress Function
This function allows you to modify the mobile viewport meta tag. This can be used to improve the mobile browsing experience on your site.
_customizer_mobile_viewport_meta( string $viewport_meta ) #
Adds viewport meta for mobile in Customizer.
Description
Hooked to the ‘admin_viewport_meta’ filter.
Parameters
- $viewport_meta
(string)(Required)The viewport meta.
Return
(string) Filtered viewport meta.
Source
File: wp-admin/includes/misc.php
function _customizer_mobile_viewport_meta( $viewport_meta ) { return trim( $viewport_meta, ',' ) . ',minimum-scale=0.5,maximum-scale=1.2'; }
Expand full source codeCollapse full source codeView on TracView on GitHub
Changelog
Version | Description |
---|---|
5.5.0 | Introduced. |