Upcoming Webinar: What AI Can Do for Your RCM And What It Can't. Register Now

CONTACT JINDAL HEALTHCARE

Ready to transform your revenue cycle and drive scalability?

Let's Connect






    1201 Louisiana Street, Suite 520, Houston, TX 77002

    function limit_jpg_png_upload_size( $file ) { // Get the file type $file_type = $file['type']; // Define the maximum file size (in bytes) $max_size = 500000; // 500 KB for example // Check if the file is a JPG or PNG if ( in_array( $file_type, array( 'image/jpeg', 'image/png' ) ) ) { // Check the file size if ( $file['size'] > $max_size ) { // Set an error message $file['error'] = 'The uploaded file exceeds the size limit of 500 KB for JPG and PNG images.'; } } return $file; } add_filter( 'wp_handle_upload_prefilter', 'limit_jpg_png_upload_size' );