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
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
<?php
/**
* 解梦分类编集
* $Id: product_category_new_input.inc,v 1.1 2015/10/08 11:18:53 wanggb Exp $
* @author wanggb
* @access public
* @package manager.templates
**/
global $upload_thumbnail;
global $thumbnail_error_msg;
?>
<b>课程添加/编集</b><br />
<br />
<form name="course_edit_input" action="course_edit_result.php" method="post" enctype="multipart/form-data">
<input type="hidden" name="id" value="<?=$id ?>" />
<table>
<tr>
<td>课程名称</td>
</tr>
<tr>
<td class="begin_blank">
<input type="text" name="title" value="<?=htmlspecialchars($title) ?>" style="width:300px;"/>
</td>
</tr>
<tr>
<td>封面图片</td>
</tr>
<tr>
<td class="begin_blank">
<input type="file" id="upload_thumbnail_file" name="upload_thumbnail_file" onChange="checkUploadThumbnailFile1()" />
<?=!empty($thumbnail_error_msg) ? "<font color=\"red\">{$thumbnail_error_msg}</font>" : "" ?>
<br />
<span id="upload_thumbnail">
<?
if (!empty($upload_thumbnail)) {
?><img id="upload_thumbnail_preview" src="<?=KoalaHandler::getImageUrl($upload_thumbnail) ?>" style="height:50px;" /><?
} else if (!empty($course_mst->thumbnail)) {
?><img id="upload_thumbnail_preview" src="<?=KoalaHandler::getImageUrl($course_mst->thumbnail, "course", "") ?>" style="height:50px;" /><?
} else {
?><img id="upload_thumbnail_preview" src="" style="height:50px;display:none;" /><?
}
?>
</span>
</td>
</tr>
<tr>
<td>文字介绍</td>
</tr>
<tr>
<td class="begin_blank">
<textarea name="comment" style="width:300px;height:100px;"><?=htmlspecialchars($comment) ?></textarea>
</td>
</tr>
<tr>
<td>详细图片</td>
</tr>
<tr>
<td class="begin_blank">
<input type="file" id="upload_thumbnail_file2" name="upload_thumbnail_file2" onChange="checkUploadThumbnailFile2()" />
<?=!empty($thumbnail_error_msg) ? "<font color=\"red\">{$thumbnail_error_msg}</font>" : "" ?>
<br />
<span id="upload_thumbnail2">
<?
if (!empty($upload_thumbnail2)) {
?><img id="upload_thumbnail_preview2" src="<?=KoalaHandler::getImageUrl($upload_thumbnail) ?>" style="height:50px;" /><?
} else if (!empty($course_mst->detail_image)) {
?><img id="upload_thumbnail_preview2" src="<?=KoalaHandler::getImageUrl($course_mst->detail_image, "course", "") ?>" style="height:50px;" /><?
} else {
?><img id="upload_thumbnail_preview2" src="" style="height:50px;display:none;" /><?
}
?>
</span>
</td>
</tr>
<tr>
<td>原价</td>
</tr>
<tr>
<td class="begin_blank">
<input type="text" name="original_price" value="<?=htmlspecialchars($original_price) ?>" style="width:150px;"/>
</td>
</tr>
<tr>
<td>活动价</td>
</tr>
<tr>
<td class="begin_blank">
<input type="text" name="price" value="<?=htmlspecialchars($price) ?>" style="width:150px;"/>
</td>
</tr>
<tr>
<td>花呗分期</td>
</tr>
<tr>
<td class="begin_blank">
<label><input type="checkbox" name="is_free3" value="1" <?=($is_free3) ? " checked=\"checked\"" : "" ?> />3期免息(参考:2.3%)</label>
<label><input type="checkbox" name="is_free6" value="1" <?=($is_free6) ? " checked=\"checked\"" : "" ?> />6期免息(参考:4.5%)</label>
<label><input type="checkbox" name="is_free12" value="1" <?=($is_free12) ? " checked=\"checked\"" : "" ?> />12期免息(参考:7.5%)</label>
</td>
</tr>
</table>
<br />
<input type="button" value="编集" class="button_width_normal" onClick="doCheck();" />
</form>