开发者

document.getElementById not working at FBJS

开发者 https://www.devze.com 2022-12-26 02:51 出处:网络
I\'m developing apps at Facebook using FBML and FBJS. When I tried to use document.getElementById to readtag, it did 开发者_如何学Pythonnot reply the correct value.

I'm developing apps at Facebook using FBML and FBJS. When I tried to use document.getElementById to read tag, it did 开发者_如何学Pythonnot reply the correct value. Can we really use this command on FBML to get data?

Here is detail of my code :

<input type="hidden" value="123" id="number"/>
<a href="#" onclick="new Dialog().showMessage('Dialog', document.getElementById('number').value);return false"/>


I found the answer. We can access the value by :

<input type="hidden" value="123" id="number"/> <a href="#" onclick="new Dialog().showMessage('Dialog', document.getElementById('number').getValue());return false"/>

0

精彩评论

暂无评论...
验证码 换一张
取 消