WordPress制作媒体元素.js反应敏捷的

我正在测试WordPress 3.6 Beta 3,很难使媒体播放器具有响应性。 我添加了以下过滤器,可以正常工作。 /** * filter audio shortcodes to add> However there appears to be a bug in mediaelement.js. The css is breaking in responsive mode and the volume slide bar displays outside and below the player. When you change the screen size the volume slider pops into position and out of position repeatedly, suggesting a calculated and returned width issue, within the plugin. I\"m a newbie when it comes to jQuery but this appears to be the fix… In mediaelement-and-player.js : Replace:>with:> What this does is always forces .mejs-time-rail width to be 1 px less than calculated so the css is never broken. Is there any chance of getting someone to look into this. Same problem here, but it was not solved for me by adding the -1. Take a look here and you can see that it is working for me. Perhaps the plugin was changed by the author? Contact me through kevinsspace.ca and I can send you my modified plugin. Hi Kevin, I was using the mediaelement plug for WP, but having just upgraded to WP 3.6 today, I removed the plug and changed all my links to use WP integration with mediaelement. That\"s where I made the -1 change, and it didn\"t work for me – you can see on the right side of my site: http://tactosound.com I\"ll get in touch with you for your modded plug. thanks! correction, the -1 fix is working for me. cache issue. cheers! Hey! Thanks a ton for the tip! The volume slider still pops out when changing the width but pops back in the moment you stop moving the mouse. If anyone searches for it in WP 3.6 look in the file /wp-includes/js/mediaelement/mediaelement-and-player.min.js 您要找的部分没有空格(这就是为什么我没有找到正确的> 并更改它,正如Kevin上面提到的那样。 哦,记住清除缓存,就像twakspot说的… 关于这个问题,应该联系谁?这应该在WordPress核心中修复! 这应该在核心中起作用。事实上。他们花了很多时间在不同的浏览器上测试它http://core.trac.wordpress.org/search?q=> 嗨,米卡 看起来不再需要过滤器,而是媒体元素.jsplugin仍然有一个音量条破坏了屏幕上的css大小。 我也看到了音量条破坏的问题… 嗨,凯文, 非常感谢您的修复!-正如丁伯特所说,我发现-1仍在中断。 我只是将其设置为-2,因此已停止了WordPress 3.6本机音频播放器容器上音量滑块的中断。 也可以这样做。 Publicu html->;wp includes->;js->;mediaelement->;mediaelement和-播放器.min 点击CTRL+F并搜索> (它应该是唯一被搜索1/1的东西)。 正如凯文现在所说,在结尾加上-1,但是,我加了-2来阻止缩放时音量滑块断裂> 通过点击CTRL+SHIFT+R来清除缓存 非常感谢凯文。 也请继续注意,这是在编辑核心文件。。因此,更新后,请注意您将需要再次添加此代码! 莱利! 您实际上可以取消注册媒体元素.js在函数文件中,并注册修改的媒体元素.js这样,您就不必在每次更新时都对其进行修复。 以下是执行此操作的基本代码: function your_theme_load_js() {wp_deregister_script(\"mediaelement\");wp_enqueue_script(\"mediaelement\",get_template_directory_uri() .\"/js/mediaelement-and-player-min.js\", array( \"jquery\" ), \"\" ,true);}add_action(\"wp_enqueue_scripts\", \"your_theme_load_load_js\"); 您需要将修改后的媒体元素.js在主题的/js/文件夹中目录。 我注意到Twenty13主题没有相同的问题,我正在调查主题开发人员为避免此问题所做的工作。 太好了,感谢您分享Kevin! 这里是技巧之前的样子: http://img69.imageshack.us/img69/644/u6sr.png 后面: http://img850.imageshack.us/img850/1091/7oqz.png 看起来在音量之后条形图还在继续… 这很大程度上取决于特定的宽度。有时,最后一个媒体播放器控件下降到其他控件之下;有时候不是,只是取决于天气宽度。它这是一个已知的问题媒体元素.js两年多前首次报道最近。那里好像是最近的补丁不过。 https://github.com/johndyer/mediaelement/issues/341 https://github.com/johndyer/mediaelement/issues/697 https://github.com/johndyer/mediaelement/issues/899我一直致力于一个纯粹的CSS修复程序,它根本不是很简单,但是,其思想是有意清除最后一个控件,然后重新定位是的。因为它有时在其他时候(取决于宽度),最好是复制所有宽度的行为,并故意清除其他控件下的行为,然后将其移回我们想要的位置。 这里是CSS: ***/* Fix for last item dropping below the controls. */.mejs-controls > div:last-of-type {position: relative;clear: both;float: right;top:-31px;} *-31可能需要调整。我正在使用自定义媒体播放器外观,现在还没有用默认值进行测试。 您可能还需要更多具体。如果就是这样,试试这样: /* Fix for last item dropping below the controls. */.mejs-container .mejs-controls > div:last-of-type {position: relative;clear: both;float: right;top:-31px;} 好把戏,谢谢!

