回答編集履歴
1
追記
test
CHANGED
@@ -12,11 +12,11 @@
|
|
12
12
|
|
13
13
|
if($this.text() == "続きを読む"){
|
14
14
|
|
15
|
-
$this.text("
|
15
|
+
$this.text("閉じる").css({color:"green"});
|
16
16
|
|
17
17
|
} else {
|
18
18
|
|
19
|
-
$this.text("
|
19
|
+
$this.text("続きを読む").css({color:"red"});
|
20
20
|
|
21
21
|
}
|
22
22
|
|
@@ -29,3 +29,7 @@
|
|
29
29
|
```
|
30
30
|
|
31
31
|
イベントが発生した時点の this はその発火したノードになります。ですのでその this を基準に処理を行えばよいです。
|
32
|
+
|
33
|
+
|
34
|
+
|
35
|
+
あと if が逆ですね。
|