原创作品,允许转载,转载时请务必以超链接形式标明文章
原始出处 、作者信息和本声明。否则将追究法律责任。
http://qingkechina.blog.51cto.com/5552198/1404845
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
|
<
title
>斗医</
title
>
<!--利于搜索引擎查询-->
<
meta
name
=
"description"
content
=
"斗医是一个医学交流平台"
/>
<
meta
name
=
"keywords"
content
=
"医学,交流,讨论"
/>
<!--设置字符集-->
<
meta
http-equiv
=
"content-type"
content
=
"text/html;charset=utf-8"
/>
<!--页面不缓存-->
<
meta
http-equiv
=
"pragma"
content
=
"no-cache"
/>
<
meta
http-equiv
=
"cache-control"
content
=
"no-cache,must-revalidate"
/>
<
meta
http-equiv
=
"expires"
content
=
"Wed, 26 Feb 1997 08:21:57 GMT"
/>
<!--引入外部文件-->
<
link
rel
=
"stylesheet"
type
=
"text/css"
href
=
"theme/navigation/navigation.css"
>
<
link
rel
=
"stylesheet"
type
=
"text/css"
href
=
"theme/challenge/challenge.css"
>
<
script
src
=
"js/common/jquery.js"
></
script
>
<
script
src
=
"js/common/common.js"
></
script
>
<
script
src
=
"js/challenge/challenge.js"
></
script
>
|
1
2
3
4
|
<!--系统导航菜单-->
<
div
id
=
"system_navigation_menu"
></
div
>
<!--系统内容部分-->
<
div
class
=
"system_content"
>abcdefg</
div
>
|
systemMenu += '<li id="system_challenge_menu"><a href="challenge.act">下战书</a></li>'; |
var menuArray = new Array("system_challenge_menu", "system_home_menu", "system_expert_menu", "system_login_menu"); |
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
|
<
html
>
<
head
>
<
title
>斗医</
title
>
<!--利于搜索引擎查询-->
<
meta
name
=
"description"
content
=
"斗医是一个医学交流平台"
/>
<
meta
name
=
"keywords"
content
=
"医学,交流,讨论"
/>
<!--设置字符集-->
<
meta
http-equiv
=
"content-type"
content
=
"text/html;charset=utf-8"
/>
<!--页面不缓存-->
<
meta
http-equiv
=
"pragma"
content
=
"no-cache"
/>
<
meta
http-equiv
=
"cache-control"
content
=
"no-cache,must-revalidate"
/>
<
meta
http-equiv
=
"expires"
content
=
"Wed, 26 Feb 1997 08:21:57 GMT"
/>
<!--引入外部文件-->
<
link
rel
=
"stylesheet"
type
=
"text/css"
href
=
"theme/navigation/navigation.css"
>
<
link
rel
=
"stylesheet"
type
=
"text/css"
href
=
"theme/challenge/challenge.css"
>
<
script
src
=
"js/common/jquery.js"
></
script
>
<
script
src
=
"js/common/common.js"
></
script
>
<
script
src
=
"js/challenge/challenge.js"
></
script
>
</
head
>
<
body
>
<!--系统导航菜单-->
<
div
id
=
"system_navigation_menu"
></
div
>
<!--系统内容部分-->
<
div
class
=
"system_content"
>
<
div
class
=
"challenge_content_wrapper"
>
<
div
class
=
"challenge_textarea_wrapper"
>
<
textarea
id
=
"challenge_title_id"
placeholder
=
"写下您的问题"
></
textarea
>
</
div
>
<
div
class
=
"challenge_hint_info"
>
已超出<
label
class
=
"challenge_hint_warn"
id
=
"challenge_title_hint_id"
></
label
>字
</
div
>
<
div
class
=
"challenge_text_desc"
>问题科室:</
div
>
<
div
class
=
"challenge_textarea_wrapper"
>
<
textarea
id
=
"challenge_kind_id"
placeholder
=
"选择问题所属科室"
></
textarea
>
</
div
>
<
div
class
=
"challenge_text_desc"
>药方说明(可选):</
div
>
<
div
class
=
"challenge_textarea_wrapper"
>
<
textarea
id
=
"challenge_prescript_id"
placeholder
=
"写下病人神、色、形、态、舌象等症状......"
></
textarea
>
</
div
>
<
div
class
=
"challenge_hint_info"
>
已超出<
label
class
=
"challenge_hint_warn"
id
=
"challenge_prescript_hint_id"
></
label
>字
</
div
>
<
div
class
=
"challenge_text_desc"
>挑战人(可选):</
div
>
<
div
class
=
"challenge_textarea_wrapper"
>
<
textarea
id
=
"challenge_challenger_id"
placeholder
=
"选择您的挑战人"
></
textarea
>
</
div
>
<
div
class
=
"challenge_text_desc"
>
<
a
href
=
"#"
class
=
"challenge_confirm_publish"
>发布</
a
>
<
a
href
=
"#"
class
=
"challenge_cancel_publish"
>取消</
a
>
</
div
>
</
div
>
</
div
>
</
body
>
</
html
>
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
|
(
function
( window){
$(document).ready(
function
(){
// 生成系统菜单
generateSystemMenu();
// 选择下战书系统菜单
selectSystemMenu(
"system_challenge_menu"
);
// 获取用户简要信息
getBreifUserInfo();
// 初始化文本框监听器
initInputListener();
});
/**
* 初始化文本框监听器
*/
function
initInputListener(){
var
textareaArray =
new
Array(
"challenge_title_id"
,
"challenge_kind_id"
,
"challenge_prescript_id"
,
"challenge_challenger_id"
);
$.each(textareaArray,
function
(i, item){
var
dynamicItem = $(
"#"
+ item);
dynamicItem.bind(
"propertychange"
,
function
(event){
this
.style.height =
this
.scrollHeight -2 +
"px"
;
});
dynamicItem.bind(
"input"
,
function
(event){
this
.style.height =
this
.scrollHeight - 2 +
"px"
;
});
});
}
})( window );
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
|
/*********************************************************************/
/* 系统下战书样式 */
/*********************************************************************/
.challenge_content_wrapper{
width
:
710px
;
margin
:
20px
auto
;
font-size
:
13px
;
border
:
1px
solid
#CCC
;
overflow
:
hidden
;
}
.challenge_textarea_wrapper{
margin
:
5px
;
padding
:
8px
5px
;
line-height
:
15px
;
box-shadow:
0
1px
1px
rgba(
0
,
0
,
0
,.
1
)
inset
;
border-radius:
3px
;
background
:
#FFF
;
border
:
1px
solid
#ccc
;
color
:
#222
;
}
/*********************************************************************/
/* 下战书TextArea公共样式 */
/*********************************************************************/
.challenge_textarea_wrapper textarea{
height
:
20px
;
line-height
:
20px
;
width
:
100%
;
vertical-align
:
bottom
;
/*移除滚动条*/
overflow
:
hidden
;
/*自动换行*/
word-wrap: break-word;
/*移除边框*/
border
:
0
;
background-color
:
#FFF
;
/*去除改变大小拖拽柄*/
resize:
none
;
font-size
:
13px
;
border-radius:
5px
;
}
.challenge_textarea_wrapper textarea:focus{
outline
:
0
;
outline-offset:
-2px
;
}
/*********************************************************************/
/* 药方说明样式 */
/*********************************************************************/
.challenge_text_desc{
margin
:
25px
5px
0
6px
;
}
#challenge_prescript_id{
height
:
80px
;
min-height
:
80px
;
}
/*********************************************************************/
/* 文本提示信息 */
/*********************************************************************/
.challenge_hint_info{
text-align
:
right
;
margin-right
:
5px
;
font-size
:
13px
;
color
:
#999
;
display
:
none
;
}
.challenge_hint_warn{
color
:
#C33
;
}
/*********************************************************************/
/* 下战书按钮 */
/*********************************************************************/
.challenge_cancel_publish, .challenge_confirm_publish{
float
:
right
;
margin
:
0
3px
10px
0
;
color
:
#259
;
font-size
:
13px
;
line-height
:
1.7
;
padding
:
4px
10px
;
}
.challenge_cancel_publish:hover{
text-decoration
:
underline
;
}
.challenge_confirm_publish{
font-size
:
14px
;
color
:
#FFF
;
display
: inline-
block
;
text-align
:
center
;
background-color
:
#1575D5
;
border
:
1px
solid
#0D6EB8
;
border-radius:
3px
;
text-shadow
:
0
-1px
0
rgba(
0
,
0
,
0
,.
5
);
box-shadow:
0
1px
0
rgba(
255
,
255
,
255
,.
2
)
inset
,
0
1px
0
rgba(
0
,
0
,
0
,.
2
);
}
|