网上有一个例子其中hack IE代码有一个display:block
测试过程中他没有用处
1.图片高度问题 
图片的高度奇偶性会影响真正居中,上下相差1px.不过在实际应用中没啥影响。
当图片高度为偶数时 *font-size:175px
当图片高度为奇数时 *font-size:176px


  IE5.5 IE6.0 IE7.0 IE8.0 beta2 Firefox3.03  
  √测试通过




[Last Modified By hoosin, at 2008-11-01 11:45:13]
posted @ 2009-04-23 13:33 Fernando 阅读(284) 评论(0) 编辑

文本的排版依据语言的不同会有一些格式上的要求,比如简体中文中类似逗号、分号等标点符号不会出现在一行的开头,对于英文来讲就是一个完整单词不会 在两行显示,浏览器会依据类似这样的原则来显示文本。但是由于网页有宽度限制的,连续的超长的字母、数字或标点符号超出其所在区域宽度的限制而导致影响页 面视觉,如例1所示。这个问题在显示用户输入信息时尤为突出,这里就是要说如何解决这个问题。

CSS3草案中,对文本的处理新增了两个新属性word-wrapword-break来解决这个问题:

  1. {word-wrap:break-word;} :依照亚洲语言和非亚洲语言的文本规则,允许在字内换行,且允许非亚洲语言文本行的任意字内断开
  2. {word-break:break-all;} : 内容将在边界内换行,如需要则词内换行(word-break)也行发生

下面是常见浏览器的支持情况:

IE6/7[1] Firefox2/3[2] Opera3+ Safari9.5+/Chrome
{word-wrap:break-word;} td元素需设置其宽度
例4例5
不支持 不支持 不支持td元素
例4例5
{word-break:break-all;} 不支持连续的符号
例3
不支持 不支持 支持
  • [1] 在MSDN的CSS Compatibility and Internet Explorer中可以看出,IE8会像IE6和IE7一样支持word-wrap和word-break这两个属性,但我在IE8beta2上测试来看却不支持这两项,由于IE8还处于beta阶段,且我相信IE8最终会支持的,所以在页头声明<meta content="IE=7" http-equiv="X-UA-Compatible" />使IE8按照IE7来解释页面是一个不错的办法。
  • [2] Firefox3.1将会支持word-wrap属性

由于{word-break:break-all;}导致英文和数字可读性严重下降且无法使连续符号换行,所以{word-wrap:break-word;}是一个相对较好的选择。

但面对浏览器的如此糟糕支持,所以不能不借助JavaScript来解决这个问题,即当浏览器不支持CSS解决方案时,在连续字符串的适当位置插入&#8203;字符(当然还可以用<wbr />和&shy;,这三个字符在浏览器中的支持情况请看ppk的《The wbr tag》),这些字符写在浏览器中不会显示,却使长字符串换行。具体实现代码如下:

function fnBreakWordAll(o){
var o = o || {},
iWord = o.word || 13,
iRe = o.re || '[a-zA-Z0-9]',
bAll = o.all || false,
sClassName = o.className || 'word-break-all',
aEls = o.els || (function(){
var aEls = [],
aAllEls = document.getElementsByTagName('*'),
re = new RegExp('(?:^|\\s+)' + sClassName + '(?:\\s+|$)');
for(var i =0,iLen = aAllEls.length; i < iLen ; ++i){
if(re.test(aAllEls[i].className)){
aEls[aEls.length] = aAllEls[i];
}
}
return aEls;
})() || [],
fnBreakWord = function(oEl){
// 基于http://www.hedgerwow.com/360/dhtml/css-word-break.html修改
if(!oEl || oEl.nodeType !== 1){
return false;
}else if(oEl.currentStyle && typeof oEl.currentStyle.wordWrap==='string'){
breakWord = function(oEl){
oEl.runtimeStyle.wordWrap = 'break-word';
return true;
}
return breakWord(oEl);
}else if(document.createTreeWalker){
var trim = function (str) {
str = str.replace(/^\s\s*/, '');
var ws = /\s/,
i = str.length;
while (ws.test(str.charAt(--i)));
return str.slice(0, i + 1);
}
breakWord = function(oEl){
var dWalker=document.createTreeWalker(oEl,NodeFilter.SHOW_TEXT,null,false);
var node,s,c = String.fromCharCode('8203'),
//re = /([a-zA-Z0-9]{0,13})/;
re = new RegExp('('+ iRe +'{0,' + iWord + '})');
while (dWalker.nextNode()){
node = dWalker.currentNode;
s = trim(node.nodeValue).split(re).join(c);
node.nodeValue = s;
}
return true;
}
return breakWord(oEl);
}
};
for(var i=0,n=aEls.length; i<n; ++i){
var sUa = navigator.userAgent,
sTn = aEls[i].tagName.toLowerCase() ;
if((/Opera/).test(sUa) || (/Firefox/).test(sUa) || ((/KHTML/).test(sUa) &&
(sTn === 'td' || sTn === 'th')) || bAll){
fnBreakWord(aEls[i]);
}
}
}

