我在Post Grid的自定义字段中添加了一个类(format-date),但我似乎无法将任何JS应用到它。
<div class="vc_gitem-post-meta-field-_EventStartDate format-date vc_gitem-align-left"> 2015-10-08 07:30:00</div>
简单的jQuery测试:
$('.format-date').addClass('test')
代码在页脚中,我已尝试$(window).load(function() $(document).ready(function()
。 Fire Bug中没有JS错误。
我怀疑它是由于应用于帖子的加载动画造成的。如何在加载后调用我的JS?
答案 0 :(得分:7)
这有效:
$(document).ajaxStop(function() {
// your code here
});