百度空间 | 百度首页 
 
文章列表
 
您正在查看 "css&js" 分类下的文章

2008年12月19日 星期五 16:54

[原创]用JS或jQuery访问页面内的iframe,兼容IE/FF


假设有两个页面,在相同域下.

index.html 文件内含有一个iframe:

XML/HTML代码
类别:css&js | 评论(0) | 浏览()
 
2008年12月03日 星期三 11:33

官方网站:http://bassistance.de/jquery-plugins/jquery-plugin-validation/

修复了一些bug,并增加了一些特性,更加好用了

1.5
---
* Improved basic demo, validating confirm-password field after password changed
* Fixed basic validation to pass the untrimmed input value as the first parameter to validation methods, changed required accordingly; breaks existing custom method that rely on the t

类别:css&js | 评论(1) | 浏览()
 
2008年11月14日 星期五 00:14

可以到这个网站:http://odyniec.net/projects/imgareaselect/

另外附上一个例子:http://gravatar.com ,他的图像裁剪使用了这个插件,效果很不错!

他是这么用的:

<script type="text/javascript">
   function preview (img, selection) {
    grav.cropper = { img: img, selection: selection }
    preview1(img, selection);

类别:css&js | 评论(1) | 浏览()
 
2008年11月08日 星期六 10:54

What we'll do here is use css border property for outer image border and we'll fake the inner border using combination of background and padding properties.

double border for images

First we add a border property to the image and set the values

img{
 border:2px solid #72a143;
}

If we set the padding to 1px and add a yellow background,

img{
 border:2px solid #72a143;
 paddi
类别:css&js | 评论(0) | 浏览()
 
2008年11月08日 星期六 09:24

image

This tutorial is aimed at controlling the size of the thumbnails appearing on your page. Sometimes we don't have enough space to spare to fit in large thumbnails and yet we would like to avoid small and barely recognizable images. Using this trick we limit the default dimensions of the thumb, and show it in full size when user mouse-overs it.

类别:css&js | 评论(0) | 浏览()
 
2008年10月30日 星期四 12:39

<style>
body{
background-color:white;
font-size:12px;
font-family:Arial, Helvetica, sans-serif;
margin:0px;
padding:0px;
color:white;
}
ul,li{
margin:0px;
padding:0px;
}
li{
display:inline;
list-style:none;
list-style-position:outside;
text-align:center;
font-weight:bold;
float:left;
}
a:link{
color:#336601;
text-decoration:none;
float:left;
width:100px;
padding:3px 5px 0px 5px;

类别:css&js | 评论(0) | 浏览()
 
2008年10月30日 星期四 11:32

<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<style type="text/css">
<!--
a {
float:left;
margin:5px 1px 0 1px;
width:20px;
height:20px;
color:#999;
font:12px/20px 宋体;
text

类别:css&js | 评论(0) | 浏览()
 
2008年10月16日 星期四 15:30

程序开发中需要用到消息提示,一般我们使用alert(),confirm等,但这些方法在用户体验上明显有不足,如:内容区域不能使用HTMl,不能设置遮罩,不能自动关闭(在alert时,用户看到了,却还必须点击确定才能关闭)所以开发了一个新的对话框系统:

更多图片:


最普通的消息框(点击查看原图)

类别:css&js | 评论(2) | 浏览()
 
2008年10月15日 星期三 16:58

原文来自:http://www.zishu.cn/blogview.asp?logID=726

这是刚才一个网友发来的代码,在IE6中不能正常显示,让我帮改一下!改完后,感觉这段代码不错,就贴出来和大家分享一下!

重点只有一个,就是下边的这行代码!

类别:css&js | 评论(0) | 浏览()
 
2008年10月15日 星期三 16:43
最近很少写CSS了,以后也可能写的会很少了,所以还是想把自已的一些经验能和大家分享一下,希望能给大家一些帮助!

这篇文章主要写的提高网页在客户端浏览器的渲染速度的CSS部分,暂时总结了10条。

1、*{} #zishu *{} 尽量避开

由于不同浏览器对HTML标签的解释有差异,所以最终的网页效果在不同的浏览器中可能是不一样的,为了消除这方面的风险,设计者通常会在CSS的一个始就把所有标签的默认属性全部去除,以达到所有签标属性值都统一的效果。所以就有了*通配符。*会遍历所有的标签;
类别:css&js | 评论(1) | 浏览()
 
2008年09月27日 星期六 19:21

<style>
.box {
/*非IE的主流浏览器识别的垂直居中的方法*/
display: table-cell;
vertical-align:middle;

/*设置水平居中*/
text-align:center;

/* 针对IE的Hack */
*display: block;
*font-size: 175px;/*约为高度的0.873,200*0.873 约为175*/
*font-family:Arial;/*防止非utf-8引起的hack失效问题,如gbk编码*/

width:200px;
height:200px;
border: 1px solid #eee;
}
.box img {
/*设置图片垂直居中*/
vertical-align:middle;
}

类别:css&js | 评论(0) | 浏览()
 
2008年04月23日 星期三 16:38

转载自:http://www.33lab.cn/demo/200803/ideas_from_an_interview_question.htm



#wrapper {
 border:1px solid #ccc;
 width:400px;
 height:200px;
 text-align:center;
 line-height:200px;  // Vertical Align For IE7 & Firefox
 
类别:css&js | 评论(2) | 浏览()
 
2008年04月23日 星期三 16:33
在XHTML中定义ID时都用得上,主要是方便CSS定义样式时能一眼看穿。所以,CSS命名仅作参考。

(1)页面结构类

容器: container
页头:header
内容:content/container
页面主体:main
页尾:footer
导航:nav
侧栏:sidebar
栏目:column
页面外围控制整体布局宽度:wrapper

(2)导航类

导航:nav
主导航:mainnav
子导航:subnav
顶导航:topnav
边导航:sidebar
类别:css&js | 评论(0) | 浏览()
 
     
 
 
文章分类
 
 
 
 
 
Asp(15)
 
 
Php(17)
 
css&js(13)
 
 
 
     
 
文章存档
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
     
 
最新文章评论
   

请给我发一份jsp的和php的吧,谢谢了。chengtongyan@163.com
 
 
 

www.jaycn.org 好米!!!
 
 
     


©2009 Baidu