锘??xml version="1.0" encoding="utf-8" standalone="yes"?> <TABLE style="table-layout: auto | fixed"> 浣跨敤:style="word-break : break-all;" 瀵逛簬鍦ㄨ嫳鏂囦腑浣跨敤,璇蜂嬌鐢╯tyle="table-layout:fixed; word-wrap:break-word" ============================================================================== word-wrap鍚寃ord-break鐨勫尯鍒?/span> word-wrap: word-break: 鎬葷粨濡備笅錛?br />
word-wrap鏄帶鍒舵崲琛岀殑銆?br />
浣跨敤break-word鏃訛紝鏄皢寮哄埗鎹㈣銆備腑鏂囨病鏈変換浣曢棶棰橈紝鑻辨枃璇彞涔熸病闂銆備絾鏄浜庨暱涓茬殑鑻辨枃錛屽氨涓嶈搗浣滅敤銆?/span> break-word鏄帶鍒舵槸鍚︽柇璇嶇殑銆?br />
normal鏄粯璁ゆ儏鍐碉紝鑻辨枃鍗曡瘝涓嶈鎷嗗紑銆?br />
break-all錛屾槸鏂紑鍗曡瘝銆傚湪鍗曡瘝鍒拌竟鐣屾椂錛屼笅涓瓧姣嶈嚜鍔ㄥ埌涓嬩竴琛屻備富瑕佽В鍐充簡闀夸覆鑻辨枃鐨勯棶棰樸?br />
keep-all錛屾槸鎸嘋hinese, Japanese, and Korean涓嶆柇璇嶃傚嵆鍙敤姝ゆ椂錛屼笉鐢╳ord-wrap錛屼腑鏂囧氨涓嶄細鎹㈣浜嗐傦紙鑻辨枃璇彞姝e父銆傦級 ff涓嬶細 鐩墠涓昏鐨勯棶棰樺瓨鍦ㄤ簬 闀夸覆鑻辨枃 鍜?鑻辨枃鍗曡瘝琚柇寮銆傚叾瀹為暱涓茶嫳鏂囧氨鏄竴涓瘮杈冮暱鐨勫崟璇嶈屽凡銆?br />
鍗寵嫳鏂囧崟璇嶅簲涓嶅簲璇ヨ鏂紑閭o紵閭i棶棰樺緢鏄庢樉浜嗭紝鏄劇劧涓嶅簲璇ヨ鏂紑浜嗐?br />
瀵逛簬闀夸覆鑻辨枃錛屽氨鏄伓鎰忕殑涓滆タ錛岃嚜鐒朵笉鐢ㄥ幓綆′簡銆備絾鏄紝涔熻鎯充簺鍔炴硶錛屼笉璁╁畠鎶婂鍣ㄦ拺澶с?br />
鐢細overflow:auto; ie涓嬶紝闀夸覆浼氳嚜鍔ㄦ姌琛屻俧f涓嬶紝闀夸覆浼氳閬洊銆?/p>
鍙︼紝嫻嬭瘯浠g爜濡備笅錛?/p>
1.htm=================================================================== <style> .c1{ width:300px; border:1px solid red} <br> <br> <br> <br> <br> <br> 鎬葷粨浜嗕竴涓嬶紝鍙鍦–SS涓畾涔変簡濡備笅鍙ュ瓙錛屽彲淇濈綉欏典笉浼氬啀琚拺寮浜嗐?/p>
鑷姩鎹㈣闂,姝e父瀛楃鐨勬崲琛屾槸姣旇緝鍚堢悊鐨?鑰岃繛緇殑鏁板瓧鍜岃嫳鏂囧瓧絎﹀父甯稿皢瀹瑰櫒鎾戝ぇ,鎸鴻浜哄ご鐤?涓嬮潰浠嬬粛鐨勬槸CSS濡備綍瀹炵幇鎹㈣鐨勬柟娉?/p>
瀵逛簬div,p絳夊潡綰у厓绱?/p>
姝e父鏂囧瓧鐨勬崲琛?浜氭床鏂囧瓧鍜岄潪浜氭床鏂囧瓧)鍏冪礌鎷ユ湁榛樿鐨剋hite-space:normal,褰撳畾涔夌殑瀹藉害涔嬪悗鑷姩鎹㈣ html IE嫻忚鍣?/p>
榪炵畫鐨勮嫳鏂囧瓧絎﹀拰闃挎媺浼暟瀛?浣跨敤word-wrap: break-word ;鎴栬厀ord-break:break-all;瀹炵幇寮哄埗鏂 html css Firefox嫻忚鍣?br />
榪炵畫鐨勮嫳鏂囧瓧絎﹀拰闃挎媺浼暟瀛楃殑鏂,Firefox鐨勬墍鏈夌増鏈殑娌℃湁瑙e喅榪欎釜闂,鎴戜滑鍙湁璁╄秴鍑鴻竟鐣岀殑瀛楃闅愯棌鎴栬?緇欏鍣ㄦ坊鍔犳粴鍔ㄦ潯 html css 瀵逛簬table鍏冪礌 Firefox嫻忚鍣?/p>
1. 浣跨敤 table-layout:fixed;寮哄埗table鐨勫搴?鍐呭眰td,th閲囩敤word-break : break-all;鎴栬厀ord-wrap : break-word ;鎹㈣錛屼嬌鐢╫verflow:hidden;闅愯棌瓚呭嚭鍐咃紝榪欓噷overflow:auto;鏃犳硶璧蜂綔鐢?lt;table style="table-layout:fixed" width="200"><tr> <td width="25%" style="word-break : break-all; overflow:hidden; ">abcdefghigklmnopqrstuvwxyz1234567890</td> <td width="75%" style="word-wrap : break-word; overflow:hidden; ">abcdefghigklmnopqrstuvwxyz1234567890</td> </tr></table> 鏈浣矯SS瀹氫箟鎹㈣浠g爜.wrap { table-layout:fixed; word-break: break-all; overflow:hidden; } 1)銆乻igkey涓轟釜浜洪壌鏉僰ey錛岃鍕夸慨鏀癸紝鍚﹀垯鏃犳硶鍙戣搗涓存椂浼氳瘽銆?/p>
2)銆佷復鏃朵細璇濆浘鏍?lt;img border="0" SRC='http://wpa.qq.com/pa?p=1:80000805:1' alt="鐐瑰嚮榪欓噷緇欐垜鍙戞秷鎭?> SRC鏄浘鏍囬摼鎺ワ紝鑷畾涔夊浘鏍囦腑鍙互鏇挎崲榪欎竴閮ㄥ垎涓鴻嚜宸卞浘鐗囩殑閾炬帴錛?/p>
鍙傛暟錛?/p>
P=浠ュ啋鍙?#8220;:”鍒嗛殧澶氫釜鍙傛暟 絎竴涓弬鏁頒負鐗堟湰鍙鳳紝鐩墠涓?錛?/p>
絎簩涓負QQ/TM鍙風爜錛?/p>
絎笁涓弬鏁頒負鍥懼儚椋庢牸錛屾敮鎸佸縐嶇姸鎬併?/p>
alt鏄浘鏍囨梺鐣欒█銆?/p>
3)銆侀櫎浜嗚嚜瀹氫箟鍥炬爣闇瑕佷慨鏀逛復鏃朵細璇濆浘鏍囧錛屽叾浠栨儏鍐典笅寤鴻涓嶈淇敼浠g爜錛屽洜涓烘湁鍙兘瀵艱嚧鍦ㄤ笉鍚岀殑鐜鍜屾祻瑙堝櫒涓嬶紝鏃犳硶鍙戣搗涓存椂浼氳瘽銆?/p>
鑷畾涔夊湪綰塊鏍煎浘鐗?/p>
鐢↗S瀹炵幇錛屽叿浣撴楠ゅ涓嬶細 1) 鐢寵浠g爜 2) 瀹氫箟online鏁扮粍錛屽繀欏繪槸online鍛藉悕 <script>var online= new Array();</script>
3) 鑾峰彇鍦ㄧ嚎鐘舵?/p>
<script src="http://webpresence.qq.com/getonline?Type=1&80000805:"></script> 鍙互鑾峰彇澶氫釜錛屽繀欏諱互鍐掑彿鍒嗛殧錛屼互鍐掑彿緇撳熬錛屾瘮濡? <script src="http://webpresence.qq.com/getonline?Type=1&80000805:10000:123456:"></script> online[0]=0,琛ㄧず80000805紱葷嚎 online[1]=1,琛ㄧず10000鍦ㄧ嚎 online[2]=1,琛ㄧず123456鍦ㄧ嚎 濉啓鍙風爜鐨勫厛鍚庨『搴忥紝鍒嗗埆瀵瑰簲鏁扮粍online鐨?銆?銆? 4) 娣誨姞浠g爜 鎶奡RC='http://wpa.qq.com/pa?p=1:80000805:1'鏇挎崲涓鴻嚜宸辯殑鍥劇墖錛屾瘮濡?
]]>
auto: 榛樿鍊?br />
fixed: 瀹藉害鍥哄畾,鎴柇瓚呭嚭鐨勫唴瀹?br />
<TABLE style="word-break: normal | break-all | keep-all">
normal: 榛樿鍊?鎸夊瓧璇嶆埅鏂崲琛?br />
break-all: 寮鴻鎴柇騫舵崲琛?br />
keep-all: 涓嶆埅鏂笉鎹㈣
浣跨敤:style="table-layout:fixed;"
琛ㄧず杈撳嚭鍋滄,鍋滅暀鍦ㄨ瀹氱殑闀垮害鍐?
琛ㄧず瀵硅秴闀塊儴鍒?鎹㈣鍐嶇戶緇樉紺?
鎺ㄨ崘浣跨敤word-wrap:break-word;word-break:break-all;table-layout:fixed;
normal Default. Content exceeds the boundaries of its container.
break-word Content wraps to next line, and a word-break occurs when necessary. 蹇呰鏃朵細瑙﹀彂word-break銆?/p>
normal Default. Allows line breaking within words. 濂藉儚鏄彧瀵笰sian text璧蜂綔鐢ㄣ?br />
break-all Behaves the same as normal for Asian text, yet allows the line to break arbitrarily for non-Asian text. This value is suited to Asian text that contains some excerpts of non-Asian text.
keep-all Does not allow word breaking for Chinese, Japanese, and Korean. Functions the same way as normal for all non-Asian languages. This value is optimized for text that includes small amounts of Chinese, Japanese, or Korean.
ie涓嬶細
浣跨敤word-wrap:break-word;鎵鏈夌殑閮芥甯搞?/p>
濡傝繖2涓兘涓嶇敤鐨勮瘽錛屼腑鏂囦笉浼氬嚭浠諱綍闂銆傝嫳鏂囪鍙ヤ篃涓嶄細鍑洪棶棰樸備絾鏄紝闀夸覆鑻辨枃浼氬嚭闂銆?br />
涓轟簡瑙e喅闀夸覆鑻辨枃錛屼竴鑸敤word-wrap:break-word;word-break:break-all;銆備絾鏄紝姝ゆ柟寮忎細瀵艱嚧錛屾櫘閫氱殑鑻辨枃璇彞涓殑鍗曡瘝浼氳鏂紑錛坕e涓嬩篃鏄級銆?/p>
鎵浠ワ紝緇間笂錛?span style="line-height: 21px; color: #ff0000; ">鏈濂界殑鏂瑰紡鏄痺ord-wrap:break-word;overflow:hidden;鑰屼笉鏄痺ord-wrap:break-word;word-break:break-all;銆?br />
word-wrap:break-word;overflow:auto;鍦╥e涓嬫病鏈変換浣曢棶棰樸傚湪ff涓嬶紝闀夸覆浼氳閬綇閮ㄥ垎鍐呭銆?/span>
.c1{ width:300px; border:1px solid red}
.c2{ width:300px;word-wrap:break-word; border:1px solid yellow}
.c3{ width:300px;word-wrap:break-word;word-break:break-all; border:1px solid green}
.c4{ width:300px;word-wrap:break-word;word-break:keep-all; border:1px solid blue}
.c5{ width:300px;word-break:break-all; border:1px solid black}
.c6{ width:300px;word-break:keep-all; border:1px solid red}
.c7{ width:300px;word-wrap:break-word;overflow:auto; border:1px solid yellow}
</style>
<div class="c1">
safjaskflasjfklsajfklasjflksajflksjflkasjfksafj
</div>
<div class=c1>
This is all English. This is all English. This is all English.
</div>
<div class=c1>
鍏ㄦ槸涓枃鐨勬儏鍐點傚叏鏄腑鏂囩殑鎯呭喌銆傚叏鏄腑鏂囩殑鎯呭喌銆?br />
</div>
<div class=c1>
涓嫳鏂囨販鎺掔殑鎯呭喌銆侰hinese and English. 涓嫳鏂囨販鎺掔殑鎯呭喌銆侰hinese and English.
</div>
.c2{ width:300px;word-wrap:break-word; border:1px solid yellow}
<div class="c2">
safjaskflasjfklsajfklasjflksajflksjflkasjfksafj
</div>
<div class=c2>
This is all English. This is all English. This is all English.
</div>
<div class=c2>
鍏ㄦ槸涓枃鐨勬儏鍐點傚叏鏄腑鏂囩殑鎯呭喌銆傚叏鏄腑鏂囩殑鎯呭喌銆?br />
</div>
<div class=c2>
涓嫳鏂囨販鎺掔殑鎯呭喌銆侰hinese and English. 涓嫳鏂囨販鎺掔殑鎯呭喌銆侰hinese and English.
</div>
.c3{ width:300px;word-wrap:break-word;word-break:break-all; border:1px solid green}
<div class="c3">
safjaskflasjfklsajfklasjflksajflksjflkasjfksafj
</div>
<div class=c3>
This is all English. This is all English. This is all English.
</div>
<div class=c3>
鍏ㄦ槸涓枃鐨勬儏鍐點傚叏鏄腑鏂囩殑鎯呭喌銆傚叏鏄腑鏂囩殑鎯呭喌銆?br />
</div>
<div class=c3>
涓嫳鏂囨販鎺掔殑鎯呭喌銆侰hinese and English. 涓嫳鏂囨販鎺掔殑鎯呭喌銆侰hinese and English.
</div>
.c4{ width:300px;word-wrap:break-word;word-break:keep-all; border:1px solid blue}
<div class="c4">
safjaskflasjfklsajfklasjflksajflksjflkasjfksafj
</div>
<div class=c4>
This is all English. This is all English. This is all English.
</div>
<div class=c4>
鍏ㄦ槸涓枃鐨勬儏鍐點傚叏鏄腑鏂囩殑鎯呭喌銆傚叏鏄腑鏂囩殑鎯呭喌銆?br />
</div>
<div class=c4>
涓嫳鏂囨販鎺掔殑鎯呭喌銆侰hinese and English. 涓嫳鏂囨販鎺掔殑鎯呭喌銆侰hinese and English.
</div>
.c5{ width:300px;word-break:break-all; border:1px solid black}
<div class="c5">
safjaskflasjfklsajfklasjflksajflksjflkasjfksafj
</div>
<div class=c5>
This is all English. This is all English. This is all English.
</div>
<div class=c5>
鍏ㄦ槸涓枃鐨勬儏鍐點傚叏鏄腑鏂囩殑鎯呭喌銆傚叏鏄腑鏂囩殑鎯呭喌銆?br />
</div>
<div class=c5>
涓嫳鏂囨販鎺掔殑鎯呭喌銆侰hinese and English. 涓嫳鏂囨販鎺掔殑鎯呭喌銆侰hinese and English.
</div>
.c6{ width:300px;word-break:keep-all; border:1px solid red}
<div class="c6">
safjaskflasjfklsajfklasjflksajflksjflkasjfksafj
</div>
<div class=c6>
This is all English. This is all English. This is all English.
</div>
<div class=c6>
鍏ㄦ槸涓枃鐨勬儏鍐點傚叏鏄腑鏂囩殑鎯呭喌銆傚叏鏄腑鏂囩殑鎯呭喌銆?br />
</div>
<div class=c6>
涓嫳鏂囨販鎺掔殑鎯呭喌銆侰hinese and English. 涓嫳鏂囨販鎺掔殑鎯呭喌銆侰hinese and English.
</div>
.c7{ width:300px;word-wrap:break-word;overflow:auto; border:1px solid yellow}
<div class="c7">
safjaskflasjfklsajfklasjflksajflksjflkasjfksafj
</div>
<div class=c7>
This is all English. This is all English. This is all English.
</div>
<div class=c7>
鍏ㄦ槸涓枃鐨勬儏鍐點傚叏鏄腑鏂囩殑鎯呭喌銆傚叏鏄腑鏂囩殑鎯呭喌銆?br />
</div>
<div class=c7>
涓嫳鏂囨販鎺掔殑鎯呭喌銆侰hinese and English. 涓嫳鏂囨販鎺掔殑鎯呭喌銆侰hinese and English.
</div>
]]>
2 import java.util.Scanner;
3 public class SortTest {
4 public static void main(String[] args) throws IOException {
5 int temp = 0;//涓存椂鍙橀噺錛岀敤浜庡啋娉′氦鎹?nbsp;
6 int[] num=new int[10]; //澹版槑涓涓┖鐨勬暟緇?nbsp; 10涓暱搴?/span>
7 Scanner sc = new Scanner(System.in);
8 FileOutputStream out=new FileOutputStream("1.txt");
9 PrintStream p=new PrintStream(out);
10 //寮濮嬪驚鐜祴鍊?/span>
11 for(int i =0;i<num.length;i++){
12 num[i]=sc.nextInt();
13 }
14 p.append("鎺掑簭鍓嶄負:");
15 for (int i = 0; i <num.length; i++) {
16 System.out.println(num[i]);
17 p.append(num[i]+" , ");
18 }
19 // 鐢ㄤ簬鎺掑簭
20 for (int i = 0; i < num.length-1; i++) {
21 for (int j = 0; j < num.length - i - 1; j++) {
22 if (num[j] > num[j + 1]) {
23 temp = num[j];
24 num[j] = num[j + 1];
25 num[j + 1] = temp;
26 }
27 }
28 }
29 //杈撳嚭鏂囦歡
30 p.append("\n");
31 p.append("鎺掑簭鍚庝負:");
32 // 寰幆杈撳嚭
33 System.out.println("鎺掑簭鍚庝負:");
34 for (int i = 0; i <num.length; i++) {
35 System.out.println(num[i]);
36 p.append(num[i]+" , ");
37 }
38
39
40 }
41 }
鏈鍚庡簲璇ユ妸p緇檆lose浜嗗搱
]]>
table涓嶈兘鎹㈣闂 涓鑸槸錛氫竴琛岄噷闈㈠叏鏄暟瀛楁垨鏄瓧姣嶆垨鑰呯粨灝炬湁澶氫釜鎰熷徆鍙瘋屽鑷?table涓嶈兘鎹㈣錛屼腑鏂囬粯璁ょ殑浼氳嚜鍔ㄦ崲琛岀殑錛屽瓧姣嶄笉鑳芥崲琛岄棶棰橈細
style="table-layout:fixed; word-break: break-all; overflow:hidden;"
澶嶅埗浠g爜鍦ㄥ崟鍏冩牸灞炴ч噷鍔犲叆涓婇潰榪欏彞錛屽錛?br />
<td style="table-layout:fixed; word-break: break-all; overflow:hidden;">
澶嶅埗浠g爜鐢ㄨ〃鏍煎仛緗戦〉鎺掔増鐨勬椂鍊欙紝涓鑸兘鑳芥甯鎬嬌鐢ㄣ傚亸鍋忔湁鏃朵細紕板埌涓孌佃繛緇殑鑻辨枃璇嶆垨鑰呬竴鍫嗘劅鍙瑰彿(!!!)鎶婄綉欏靛氨鎾戝紑鐨勭幇璞°?/p>
<div id="wrap">姝e父鏂囧瓧鐨勬崲琛?浜氭床鏂囧瓧鍜岄潪浜氭床鏂囧瓧)鍏冪礌鎷ユ湁榛樿鐨剋hite-space:normal,褰撳畾涔?lt;/div>
css
#wrap{white-space:normal; width:200px; }
<div id="wrap">abcdefghijklmnabcdefghijklmnabcdefghijklmn111111111</div>
#wrap{word-break:break-all; width:200px;}
鎴栬?
#wrap{word-wrap:break-word; width:200px;}
<div id="wrap">abcdefghijklmnabcdefghijklmnabcdefghijklmn111111111</div>
#wrap{word-break:break-all; width:200px; overflow:auto;}
IE嫻忚鍣?br />
1. 浣跨敤 table-layout:fixed;寮哄埗table鐨勫搴?澶氫綑鍐呭闅愯棌<table style="table-layout:fixed" width="200"><tr><td>abcdefghigklmnopqrstuvwxyz1234567890ssssssssssssss</td></tr></table>
澶嶅埗浠g爜2. 浣跨敤 table-layout:fixed;寮哄埗table鐨勫搴?鍐呭眰td,th閲囩敤word-break : break-all;鎴栬厀ord-wrap : break-word ;鎹㈣ <table width="200" style="table-layout:fixed;"><tr><td width="25%" style="word-break : break-all; ">abcdefghigklmnopqrstuvwxyz 1234567890</td><td style="word-wrap : break-word ;">abcdefghigklmnopqrstuvwxyz 1234567890</td></tr></table>
澶嶅埗浠g爜3.鍦╰d,th涓祵濂梔iv,p絳夐噰鐢ㄤ笂闈㈡彁鍒扮殑div,p鐨勬崲琛屾柟娉?/p>
澶嶅埗浠g爜2.鍦╰d,th涓祵濂梔iv,p絳夐噰鐢ㄤ笂闈㈡彁鍒扮殑瀵逛粯Firefox鐨勬柟娉曘?/p>
澶嶅埗浠g爜褰撶劧錛岃繖縐嶇幇璞″嚭鐜扮殑鍑犵巼寰堝皬錛屼絾鏄笉鑳芥帓闄ょ綉鍙嬬殑鎭舵悶銆?
]]>
<a href="http://sighttp.qq.com/cgi-bin/check?sigkey=81a37f0b7cac68639bddfdb9b93a6c92bc211f3e3a4e683afbb31a079382dc9d";target=_blank; onclick="var tempSrc='http://sighttp.qq.com/wpa.js?rantime='+Math.random()+'&sigkey=81a37f0b7cac68639bddfdb9b93a6c92bc211f3e3a4e683afbb31a079382dc9d';var oldscript=document.getElementById('testJs');var newscript=document.createElement('script');newscript.setAttribute('type','text/javascript'); newscript.setAttribute('id', 'testJs');newscript.setAttribute('src',tempSrc);if(oldscript == null){document.body.appendChild(newscript);}else{oldscript.parentNode.replaceChild(newscript, oldscript);}return false;"><img border="0" SRC='http://wpa.qq.com/pa?p=1:80000805:1' alt="鐐瑰嚮榪欓噷緇欐垜鍙戞秷鎭?></a>
else document.write("<a href="http://sighttp.qq.com/cgi-bin/check?sigkey=81a37f0b7cac68639bddfdb9b93a6c92bc211f3e3a4e683afbb31a079382dc9d"; target=_blank; onclick="var tempSrc='http://sighttp.qq.com/wpa.js?rantime='+Math.random()+'&sigkey=81a37f0b7cac68639bddfdb9b93a6c92bc211f3e3a4e683afbb31a079382dc9d';var oldscript=document.getElementById('testJs');var newscript=document.createElement('script');newscript.setAttribute('type','text/javascript'); newscript.setAttribute('id', 'testJs');newscript.setAttribute('src',tempSrc);if(oldscript == null){document.body.appendChild(newscript);}else{oldscript.parentNode.replaceChild(newscript, oldscript);}return false;"><img border="0" SRC='http://xxxx/online.jpg' alt="鐐瑰嚮榪欓噷緇欐垜鍙戞秷鎭?></a>"); </script>
鎴戞槸榪欐牱鐪嬬殑錛岀敤tx鐨勬柟娉曞緱鍒版煇QQ鍙鋒槸鍚﹀湪綰匡紝鐢╦s鍒ゆ柇錛屾樉紺簅nline.jpg鎴栬卭utline.jpg榪欎袱涓浘鐗囷紝鍏朵綑涓嶅彉銆?img src ="http://www.tkk7.com/chenglu/aggbug/324381.html" width = "1" height = "1" />
]]>
Spring鐨刟pplicationContext.xml鏂囦歡