0 File Uploader in Block Settings 1 Daniel Hazelbaker posted 8 Years Ago Okay, so I have a block that is going to include a URL to an image in an XML feed. I want the user (administrator) to be able to select what image. BinaryFileField seemed like the way to go. But it only lets you select an existing image, not upload a new one. Digging through the source code I came up with this. It seems to work but I'm not sure if I am just missing the correct way to do it (or is this it), and I'm not sure if it is safe to do so:[BinaryFileField( Rock.SystemGuid.BinaryFiletype.MEDIA_FILE, "About Us Category Image", "The image to use for the about us category.", false, category: "About Us", order: 3, FieldTypeClass = "Rock.Field.Types.ImageFieldType" )]
Nick Airdo 8 years ago Daniel, we'll also happily accept a pull request if you want to add those ImageFieldTypeAttribute and FileFieldTypeAttribute classes (if you're up to coding them.)