function _amp_dfp_get_lowest_resolution in Accelerated Mobile Pages (AMP) 7
Parameters
$sizes: A string of comma-separated resolution sizes. Ex. 300x250
Return value
mixed A string of lowest sized resolution.
1 call to _amp_dfp_get_lowest_resolution()
- _amp_dfp_get_amp_size in modules/
amp_dfp/ amp_dfp.module - Given a DFP tag object, return the size that should be used for an amp-ad element.
File
- modules/
amp_dfp/ amp_dfp.module, line 232 - AMP integration for the DFP module.
Code
function _amp_dfp_get_lowest_resolution($sizes) {
$resolutions = explode(',', $sizes);
return array_reduce($resolutions, '_amp_dfp_size_reduce_callback');
}