具体应用请看演示实例

fnWordBreakAll函数提供一些定制参数,使用方法和参数含义如下:

fnWordBreakAll({word:15,re:'[\\w]',all:true});
参数 说明
word 正整数,默认是13 在这个字数内的单词不会被插入\u8203,印象中超过13个字母的单词不多,这可以保证绝大部分单词不会被打碎
re 正则表达式,默认[a-zA-Z0-9] 单词的正则表达式,用以确定一个单词是哪些字符组成,注意\的转义
all 布尔值,默认false 确定是否在所有的浏览器中执行,默认在Opera和Firefox,以及当class应用在th或td的Safari上执行,这个主要用在.word-break-all没有定义时,会对IE加上样式
className 合法class名,默认word-break-all 执行函数的元素对应属性名

这个函数的核心部分修改自Hedger Wang 整理了一个JavaScript解决方案《Cross Browser Word Breaker》,其利用document.createTreeWalker和 split方法给非IE浏览器的每个字符间加入了&#8203;,它用在纯中文文本基本上没有什么问题,但是如果你仔细观察他给出的例子就会发现 文本中有英文或数字时,虽然解决了换行问题,但是使文本难以阅读,且增大了字符间的间距,所以我在此基础上做了上面的改进。

posted @ 2009-03-24 10:22 Fernando 阅读(189) 评论(0) 编辑


1、这涉及到 CSS 简写的基本原则。在一条简写规则当中的缺省项会自动被“默认初始值”代替。因此,声明 {border: 0;} 完全等价于声明 {border: 0 none 元素颜色},而声明 {border: none;} 完全等价于声明 {border: medium none 元素颜色}。
我相信大家在使用 background 和 font 的简写方式时对此已经有过深刻的体会。

2、由上面一条可以得出,即使你在简写属性当中省略某个值,但元素还是会[b]隐式地[/b]得到“默认初始值”的[b]声明[/b],注意,是[b]声明[/b]。浏览器并不会因为你在简写中省略了某个值而放弃存储它。
这个问题解释起来需要花费点口舌,有机会再写。

posted @ 2009-03-20 12:49 Fernando 阅读(118) 评论(0) 编辑
  1. 关闭fiddler;
  2. 打开IE,设置代理,访问需要调试的网页;
  3. 关闭IE;
  4. 打开FIREFOX,设置通过fiddler调试的代理;
  5. 直接打开需要调试的网页即可;
posted @ 2009-03-17 11:00 Fernando 阅读(551) 评论(0) 编辑

Dealing with browser inconsistencies often makes up a majority of the work for a web designer. Sometimes there is no reasonable way to accomplish a desired layout in all major web browsers without the use of some special exception rules for certain layout engines. Hacks necessarily lead to potential complications and should be avoided whenever possible, but when the circumstances require hacks to be used, it’s best to know what your options are and weigh the consequences appropriately. The purpose of this article is to describe some of the CSS hacks, also called CSS filters, with the least significant potential consequences.

Conditional comments

UpDue to its relatively poor level of standards support, Internet Explorer tends to be the subject of most CSS hacks. Luckily, as of version 5, it deliberately supports a rather safe-to-use hack called “conditional comments”. Conditional comments are specially constructed HTML comments that Internet Explorer on Windows may treat differently from other browsers, optionally based on IE’s version number. They can cause Internet Explorer to ignore the markup between comments or to include part of a comment as if it was regular markup. Conditional comments apply specifically to browsers using Internet Explorer’s Trident layout engine, meaning IE-based browsers like Maxthon and Avant handle them like Internet Explorer does while browsers using other layout engines see them simply as regular comments. Internet Explorer on the Mac uses a different layout engine and doesn’t support conditional comments.

