0
我尝试修改UserVoice的表单。修改Uservoice Textarea占位符
这里控件的HTML代码:
<article class="widget large-widget">
<div class="viewport vertical-layout" data-viewport="" style="height: 325px;">
<section class="pane instant-answers-omnibox-input-pane" style="display: block;">
....
<form>
<div class="pane-body" style="top: 48px; bottom: 119px; height: 158px;">
<div data-stretch-vertical="" style="height: 158px;">
<textarea
placeholder="Give feedback or ask for help…"
data-autofocus=""
data-search-input=""
class="textbox textarea full-width full-height">
</textarea>
</div>
</div>
....
</form>
</section>
</div>
</article>
我想修改textarea的占位符,但是这是不可能的访问。
例:
jQuery('textarea').attr('class') -> <nothing> (otherwise: 'textbox')
感谢
是的,我测试这个,但它不起作用。在我的例子中,它只是为了捕捉对象而没有任何东西。 uservoice对象不存在我的脚本... – madvic 2014-11-06 08:12:18
我更新了代码...给该textarea一个ID,然后选择该ID。 console.log($(“#switch”));会将该对象转储到浏览器的控制台。 – Solrac 2014-11-08 00:44:18
是的但是这个textarea是由uservoice代码创建的,没有给出ID! – madvic 2014-11-10 15:25:14