• 动态增加属性



    <html>

    <script>

    functionck()

    {

    vartruename;

    document.form1.sele.options[0].truename="11111";

    }

    functionck1()

    {

    alert(document.form1.sele.options[0].truename);

    }

    functionck2()

    {

    document.form1.sele.value="3";

    alert(document.form1.sele.value);

    alert(document.form1.sele.options[document.form1.sele.selectedIndex].value);

    }

    </script>

    <body>

    <formname=form1>

    <selectname=sele>

    <optionvalue=1>1</option>

    <optionvalue=2>2</option>

    <optionvalue=3>3</option>

    </select>

    <inputtype=button onclick="ck();" value="给select增加属性">

    <inputtype=button onclick="ck1();" value="检查;">

    <inputtype=button onclick="ck2();" value="检查select的值;">

    </form>

    <script>

    //ck();

    </script>

    </body>

    </html>

    right:-�t>�L �ٳg=EN-US><br><ahref="javascript:alert('X:'+block.xpos)">横向位置</a>

    <br><ahref="javascript:alert('Y:'+block.ypos)">竖向位置</a>

    <br><ahref="javascript:showObject(block)">显示</a>

    <br><ahref="javascript:hideObject(block)">隐藏</a>

    <br>移动moveto:

    <br><ahref="javascript:moveto(block,100,200)">(100,200)</a>

    <br><ahref="javascript:moveto(block,200,260)">(200,260)</a>

    <br><ahref="javascript:moveto(block,300,340)">(300,340)</a>

    <br>相对移动moveby:

    <br><ahref="javascript:moveby(block,10,0)">(10,0)</a>

    <br><ahref="javascript:moveby(block,-10,0)">(-10,0)</a>

    <br><ahref="javascript:moveby(block,0,10)">(0,10)</a>

    <br><ahref="javascript:moveby(block,0,-10)">(0,-10)</a>

    <divid="blockdiv"style="position:absolute;left:100;top:200;30;visibility:visible;">

    sktjyerlwo;ekrw;

    <IMG SRC="1.jpg"border=0>

    </div>

    </body>

    </html>

  • 相关阅读:
    图论——拓扑排序
    BZOJ 2882 & 后缀数组的傻逼实现
    BZOJ 2626 & KDtree
    Colorado Potato Beetle(CF的某道) & 鬼畜宽搜
    Prime & 反素数plus
    BZOJ 2049 & LCT又一模板
    BZOJ2002 & LCT模板(分块不会搞)
    BZOJ2190 & 欧拉函数
    BZOJ 1053 & 反素数
    POJ2774 & 后缀数组模板题
  • 原文地址:https://www.cnblogs.com/liaoshiyong/p/3150911.html
Copyright © 2020-2023  润新知