使用Javascript / jQuery将焦点设置为嵌入式Flash电影/ HTML嵌入元素 [英] Setting focus to an embedded Flash movie/HTML embed element using Javascript/jQuery

查看:152
本文介绍了使用Javascript / jQuery将焦点设置为嵌入式Flash电影/ HTML嵌入元素的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

有没有办法将焦点设置为使用JavaScript嵌入HTML元素?测试案例:在一个页面上嵌入YouTube视频。



我无法控制嵌入式Flash元素。那么,有没有办法通过只使用JavaScript来关注它?

我读过某处调用element.focus()方法只能在IE中使用的地方。我需要一个独立于浏览器的方式,可以在Chrome / Firefox中使用。

谢谢!

解决方案

这只适用于Internet Explorer。 / p>

http://kb2.adobe .com / cps / 155 / tn_15586.html


Is there a way to set focus to the embed HTML element using JavaScript? Test case: embedded YouTube videos on a page.

I have no control over the embedded Flash element. So, is there a way to set focus on it by using only JavaScript?

I read somewhere that calling the element.focus() method works only in IE. I need a browser-independent way that works in Chrome/Firefox.

Thanks!

解决方案

This only works in Internet Explorer.

http://kb2.adobe.com/cps/155/tn_15586.html

这篇关于使用Javascript / jQuery将焦点设置为嵌入式Flash电影/ HTML嵌入元素的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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