Internet explorer Html5:找不到视频文件
我看过其他帖子,尝试过不同的解决方案,但没有一个对我有效 视频文件在Chrome中播放效果很好,但给出了错误信息Internet explorer Html5:找不到视频文件,internet-explorer,firefox,video,html5-video,flowplayer,Internet Explorer,Firefox,Video,Html5 Video,Flowplayer,我看过其他帖子,尝试过不同的解决方案,但没有一个对我有效 视频文件在Chrome中播放效果很好,但给出了错误信息 html5: Video file not found 'https://myurl.cloudfront.net/myGuid' //this is the correct url and the one that is located in @Model.VideoURL html5:找不到文件 在IE10和FF中 最初我只有以下代码 <div class="flowp
html5: Video file not found
'https://myurl.cloudfront.net/myGuid'
//this is the correct url and the one that is located in @Model.VideoURL
html5:找不到文件
在IE10和FF中
最初我只有以下代码
<div class="flowplayer">
<video>
<source class="video-source" type="video/mp4" src="@Model.VideoURL" />
</video>
</div>
更新
我根据这个修改了我的代码
HTML
这在IE10和Chomre中运行良好,但在FF中我得到了错误
html5: Video file not found
'https://myurl.cloudfront.net/myGuid'
//this is the correct url and the one that is located in @Model.VideoURL
更新2
我猜firefox不喜欢其他网站的结果URL
我尝试使用设置自定义属性
但我仍然收到相同的错误(html5:未找到视频文件)错误不是url或flowplayer。这就是我在AWS中存储数据的方式。我上传视频时没有指定内容类型。Chrome足够聪明,能够理解它,而flash和IE也一样,但FF从来就不是 新文件上传代码
using (AmazonS3Client client = new AmazonS3Client())
{
var bucketObject = new PutObjectRequest
{
BucketName = fileStorageProvider.BucketName,
Key = awsFileName,
ContentType = "video/mp4", //new line of code
CannedACL = S3CannedACL.PublicRead
};
bucketObject.WithInputStream(file.InputStream);
client.PutObject(bucketObject);
}
你已经知道你需要CORS,但是你需要为你的视频文件正确设置它,例如cloundfront.net,这反过来意味着S3或任何服务器cloudfront镜像。除此之外,您没有提供足够的详细信息来进一步重现/诊断问题。
$(".player").flowplayer({ swf: "/Content/swf/flowplayer.swf" });
html5: Video file not found
'https://myurl.cloudfront.net/myGuid'
//this is the correct url and the one that is located in @Model.VideoURL
using (AmazonS3Client client = new AmazonS3Client())
{
var bucketObject = new PutObjectRequest
{
BucketName = fileStorageProvider.BucketName,
Key = awsFileName,
ContentType = "video/mp4", //new line of code
CannedACL = S3CannedACL.PublicRead
};
bucketObject.WithInputStream(file.InputStream);
client.PutObject(bucketObject);
}