代码之家  ›  专栏  ›  技术社区  ›  Sam Johannes Rudolph

我的输入类型=“提交”未显示?

  •  4
  • Sam Johannes Rudolph  · 技术社区  · 14 年前

    为什么我的 <input type="submit" 不显示在 http://ballpointradio.com/new/page_edit.php

    这真让我困惑!!是我的jQuery吗?我很确定这不是。。。

    2 回复  |  直到 14 年前
        1
  •  2
  •   Mike Sherov    14 年前
    $("#page_selection").change(function(){
        $("#" + this.value).show().siblings().hide();
    });
    $("page_selection").change();
    

    加载时,此代码执行以下操作:

    $("#edit1").show().siblings().hide();
    

    考虑到 <input type="submit"> $('edit1') ,它藏起来了!

    .siblings() .siblings('textarea') 所以它只隐藏同样是文本区域的兄弟姐妹!

        2
  •  4
  •   Lauri Lehtinen    14 年前

    是的 style="display: none" 设置。

    不过,我没能马上找出原因。

    我不是jquery的人,但你可以看看 hide()

    $("#" + this.value).show().siblings().hide();