質問編集履歴
2
test
CHANGED
File without changes
|
test
CHANGED
@@ -180,7 +180,7 @@
|
|
180
180
|
|
181
181
|
ファイル名から数字を取り出して、hiddenでIDを送信する部分はできたのですが…
|
182
182
|
|
183
|
-
###
|
183
|
+
### ファイル名をhiddenで送信する
|
184
184
|
|
185
185
|
```
|
186
186
|
|
1
test
CHANGED
File without changes
|
test
CHANGED
@@ -18,7 +18,71 @@
|
|
18
18
|
|
19
19
|
```
|
20
20
|
|
21
|
+
<!DOCTYPE html>
|
22
|
+
|
23
|
+
<html>
|
24
|
+
|
25
|
+
<head>
|
26
|
+
|
27
|
+
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
28
|
+
|
29
|
+
<link rel="stylesheet" href="style.css" media="all">
|
30
|
+
|
31
|
+
<link rel="stylesheet" href="jQuality/css/validationEngine.jquery.css" type="text/css"/>
|
32
|
+
|
33
|
+
<script src="jQuality/js/jquery-1.8.2.min.js" type="text/javascript"></script>
|
34
|
+
|
35
|
+
<script src="jQuality/js/languages/jquery.validationEngine-ja.js" type="text/javascript" charset="utf-8"></script>
|
36
|
+
|
37
|
+
<script src="jQuality/js/jquery.validationEngine.js" type="text/javascript" charset="utf-8"></script>
|
38
|
+
|
39
|
+
<script type="text/javascript">
|
40
|
+
|
41
|
+
jQuery(document).ready(function(){
|
42
|
+
|
43
|
+
jQuery("#pngform").validationEngine();
|
44
|
+
|
45
|
+
});
|
46
|
+
|
47
|
+
</script>
|
48
|
+
|
49
|
+
<script type="text/javascript">
|
50
|
+
|
51
|
+
var url = window.location.href;
|
52
|
+
|
53
|
+
var filename = url.match(".+/(.+?).[a-z]+([?#;].*)?$")[1];
|
54
|
+
|
55
|
+
function set() {
|
56
|
+
|
57
|
+
var var2 = document.getElementById('hidden');
|
58
|
+
|
59
|
+
var2.value = filename;
|
60
|
+
|
61
|
+
}
|
62
|
+
|
63
|
+
</script>
|
64
|
+
|
65
|
+
<script type="text/javascript" src="js/PHPtemplate.js"></script>
|
66
|
+
|
67
|
+
<title>作品自動登録システム</title>
|
68
|
+
|
69
|
+
<meta http-equiv="Pragma" content="no-cache"><meta http-equiv="Cache-Control" content="no-cache"><meta http-equiv="Expires" content="Thu, 01 Dec 1994 16:00:00 GMT"></head>
|
70
|
+
|
71
|
+
<body>
|
72
|
+
|
73
|
+
<p class="title">PNG(イラスト)自動投稿フォーム ※管理者用</p>
|
74
|
+
|
75
|
+
<Hr>
|
76
|
+
|
77
|
+
<form id="pngform" action="pngworkform.php" method="post" enctype="multipart/form-data" onsubmit="set()">
|
78
|
+
|
79
|
+
<input type="hidden" id="hidden" name="username" value="" />
|
80
|
+
|
81
|
+
<table frame="void" cellpadding="5">
|
82
|
+
|
83
|
+
<tr>
|
84
|
+
|
21
|
-
<td><p class="word">
|
85
|
+
<td><p class="word">作者名 : </p></td>
|
22
86
|
|
23
87
|
<td><select name="penname" class="validate[required]">
|
24
88
|
|
@@ -28,6 +92,54 @@
|
|
28
92
|
|
29
93
|
</select></td>
|
30
94
|
|
95
|
+
<tr>
|
96
|
+
|
97
|
+
<td><p class="word">作品名 : </p></td>
|
98
|
+
|
99
|
+
<td><input type="text" name="worktitle" size="20" class="validate[required,minSize[1],maxSize[10]]" /></td>
|
100
|
+
|
101
|
+
<tr>
|
102
|
+
|
103
|
+
<td>サムネイルファイル(幅300px以下) : </td>
|
104
|
+
|
105
|
+
<td><input type="file" name="upfile" size="30" class="validate[required]" data-prompt-position="bottomLeft" accept=".png" /></td>
|
106
|
+
|
107
|
+
<tr>
|
108
|
+
|
109
|
+
<td><p class="word">投稿通知設定 : </p></td>
|
110
|
+
|
111
|
+
<td>
|
112
|
+
|
113
|
+
<input type="radio" name="notice" value="0" class="validate[required]" id="notice1" checked="checked" /><label for="notice1"">通知しない</label>
|
114
|
+
|
115
|
+
<input type="radio" name="notice" value="1" class="validate[required]" id="notice2" /><label for="notice2"">通知する</label>
|
116
|
+
|
117
|
+
<td>
|
118
|
+
|
119
|
+
<tr>
|
120
|
+
|
121
|
+
<tr>
|
122
|
+
|
123
|
+
<td><BR><BR><BR></td><td></td>
|
124
|
+
|
125
|
+
<tr>
|
126
|
+
|
127
|
+
<td>
|
128
|
+
|
129
|
+
<input type="checkbox" class="validate[required] checkbox" name="checkbox1" id="checkbox1"><label for="checkbox1">内容を確認しました。</label><br><BR><br>
|
130
|
+
|
131
|
+
<input type="submit" name="button" value="イラストを投稿する!">
|
132
|
+
|
133
|
+
</td>
|
134
|
+
|
135
|
+
</table>
|
136
|
+
|
137
|
+
</form>
|
138
|
+
|
139
|
+
</body>
|
140
|
+
|
141
|
+
</html>
|
142
|
+
|
31
143
|
```
|
32
144
|
|
33
145
|
### PHPtenmlate.js (text/javascript)
|