admin_action_{$_REQUEST[‘action’]}

do_action( "admin_action_{$_REQUEST[‘action’]}" )动作钩子::在发送“Action”请求变量时激发。Action Hook: Fires when an ‘action’ request variable is sent.目录锚点:#说明#源码说明(Description)钩子名称的动态部分$_REQUEST['action']引用从GET或POST请求派生的操作。源码(Source)更新版本源码位置使用被使用2.6.0 wp-admin/admin.php:...

日期:2020-09-02 17:44:16 浏览:1173

admin_footer-{$GLOBALS[‘hook_suffix’]}

do_action( "admin_footer-{$GLOBALS[‘hook_suffix’]}", string $hook_suffix )操作挂钩:在默认页脚脚本之后打印脚本或数据。Action Hook: Print scripts or data after the default footer scripts.目录锚点:#说明#参数#源码说明(Description)钩子名的动态部分,$GLOBALS['hook_suffix']引用当前页的全局钩子后缀。参数(Parameters)参数类...

日期:2020-09-02 17:44:20 浏览:1071

customize_save_{$this->id_data[‘base’]}

do_action( "customize_save_{$this->id_data[‘base’]}", WP_Customize_Setting $this )动作钩子::在调用WP_Customize_Setting::save()方法时激发。Action Hook: Fires when the WP_Customize_Setting::save() method is called.目录锚点:#说明#参数#源码说明(Description)钩子名称的动态部分,$this->id_data...

日期:2020-08-15 15:47:24 浏览:808

customize_value_{$this->id_data[‘base’]}

apply_filters( "customize_value_{$this->id_data[‘base’]}", mixed $default )过滤器::过滤未作为主题模式或选项处理的自定义设置值。Filter Hook: Filter a Customize setting value not handled as a theme_mod or option.目录锚点:#说明#参数#源码说明(Description)钩子名称的动态部分,$this->id_date['base'],指的是设置...

日期:2020-08-15 15:47:24 浏览:900

get_comment_author_url

过滤钩子:过滤评论作者的URL。Filter Hook: Filters the comment author’s URL.目录锚点:#源码源码(Source)更新版本源码位置使用被使用 wp-includes/comment-template.php:32610...

日期:2020-08-10 23:06:14 浏览:931

network_admin_edit_{$_GET[‘action’]}

do_action( "network_admin_edit_{$_GET[‘action’]}" )操作挂钩:启动请求的处理程序操作。Action Hook: Fires the requested handler action.目录锚点:#说明#源码说明(Description)钩子名称的动态部分$u GET['action']引用请求的操作的名称。源码(Source)更新版本源码位置使用被使用3.1.0 wp-admin/network/edit.php:3600...

日期:2020-08-02 09:56:09 浏览:878

network_sites_updated_message_{$_GET[‘updated’]}

apply_filters( "network_sites_updated_message_{$_GET[‘updated’]}", string $msg )筛选器挂钩:在网络管理中筛选特定的非默认站点更新消息。Filter Hook: Filters a specific, non-default site-updated message in the Network admin.目录锚点:#说明#参数#源码说明(Description)钩子名称的动态部分$_GET['updated']引用了非默认的...

日期:2020-08-02 09:56:03 浏览:865

pre_wp_is_site_initialized

过滤器::过滤在访问数据库之前是否初始化站点的检查。Filter Hook: Filters the check for whether a site is initialized before the database is accessed.目录锚点:#源码源码(Source)更新版本源码位置使用被使用 wp-includes/ms-site.php:93910...

日期:2020-07-29 10:15:38 浏览:834

WordPress 的SEO 教学:如何在网站中加入关键字(Meta Keywords)与Meta 描述(Meta Description)?

你想在WordPress 中添加关键字和meta 描述吗?关键字和meta 描述使你能够提高网站的SEO。在本文中,我们将向你展示如何在WordPress 中正确添加关键字和meta 描述。为什么要在WordPress 中添加关键字和Meta 描述?关键字和说明让搜寻引擎更了解您的帖子和页面的内容。关键词是人们寻找您发布的内容时,可能会搜索的重要词语或片语。而Meta Description则是对你的页面和文章的简要描述。如果你想要了解更多关于中继标签的资讯,可以参考Google的说明。Meta 关键字和描...

日期:2020-10-03 21:18:25 浏览:1734

谷歌的SEO是什么

SEO (Search Engine Optimization)中文是搜寻引擎最佳化,意思近于「关键字自然排序」、「网站排名优化」。简言之,SEO是以搜索引擎(如Google、Bing)为曝光媒体的行销手法。例如搜寻「wordpress教学」,会看到本站的「WordPress教学:12个课程…」排行Google第一:关键字:wordpress教学、wordpress课程…若搜寻「网站架设」,则会看到另一个网页排名第1:关键字:网站架设、架站…以上两个网页,每月从搜寻引擎导入自然流量,达2万4千:每月「有机搜...

日期:2020-10-30 17:23:57 浏览:1309