Closed johnwc closed 8 years ago
there is nothing "below"
Sorry, I didn't realize I had to wrap the code in special characters for them not to be stripped out.
I see. You can use .HtmlAttributes
extension to set these:
@Html.Bootstrap().FileFor(m => m.SomeFile).HtmlAttributes(new { @accept = "image/*;capture=camera" })
Or... you could add it to your existing Accept method and FileType enum and we can keep it clean.
Sent from my iPhone
On Feb 8, 2016, at 9:48 PM, Dmitry A. Efimenko notifications@github.com wrote:
I see. You can use .HtmlAttributes extension to set these:
@Html.Bootstrap().FileFor(m => m.SomeFile).HtmlAttributes(new { @accept = "image/*;capture=camera" }) — Reply to this email directly or view it on GitHub.
true, however there are so many of these types... The challenge of having an Enum for every single one is not something I would like to pursue.
Not true, this is not a mime type it's a html5 standard functionality to tell mobile devices to use the camera.
Sent from my iPhone
On Feb 9, 2016, at 10:17 AM, Dmitry A. Efimenko notifications@github.com wrote:
true, however. There are so many of these types... The challenge of having an Enum for every single one is not something I would like to pursue.
— Reply to this email directly or view it on GitHub.
Whatever it is, there are too many of them
Again, there are several several mime types, but this is not a mime type to be added. This is a hrml5 functionality to be added to the end of accept attribute.
Sent from my iPhone
On Feb 9, 2016, at 1:57 PM, Dmitry A. Efimenko notifications@github.com wrote:
Whatever it is, there are too many of them
— Reply to this email directly or view it on GitHub.
There is only one...
Sent from my iPhone
On Feb 9, 2016, at 1:57 PM, Dmitry A. Efimenko notifications@github.com wrote:
Whatever it is, there are too many of them
— Reply to this email directly or view it on GitHub.
This example already shows multiple options What would be the api for this?
It's the Round 1 HTML Media Capture section.
Sent from my iPhone
On Feb 9, 2016, at 3:10 PM, Dmitry A. Efimenko notifications@github.com wrote:
This example already shows multiple options What would be the api for this?
— Reply to this email directly or view it on GitHub.
Just add another enum for image, video and audio like so.
[Description("image/*;capture=camera")]
ImageCapture,
[Description("image/*;capture=camcorder")]
VideoCapture,
[Description("audio/*;capture=microphone")]
AudioCapture,
This is done
We need the ability to also add the type for camera capture. So that the accept can be as below.
<input type="file" id="vFile" name="vFile" accept="image/*;capture=camera" />