我正在努力创造this button 对于我网站上的自定义字段
<button type="button"
onclick="document.getElementById(\'demo\').innerHTML = Date()">
Click me to display Date and Time.</button>
问题是,当我点击按钮显示wordpress网站上自定义字段的输入时。我把名字写在字段上而不是\'
Date()
\' 还有我的部门id,但什么都没发生。问题是我不知道我应该写什么代码才能做到这一点。
更新(基于brownian):因此,这是一个信息图表,可以更好地解释我需要什么:
