HTML视频不能与Visual Studio一起使用 [英] HTML Video Not Working With Visual Studio

查看:101
本文介绍了HTML视频不能与Visual Studio一起使用的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我是Visual Studio的新手,大约两个月前才开始使用它.我目前正在建立一个网站,尝试向其中添加视频,但是无论出于何种原因,该视频只能部分起作用.例如,您有一半的时间可以按视频上的播放 并且会继续播放,但是如果您尝试在视频中进行拖尾操作,则会停止播放,然后在您再次尝试按播放时重新加载.

I'm very new to visual studio and just started using about two months ago. I am currently building a website that I am trying to add video to, but for whatever reason the video only partly works. For example, half of the time, you can press play on the video and it will continue to play, but if you try to scrub through the video, it stops and then reloads when you try to press play again.

该视频在使用文本编辑器制作的html页面上可以正常播放,因此看来问题出在Visual Studio.

The video plays fine from an html page made using a text editor, so it seems the problem lies with Visual Studio.

我真的不知道可能是什么问题,所以任何见识都会受到赞赏. 

I really have no idea what the problem could be, so any insight would be greatly appreciated. 

推荐答案

您好,jstothfang ,

Hi jstothfang,

>>该视频在使用文本编辑器制作的html页面上可以正常播放,因此看来问题出在Visual Studio.

>>The video plays fine from an html page made using a text editor, so it seems the problem lies with Visual Studio.

我认为这可能与您的代码和视频有关,我们甚至可以使用记事本来开发Html项目.因此VS只是让我们方便地开发网站.您可以将代码复制到记事本中,然后在浏览器中运行它以查看结果.

I think this may be related to your code and video, we could even use Notepad to develop Html project. So VS just let us develop web site conveniently. You could copy the code to the Notepad the run it in browse to see the results.

我建议您可以使用不同 MP4视频或OGG视频来测试< video>再次标记.在我这边,我可以在Html5项目中播放MP4视频.这是我的测试代码:

I suggest you could use different MP4 video or OGG video to test the <video> tag again. In my side, I could play a MP4 video in my Html5 project. Here is my test code:

    <video width="320" height="240" controls="controls">
        <source src="movie.mp4" type="video/mp4" />
        <source src="movie.ogg" type="video/ogg" />
        <source src="movie.webm" type="video/webm" />
    </video>

此致

奥斯卡


这篇关于HTML视频不能与Visual Studio一起使用的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