Uma área de pesquisa sobre o WordPress para devs e autores do tema



wp_constrain_dimensions ›

Desde4.1.0
Obsoleton/a
apply_filters( 'wp_constrain_dimensions', array( $w, $h )
Parâmetros: (5)
  • (array) $dimensions The image width and height.
    Required: Yes
  • (int) $current_width The current width of the image.
    Required: Yes
  • (int) $current_height The current height of the image.
    Required: Yes
  • (int) $max_width The maximum width permitted.
    Required: Yes
  • (int) $max_height The maximum height permitted.
    Required: Yes
Definido em:
Codex:

Filters dimensions to constrain down-sampled images to.





Fonte

return apply_filters( 'wp_constrain_dimensions', array( $w, $h ), $current_width, $current_height, $max_width, $max_height );