bp_inline_cropper_image

  • apply_filters( 'bp_inline_cropper_image', getimagesize( bp_core_avatar_upload_path() . $bp->avatar_admin->image->dir ) )

    Source Reference:

    • Component: BuddyPress :: bp-core
      File: /bp-core/bp-core-cssjs.php :: Trac Source Line: 78
       * bp_core_add_cropper_inline_js()
       *
       * Adds the inline JS needed for the cropper to work on a per-page basis.
       *
       * @package BuddyPress Core
       */
      function bp_core_add_cropper_inline_js() {
      	global $bp;
      
      	$image = apply_filters( 'bp_inline_cropper_image', getimagesize( bp_core_avatar_upload_path() . $bp->avatar_admin->image->dir ) );
      	$aspect_ratio = 1;
      
      	$full_height = bp_core_avatar_full_height();
      	$full_width  = bp_core_avatar_full_width();
      
      	// Calculate Aspect Ratio
      	if ( $full_height && ( $full_width != $full_height ) )
      		$aspect_ratio = $full_width / $full_height;
      
      	$width  = $image[0] / 2;
      

Comments are closed.