zoukankan      html  css  js  c++  java
  • 遇到细小知识点记录

      1、background-color:transparent;就是把背景色设置为透明

      2、target的值

     target="_blank":在新窗口中浏览新的页面。
    target="_self":在同一个窗口打开新的页面。
    target="_parent":在父窗口中打开新的页面。(页面中使用框架才有用)
    target="_top" :以整个浏览器作为窗口显示新页面。(突破了页面框架的限制)
    3、setAtrribute('value','rs');

    getAtrribute('id');
    removeAtrribute();
    4、跳转
     location.href="test.html?id="+ sid.value + " ";
    5、 var oul=document.getElementById('uli');
    var lis=oul.getElementsByTagName('li');
    lis[i].className=='sss'
    6、window.close在FF中只能关闭以脚本打开的窗口
    7、confirm:询问对话框,利用对话框返回的值 (true 或者 false);
    alert:提醒的对话框;
    prompt: var name=prompt("请输入您的名字","");//将输入的内容赋给变量 name ,
           prompt有两个参数,前面是提示的话,后面是当对话框出来后,在对话框里的默认值
    8、子级div margin-top影响父级,为父级加上overflow:hidden;
    9、div块居中方法:
    #wrap{
            400px;height:500px;border:1px solid yellow;margin:auto;background-color: #ccc;
        }
          #div1{100px;height:100px;background-color: red; position:relative;top:50%;left:50%;margin-top:-50px;margin-left: -50px; }
    
    
  • 相关阅读:
    Eclipse添加注释简介
    git config配置文件
    ndk开发教程以及问题解决方案
    PATH路径出错导致任何命令都找不到解决方法
    git详细教程
    ssh相关操作
    ORM SQLAlchemy 表于表的关系
    SQLAlchemy 使用
    ORM SQLAlchemy 简介
    LUA基础
  • 原文地址:https://www.cnblogs.com/a67cm/p/4541966.html
Copyright © 2011-2022 走看看