質問編集履歴

3

ミス

2015/07/27 14:23

投稿

Shinog
Shinog

スコア99

test CHANGED
File without changes
test CHANGED
@@ -25,6 +25,8 @@
25
25
 
26
26
 
27
27
 
28
+
29
+ ```PHP
28
30
 
29
31
  <!DOCTYPE html>
30
32
 
@@ -97,3 +99,5 @@
97
99
  </body>
98
100
 
99
101
  </html>
102
+
103
+ ```

2

ミス

2015/07/27 14:23

投稿

Shinog
Shinog

スコア99

test CHANGED
File without changes
test CHANGED
@@ -21,3 +21,79 @@
21
21
 
22
22
 
23
23
  ちなみに、変数はきちんと読み取られ、また「jQuery Raty」公式ページに沿ったやり方なら無事出来ました。
24
+
25
+
26
+
27
+
28
+
29
+ <!DOCTYPE html>
30
+
31
+ <html lang="ja">
32
+
33
+ <head>
34
+
35
+ <meta charset="UTF-8">
36
+
37
+ <meta http-equiv="X-UA-Compatible" content="IE=edge">
38
+
39
+ <meta name="viewport" content="width=device-width, initial-scale=1">
40
+
41
+ <title>mosio</title>
42
+
43
+
44
+
45
+ <link href="/raty-2.7.0/demo/stylesheets/labs.css" media="screen" rel="stylesheet" type="text/css">
46
+
47
+ <link rel="stylesheet" href="/raty-2.7.0/lib/jquery.raty.css">
48
+
49
+ <script src="/raty-2.7.0/vendor/jquery.js"></script><script src="/raty-2.7.0/lib/jquery.raty.js"></script>
50
+
51
+ <script src="/raty-2.7.0/demo/javascripts/labs.js" type="text/javascript"></script>
52
+
53
+
54
+
55
+ <script type="text/javascript">
56
+
57
+ $(function() {
58
+
59
+ $('#star').raty( {
60
+
61
+ readOnly: true, //閲覧者によるスコアの変更不可
62
+
63
+ score: function() {
64
+
65
+ return $(this).attr('data-score');
66
+
67
+ },
68
+
69
+ .fn.raty.defaults.path: '/raty-2.7.0/lib/images' //サーバ上のRaty画像のパス
70
+
71
+ });
72
+
73
+ });
74
+
75
+ </script>
76
+
77
+
78
+
79
+ </head>
80
+
81
+ <body>
82
+
83
+
84
+
85
+ <?php
86
+
87
+ $fun = 4;
88
+
89
+ ?>
90
+
91
+
92
+
93
+ <div id="star" data-score="<?php echo $fun; ?>"></div>
94
+
95
+
96
+
97
+ </body>
98
+
99
+ </html>

1

ミス

2015/07/27 14:22

投稿

Shinog
Shinog

スコア99

test CHANGED
File without changes
test CHANGED
@@ -17,3 +17,7 @@
17
17
 
18
18
 
19
19
  是非ともご教授のほどよろしくお願い申し上げます。
20
+
21
+
22
+
23
+ ちなみに、変数はきちんと読み取られ、また「jQuery Raty」公式ページに沿ったやり方なら無事出来ました。