The most beneficial aspect of conditional comments is that you are not relying on browser bugs when using them. When you use CSS hacks that rely on browser bugs, you run into the possibility of those bugs being fixed at an unwanted time or other browsers showing the same bugs. Conditional comments only work in browsers that specifically support them and claim to be based on Internet Explorer, which in this case all known browsers are honest about.

There are two forms of conditional comments: positive and negative. A positive conditional comment will expose the included markup only to web browsers that match the condition (meaning only the selected versions of Internet Explorer). A negative conditional comment will expose the markup only to web browsers that don’t match the condition (meaning all non-IE web browsers and any versions of IE that the condition didn’t match). Note that, since versions of IE older than IE 5 don’t support conditional comments, you may get unexpected results in those browsers.

Syntax

UpThe syntax for conditional comments is as follows:

Positive
<!--[if condition]> HTML <![endif]–>
Negative
<!--[if !condition]><![IGNORE[--><![IGNORE[]]> HTML <!--<![endif]–>

condition is one of the following:

IE
Any version of IE
lt IE version
Versions less than version
lte IE version
Versions less than or equal to version
IE version
Only version version
gte IE version
Versions greater than or equal to version
gt IE version
Versions greater than version

version is the version of Internet Explorer, typically 5, 5.5, 6, or 7

HTML is the HTML to be included if the condition does or doesn’t match, depending on the type of conditional comment. When included, the HTML is placed right where the conditional comment is in the source.

For negative conditions, <![IGNORE[--><![IGNORE[]]> can be replaced with --> if the condition is simply IE. The longer version is only needed when Internet Explorer might parse the contents.

The <![IGNORE[ ... ]]> directive is not available in XML, so it is illegal to use it in XHTML. A solution would be to split it up into two special conditional comments: <!--[if !condition]> XHTML <![endif]–> <!--[if !IE]>–> XHTML <!--<![endif]–> where XHTML is the same both places. Note that Internet Explorer 7 and below don’t yet recognize XHTML as a form of XML, so this is merely forward-looking.

To minimize the chance of your site breaking in future versions of Internet Explorer, read Preparing your site for IE.next.

Fixing stand-alone versions of Internet Explorer

UpInternet Explorer was not designed to allow multiple versions to be installed at once, and Microsoft doesn’t officially support any such configurations. If you use one of the hacked third party packages that attempts to do this, you will experience problems with version-specific conditional comments, among other things. This is because the different stand-alone copies still rely on a common centralized registry for certain data, including version information.

Although there is no simple way to cut through all of the issues with stand-alone versions of Internet Explorer, it is possible to force them to look elsewhere for their version information, thus fixing this issue with conditional comments. The trick is to remove the normal centralized version indicator. To do this, first open up regedit.exe from the “Run…” dialog. Navigate to HKEY_LOCAL_MACHINE/Software/Microsoft/Internet Explorer/Version Vector/ (If HKEY_LOCAL_MACHINE doesn’t exist, try HKLM instead). In the right pane, you should see a row with a Name value of IE. Rename this by clicking on it and changing it to zIE (or anything unique and different). Restart Internet Explorer to see the effects. Now when it looks for the IE key for its version information, the key will be missing and it will be forced to determine the correct version number from its own module.

Stand-alone versions of Internet Explorer have a number of other issues, and it therefore may be better to instead use a separate virtual machine for each version of Internet Explorer to ensure that what you see is what your users will see. I recommend VMware Server, which is completely free of charge and fairly easy to set up.

Conditional comments as a CSS hack

UpConditional comments can be used as a CSS hack by including links to stylesheets based on the layout engine. Here is an example of how stylesheets can be separated in this way:

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html lang="en">
	<head>
		<title>Test</title>
		<link href="all_browsers.css" rel="stylesheet" type="text/css">
		<!--[if IE]> <link href="ie_only.css" rel="stylesheet" type="text/css"> <![endif]-->
		<!--[if lt IE 7]> <link href="ie_6_and_below.css" rel="stylesheet" type="text/css"> <![endif]-->
		<!--[if !lt IE 7]><![IGNORE[--><![IGNORE[]]> <link href="recent.css" rel="stylesheet" type="text/css"> <!--<![endif]-->
		<!--[if !IE]>--> <link href="not_ie.css" rel="stylesheet" type="text/css"> <!--<![endif]-->
	</head>
	<body>
		<p>Test</p>
	</body>
</html>

In the above example, all_browsers.css applies to all browsers, ie_only.css only applies to all versions of Internet Explorer, ie_6_and_below.css applies to all versions of Internet Explorer below IE 7, recent.css applies to all browsers except IE versions below 7, and not_ie.css applies to all non-IE browsers.

See also: MSDN: About Conditional Comments

In-CSS hacks

UpOne of the drawbacks of conditional comments is that they require changes to the HTML source. Unfortunately, there is no equivalent to conditional comments in CSS. Instead, if you must use in-CSS hacks, you must use some other much less reliable techniques, often involving the exploitation of browser bugs.

Easy selectors

UpMost in-CSS hacks deal with selector bugs. The following is a list of browser version ranges and the beginnings of selectors that are known to select elements in them. Note that because these hacks rely on browser bugs or missing features, results may vary in some lesser-known or future browsers. All of these selectors use valid CSS.

IE 6 and below
* html {}
IE 7 and below
*:first-child+html {} * html {}
IE 7 only
*:first-child+html {}
IE 7 and modern browsers only
html>body {}
Modern browsers only (not IE 7)
html>/**/body {}
Recent Opera versions 9 and below
html:first-child {}

Note that the hack for IE 7 and below is actually two separate selectors: one for IE 7 and one for IE 6 and below. The rest of the desired selector must be added to both parts of the hack. The two parts cannot be combined with a comma, because IE 6 and below will fail to correctly parse the selector and won’t be targetted.

Some of these selectors require that the document has a doctype but no processing instructions (including XML declarations). This is the ideal setup to prevent IE 6 from going into quirks mode anyway.

The above selectors will select either the html or body element. This should be used as the start of your full selector. For example, if your desired selector is #foo .bar and you want it to apply only to IE 7, your resulting selector will be *:first-child+html #foo .bar.

Warning: Due to the nature of the Opera-specific selector and Internet Explorer 7’s incorrect handling of :first-child, it is very possible that the html:first-child selector may also select in a future version of Internet Explorer, so be careful when using it. This selector also relies on a bug, so it may be fixed in a future version of Opera. This page also describes an alternative method that is more of an issue to implement but may be somewhat more dependable considering the likely priorities of bug fixing.

Minimized attribute selectors

UpThese hacks are based on differences in handling of attributes in minimized form. If a tag is written <input disabled>, input[disabled="disabled"] {} should select it. However, most browsers get this wrong and in different ways.

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html lang="en">
	<head>
		<title>Test</title>
	</head>
	<body>
		<input type="hidden" disabled id="attrhack">
		<p>Test</p>
	</body>
</html>

For the above markup, here are the selectors various browsers recognize to select the p element:

#attrhack[disabled=""]+p {}
Firefox 1.5 and below, possibly future versions
Safari 2.0 and below, possibly future versions
Konqueror 3.5 and below, possibly future versions
#attrhack[disabled="true"]+p {}
Opera 9 and below, possibly future versions

Note that neither of these selects Internet Explorer 7. Although it supports attribute selectors and adjacent sibling combinators, it doesn’t seem to recognize a string value for attributes in minimized form.

Notice: Minimized attribute form is allowed in HTML but not in XHTML. This hack will not work in XHTML documents.

!important

UpInternet Explorer 6 and below had a problem with the !important identifier that caused it to be ignored if another declaration of the same property appeared later in the same style declaration block. This can be used to feed Internet Explorer 6 and below special property values that are ignored by other browsers. Internet Explorer 7 fixed this issue.

Here is an example of this technique in use:

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html lang="en">
	<head>
		<title>Test</title>
		<style type="text/css">
			p
			{
				background: green !important; /* Major browsers other than IE 6 and below respect the importance immediately */
				background: red; /* IE 6 and below use this value instead, even though the above was marked as important */
			}
		</style>
	</head>
	<body class="page-body">
		<p>Test</p>
	</body>
</html>

@import “non-ie.css” all;

UpInternet Explorer 7 and below don’t support media selectors on @import rules, instead ignoring the entire rule when they are present. Therefore, you can create an entire stylesheet for non-IE browsers and import it into your main stylesheet by adding @import "non-ie.css" all;.

Future versions of Internet Explorer may support the @import rule correctly.

@import "stylesheet.css” all; imports the stylesheet in all major browsers except IE 7 and below. It may or may not work in future versions of IE.

body[class|="page-body"]

UpThe CSS 2.1 specification isn’t clear about whether or not a hyphen can be included in the value of a hyphen-separated attribute selector. Most browsers, including Firefox and Internet Explorer 7, Allow the body[class|="page-body"] selector to select an element whose start tag looks like this: <body class="page-body">. However, Opera interprets the specification differently in this regard. It splits up the attribute value by hyphens and only checks the first piece against the attribute selector value. Obviously, if the attribute was split by hyphens, the first piece won’t have any hyphens in it, so Opera treats this selector as a non-match. Therefore, when the proper class is applied to the body element, this selector matches Internet Explorer 7 and most modern browsers except Opera. Opera may change their behavior to match other browsers in the future, but this technique is known to work for Opera 8 and 9.

Here is an example of this technique in use:

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html lang="en">
	<head>
		<title>Test</title>
		<style type="text/css">
			p
			{
				background: red; /* Applies to all major browsers */
			}

			body[class|="page-body"] p
			{
				background: green; /* Applies to IE 7 and most modern browsers except Opera */
			}
		</style>
	</head>
	<body class="page-body">
		<p>Test</p>
	</body>
</html>

body[class|="page-body"] {} selects the body element with the class page-body in IE 7 and all modern browsers except Opera 9 and below. It may or may not work in future versions.

Unrecommended hacks

UpIf you are going to use hacks, the above techniques are the recommended choices. However, it’s interesting to point out the following unrecommended hacks. Some of them rely on invalid CSS or are more clumsy than the above alternatives.

_property: value and -property: value

UpDue to a parsing error, Internet Explorer 6 and below wouldn’t fail on properties that were prefixed with non-alphanumeric characters. Prefixing a regular property name with _ or - will cause the property to be applied to Internet Explorer 6 and below but generally not in other browsers. Internet Explorer 7 had this bug fixed.

The CSS specification allows browsers to use an underscore (_) or hyphen (-) as a prefix for a vendor-specific property name with the guarantee that such properties will never be used in a future CSS standard. Because of this guarantee, these two prefix characters are ideal options for this hack.

Although the CSS specification defines this vendor-specific property syntax, the properties are inherently not part of any W3C-endorsed CSS profile and are therefore invalid when validated against one. For this reason, and because there is an often acceptable alternative, this hack is unrecommended.

_property: value and -property: value apply the property value in IE 6 and below. Warning: this uses invalid CSS.

*property: value

UpAlthough Internet Explorer 7 corrected its behavior when a property name is prefixed with an underscore or a hyphen, other non-alphanumeric character prefixes are treated as they were in IE6. Therefore, if you add a non-alphanumeric character such as an asterisk (*) immediately before a property name, the property will be applied in IE and not in other browsers. Unlike with the hyphen and underscore method, the CSS specification makes no reservations for the asterisk as a prefix, so use of this hack could result in unexpected behavior as the CSS specifications evolve.

*property: value applies the property value in IE 7 and below. It may or may not work in future versions. Warning: this uses invalid CSS.

body:empty

UpThe :empty pseudo-classes is proposed for CSS 3 and should select an element that has no elements or text inside it. However, when used on the body element, Firefox 1.5 and 2.0 (and corresponding versions of other Gecko-based browsers) always select it even when the body has content (which it should always have).

Although this hack is expected to be valid in CSS 3, it has not yet reached W3C Recommendation status and is invalid CSS 2.x, so it currently isn’t recommended to use this hack. However, it is probably the best way to single out recent versions of Firefox.

body:empty {} selects the body element in Firefox 1.5 and 2.0 only. It may or may not work in future versions. Warning: this uses invalid CSS 2.x but valid CSS 3 according to recent drafts.

>body

UpIf a simple selector is missing on either side of the child combinator (>), Internet Explorer 7 incorrectly assumes that the missing simple selector is a universal selector. So >body is treated by IE7 like *>body, while other browsers ignore it because it’s a parsing error. Similarly, IE7 treats >> like *>*>*.

IE7 has the same quirk with other combinators. +p is treated like *+p and ~p is treated like *~p. (Note: The ~ combinator is an upcoming CSS 3 feature and is not valid CSS 2.1.)

>body {} selects the body element in IE 7 only. It may or may not work in future versions. Warning: this uses invalid CSS!

html*

UpInternet Explorer 7 fixed the quirk that allowed the universal selector (*) to select some nonexistent parent of the html element, but there’s another issue that they didn’t fix: When a universal selector is directly adjacent to another simple selector without a space between, Internet Explorer 7 assumes a space there. That means that html* is treated by IE7 like html *, while other browsers ignore it because it’s a parsing error. Similarly, IE7 treats ** like * *.

html* {} selects all descendants of the html element in IE 7 and below. It may or may not work in future versions. Warning: this uses invalid CSS!

!ie

UpInternet Explorer 7 fixed one of the issues with the !important identifier, but it still has problems when the identifier has an error in it. If an illegal identifier name is used in place of important, Internet Explorer 7 and below will handle the property normally instead of failing. Therefore, in any style declaration block, you can include properties intended to only apply to Internet Explorer and add an !ie identifier. Almost any word can be used in place of ie.

The !ie identifier allows the property to be applied in IE 7 and below. It may or may not work in future versions. Warning: this uses invalid CSS!

!important!

UpAnother problem with the !important identifier that wasn’t fixed in IE 7 is the treatment of non-alphanumeric characters after the identifier. Normally, this should cause the property to fail, but Internet Explorer 7 and below ignore the additional punctuate and apply the property as if it just had the !important identifier.

The !important! identifier allows the property to be applied with importance in IE 7 and below and the property is not applied in other browsers. It may or may not work in future versions. Warning: this uses invalid CSS!

posted @ 2009-03-15 21:13 Fernando 阅读(96) 评论(0) 编辑

If the background color of this paragraph is green (a darker green than this page's background) then the hack was applied.

Example Code

p.test {
  background-color: #f66;
}

*:first-child+html p.test {
  background-color: #6f6;
}

List of browsers that apply this

  • IE7, when in Standards Compatibility mode

List of browsers that do not apply this

  • IE7, when in backwards compatibility mode (aka quirks mode)
  • IE4-6/Win
  • Firefox
  • NS6.0-7.2
  • NS4.x
  • Opera 5+
  • Safari
  • Konqueror 3
  • iCab 3
  • IE5.x/Mac

Note: IE5.5/Win and IE6/Win will ignore any rule that use this selector hack, even if there are multiple selector chains, each separated by a comma, and one of the others would normally apply to an element in the document. This is a very serious parser bug. This is demonstrated in the second test below.

If the background color of this paragraph is green then the hack works. If this is yellow then the browser supports the "* html" (star html) hack, but ignores the second rule.

posted @ 2009-03-15 20:41 Fernando 阅读(172) 评论(0) 编辑
摘要: CSS代码格式化点击查看CSS_format.htmlJS代码格式化点击查看JS_format.htmlJS代码压缩点击查看Js_zip.htmCSS和JS编码美化工具,使你写的有些混乱的编码更加的美观,HTML源码也有美化工具,这个工具名称是FRONTPAGE 2003,具体的大家可以留言咨询阅读全文
posted @ 2009-03-11 15:15 Fernando 阅读(550) 评论(0) 编辑
摘要: 只简单说下和前端开发调试密切相关的:使用AutoResponder本地调试文件。请参考如何直接调试线上页面的JavaScript和CSS. 使用QuickExecBox快速操作。请参考QuickExec Reference. 推荐熟练掌握的命令:?sometext, bpu, go, urlreplace. 快捷键:Alt + Q, Ctrl + I, Shift + Del, Ctrl + X,...阅读全文
posted @ 2009-03-10 12:05 Fernando 阅读(224) 评论(0) 编辑
摘要: 作为一名前端工程师,除了开发新项目,还有一个重要任务是线上网站的日常维护。一个典型的工作场景是:线上的某个页面出现了bugs,需要紧急修复。这时候有个简单的传统做法是,将问题页面另存为本地html文件,然后疯狂的寻找并修复bugs,等弄好了,再将修改后的js和css上传到线上并检查校验bugs是否已修正。上面的方法,对于简单页面,是够用的。但是对于稍微复杂的页面,IE的另存为经常不保真,如果页面中...阅读全文
posted @ 2009-03-10 12:04 Fernando 阅读(193) 评论(0) 编辑
摘要: 一 什么是Scrum?Scrum (英式橄榄球争球队), 软件开发模型是敏捷开发的一种,在最近的一两年内逐渐流行起来。Scrum的基本假设是:开发软件就像开发新产品,无法一开始就能定义软件产品最终的规程,过程中需要研发、创意、尝试错误,所以没有一种固定的流程可以保证专案成功。Scrum 将软件开发团队比拟成橄榄球队,有明确的最高目标,熟悉开发流程中所需具备的最佳典范与技术,具有高度自主权,紧密地沟...阅读全文
posted @ 2009-03-03 19:14 Fernando 阅读(78) 评论(0) 编辑