File tree 1 file changed +5
-17
lines changed
1 file changed +5
-17
lines changed Original file line number Diff line number Diff line change 1
1
# SmartTV JavaScript SDK for Sony, Philips, LG, Samsung and more!
2
2
3
- ## PubNub JavaScript SDK Usage
3
+ ## SIMPLE EXAMPLE
4
4
5
- You may access the latest PubNub JavaScript SDK on The PubNub Network CDN .
5
+ > ** NOTE: ** Copy and paste this example into a * blank * HTML file .
6
6
7
7
``` html
8
8
<script src =pubnub.min.js ></script >
@@ -13,33 +13,21 @@ You may access the latest PubNub JavaScript SDK on The PubNub Network CDN.
13
13
subscribe_key : ' demo'
14
14
});
15
15
16
- })(); </script >
17
- ```
18
-
19
- ## SIMPLE EXAMPLE
20
-
21
- > ** NOTE:** Copy and paste this example into a * blank* HTML file.
22
-
23
- ``` html
24
- <div id =pubnub pub-key =demo sub-key =demo ></div >
25
- <script src =http://cdn.pubnub.com/pubnub-3.4.8.min.js ></script >
26
- <script >
27
-
28
16
// LISTEN
29
- PUBNUB .subscribe ({
17
+ pubnub .subscribe ({
30
18
channel : " hello_world" ,
31
19
message : function (m ){ alert (m) },
32
20
connect : publish
33
21
})
34
22
35
23
// SEND
36
24
function publish () {
37
- PUBNUB .publish ({
25
+ pubnub .publish ({
38
26
channel : " hello_world" ,
39
27
message : " Hi."
40
28
})
41
29
}
42
30
43
- </script >
31
+ })(); </script >
44
32
```
45
33
You can’t perform that action at this time.
0 commit comments