如何定位 jPlayer
我似乎不知道如何定位 jPlayer。
我查看了 jPlayer 的文档,其中说 jPlayer 默认设置为绝对定位,但似乎并非如此,因为它似乎是页面流程的一部分,而不是像绝对定位元素那样脱离流程。
另外,我尝试将 left、top、bottom 和 right CSS 属性应用到 jPlayer 组成的一堆元素,但没有一次尝试进行任何更改。
另外,将选项添加到 jPlayer 上的 javascript 部分似乎也没有执行任何操作。我正在谈论此处列出的选项: http://www.jplayer.org/ 0.2.2/开发人员指南/。我尝试了顶部和左侧,但他们什么也没做。
I can't seem to figure out how to position jPlayer.
I looked at jPlayer's documentation which says that jPlayer is set to be absolute positioned by default, but it doesn't appear to be because it seems to be part of the flow of the page, not out of the flow like an absolutely positioned element is.
Also, I tried applying the left, top, bottom, and right CSS properties to a bunch of elements that the jPlayer is made of and not a single attempt made any change.
Also, adding options into the javascript section on jPlayer don't seem to do anything either. I'm talking about the options listed here: http://www.jplayer.org/0.2.2/developer-guide/. I tried top and left and they did nothing.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
将其放在主
div
或第一个div
标记中。然后,完成后,您可以根据需要编辑位置:Put this in the main
div
or firstdiv
tag. Then, once you are done with it, you can edit the position as you wish:您可以完全控制 jPlayer 实例的 HTML 标记和 CSS 外观/感觉。下面的示例(请参阅此处的 Fiddle)
使用此标准 GUI 标记(取自 jPlayer 演示),
您可以实例化使用此 javascript 的播放器
可以在浏览器中呈现简单的、无样式的 HTML。您可以根据需要设计 jPlayer GUI 的样式。例如,通过添加一些定位规则
You have full control of the HTML Markup and CSS look/feel of your jPlayer instance. Example below (see Fiddle here)
With this standard GUI markup (taken from the jPlayer demos)
you can instantiate a player with this javascript
this renders plain, unstyled HTML in your browser. You can style your jPlayer GUI as you please. For example, by adding some positioning rules