问题描述
<!DOCTYPEhtml><html><head><script></script></head><buttontype="button"onclick="myFunction101()">C</button><buttontype="button"onclick="myFunction102()">C#</button><buttontype="button"onclick="myFunction103()">D</button><buttontype="button"onclick="myFunction104()">D#</button><buttontype="button"onclick="myFunction105()">E</button><buttontype="button"onclick="myFunction106()">F</button><buttontype="button"onclick="myFunction107()">F#</button><buttontype="button"onclick="myFunction108()">G</button><buttontype="button"onclick="myFunction109()">G#</button><buttontype="button"onclick="myFunction110()">A</button><buttontype="button"onclick="myFunction111()">A#</button><buttontype="button"onclick="myFunction112()">B</button><body>c=1c#=2d=3D#=4e=5f=6f#=7g=8g#=9a=10a#=11b=12varx=1<pid="chord">cdef</p><h1>我是歌词.....</h1><pid="chord">efgh</p><h1>我是歌词.................</h1></body></html>想请问,如何把下面pid=chord里的资料,加入x,比如说,现在x等于1所以chord是cdef当x变成2的时候chord是c#d#ff#这里有样本http://www.ijita.com/tab/6826.html
解决方案
解决方案二:
写个循环,加上判断条件