emi-indo-cordova-plugin-admob 1.4.7 → 1.5.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.vscode/debug/app-debug.apk +0 -0
- package/.vscode/debug/output-metadata.json +21 -0
- package/.vscode/settings.json +3 -0
- package/README.md +351 -76
- package/package.json +1 -1
- package/plugin.xml +299 -284
- package/src/android/emiAdmobPlugin.kt +1843 -0
- package/src/ios/emiAdmobPlugin.h +0 -1
- package/src/ios/emiAdmobPlugin.m +501 -2622
- package/www/emiAdmobPlugin.js +39 -17
- package/example/Advanced topics/IABTFC.html +0 -187
- package/example/Advanced topics/consent.html +0 -156
- package/example/Advanced topics/globalSettings.html +0 -49
- package/example/Advanced topics/requestIDFA.html +0 -59
- package/example/Advanced topics/targeting.html +0 -64
- package/example/app_open_ads.html +0 -128
- package/example/banner_ads.html +0 -213
- package/example/interstitial_ads.html +0 -150
- package/example/rewarded_ads.html +0 -169
- package/example/rewarded_interstitial_ads.html +0 -167
- package/example/wewrtr.html +0 -0
- package/src/android/emiAdmobPlugin.java +0 -1
@@ -1,128 +0,0 @@
|
|
1
|
-
<html>
|
2
|
-
<head>
|
3
|
-
<script type="text/javascript" src="cordova.js"></script>
|
4
|
-
</head>
|
5
|
-
<body>
|
6
|
-
|
7
|
-
<label for="event">Debug Event All response :</label>
|
8
|
-
<textarea id="event" name="event" rows="5" cols="40"></textarea>
|
9
|
-
|
10
|
-
<script>
|
11
|
-
|
12
|
-
let event = document.getElementById('event');
|
13
|
-
|
14
|
-
let cleanText = () => { event.value = '' };
|
15
|
-
|
16
|
-
|
17
|
-
// WARNING config must be an array[] not an object{}
|
18
|
-
const config_AppOpenAd = [adUnitId = "ca-app-pub-3940256099942544/3419835294", autoShow = false ];
|
19
|
-
|
20
|
-
|
21
|
-
// load App Open Ad
|
22
|
-
|
23
|
-
let loadAppOpenAd = () => {
|
24
|
-
|
25
|
-
cordova.plugins.emiAdmobPlugin.loadAppOpenAd(config_AppOpenAd);
|
26
|
-
// Or like this
|
27
|
-
// cordova.plugins.emiAdmobPlugin.loadAppOpenAd([adUnitId = "ca-app-pub-3940256099942544/3419835294", autoShow = false ]);
|
28
|
-
// call loadAppOpenAd();
|
29
|
-
}
|
30
|
-
|
31
|
-
// Show App Open Ad
|
32
|
-
|
33
|
-
let showAppOpenAd = () => {
|
34
|
-
cordova.plugins.emiAdmobPlugin.showAppOpenAd();
|
35
|
-
// call showAppOpenAd();
|
36
|
-
}
|
37
|
-
|
38
|
-
|
39
|
-
///// >>>>>> Device Ready <<<<<<
|
40
|
-
|
41
|
-
|
42
|
-
document.addEventListener("deviceready", function(){
|
43
|
-
|
44
|
-
const config_globalSettings = [
|
45
|
-
|
46
|
-
// DEPRECATED enableSameAppKey
|
47
|
-
setAppMuted = false, // Type Boolean default: false
|
48
|
-
setAppVolume = 1.0, // Type float default: 1
|
49
|
-
publisherFirstPartyIdEnabled = true, // Type Boolean default: true // enableSameAppKey
|
50
|
-
npa = "1", // string "0" | "1" // DEPRECATED Beginning January 16, 2024
|
51
|
-
enableCollapsible = true, // (BETA) activate the collapsible banner ads
|
52
|
-
responseInfo = false, // For debugging and logging purposes
|
53
|
-
|
54
|
-
]
|
55
|
-
|
56
|
-
cordova.plugins.emiAdmobPlugin.globalSettings(config_globalSettings);
|
57
|
-
cordova.plugins.emiAdmobPlugin.initialize();
|
58
|
-
// SDK EVENT Initialization
|
59
|
-
|
60
|
-
document.addEventListener('on.sdkInitialization', () => {
|
61
|
-
|
62
|
-
event.value += ("\n On Sdk Initialization");
|
63
|
-
|
64
|
-
|
65
|
-
});
|
66
|
-
|
67
|
-
|
68
|
-
// App Open Ad EVENT
|
69
|
-
|
70
|
-
/*
|
71
|
-
on.appOpenAd.loaded
|
72
|
-
on.appOpenAd.failed.loaded
|
73
|
-
on.appOpenAd.dismissed
|
74
|
-
on.appOpenAd.failed.show
|
75
|
-
on.appOpenAd.show
|
76
|
-
on.appOpenAd.revenue
|
77
|
-
*/
|
78
|
-
|
79
|
-
|
80
|
-
document.addEventListener('on.appOpenAd.loaded', () => {
|
81
|
-
|
82
|
-
event.value += ("\n on.appOpenAd.loaded");
|
83
|
-
|
84
|
-
});
|
85
|
-
|
86
|
-
document.addEventListener('on.appOpenAd.failed.loaded', () => {
|
87
|
-
|
88
|
-
event.value += ("\n on.appOpenAd.failed.loaded");
|
89
|
-
|
90
|
-
});
|
91
|
-
|
92
|
-
document.addEventListener('on.appOpenAd.dismissed', () => {
|
93
|
-
|
94
|
-
event.value += ("\n on.appOpenAd.dismissed");
|
95
|
-
|
96
|
-
});
|
97
|
-
|
98
|
-
document.addEventListener('on.appOpenAd.failed.show', () => {
|
99
|
-
|
100
|
-
event.value += ("\n on.appOpenAd.failed.show");
|
101
|
-
|
102
|
-
});
|
103
|
-
|
104
|
-
document.addEventListener('on.appOpenAd.show', () => {
|
105
|
-
|
106
|
-
event.value += ("\n on.appOpenAd.show");
|
107
|
-
|
108
|
-
});
|
109
|
-
|
110
|
-
document.addEventListener('on.appOpenAd.revenue', () => {
|
111
|
-
|
112
|
-
event.value += ("\n on.appOpenAd.revenue");
|
113
|
-
|
114
|
-
});
|
115
|
-
|
116
|
-
|
117
|
-
}, false);
|
118
|
-
|
119
|
-
</script>
|
120
|
-
|
121
|
-
<p> <button onclick="loadAppOpenAd();">load App Open Ad</button></p>
|
122
|
-
<p> <button onclick="showAppOpenAd();">Show App Open Ad</button></p>
|
123
|
-
|
124
|
-
<p> <button onclick="cleanText();">Clean response Text</button></p>
|
125
|
-
|
126
|
-
|
127
|
-
</body>
|
128
|
-
</html>
|
package/example/banner_ads.html
DELETED
@@ -1,213 +0,0 @@
|
|
1
|
-
<html>
|
2
|
-
<head>
|
3
|
-
<script type="text/javascript" src="cordova.js"></script>
|
4
|
-
</head>
|
5
|
-
<body>
|
6
|
-
|
7
|
-
<label for="event">Debug Event All response :</label>
|
8
|
-
<textarea id="event" name="event" rows="5" cols="40"></textarea>
|
9
|
-
|
10
|
-
<script>
|
11
|
-
|
12
|
-
let event = document.getElementById('event');
|
13
|
-
|
14
|
-
let cleanText = () => { event.value = '' };
|
15
|
-
/*
|
16
|
-
|
17
|
-
|
18
|
-
>>>>>>>>>>> Banner collapsible position <<<<<<<<<<<<
|
19
|
-
top-center
|
20
|
-
bottom-center
|
21
|
-
|
22
|
-
|
23
|
-
>>>>>>>>>>> Banner position <<<<<<<<<<<<
|
24
|
-
top-right
|
25
|
-
top-center
|
26
|
-
left
|
27
|
-
center
|
28
|
-
right
|
29
|
-
bottom-center
|
30
|
-
bottom-right
|
31
|
-
|
32
|
-
>>>>>>>>>>> Banner size <<<<<<<<<<<<
|
33
|
-
( Ad Size Adaptive )
|
34
|
-
|
35
|
-
ANCHORED
|
36
|
-
IN_LINE
|
37
|
-
FULL_WIDTH
|
38
|
-
adaptive_Width = 320
|
39
|
-
|
40
|
-
( Ad Size not Adaptive )
|
41
|
-
|
42
|
-
BANNER
|
43
|
-
FLUID
|
44
|
-
LARGE_BANNER
|
45
|
-
MEDIUM_RECTANGLE
|
46
|
-
FULL_BANNER
|
47
|
-
LEADERBOARD
|
48
|
-
|
49
|
-
*/
|
50
|
-
|
51
|
-
|
52
|
-
// WARNING config must be an array[] not an object{}
|
53
|
-
const bannerConfig = [
|
54
|
-
|
55
|
-
adUnitId = "ca-app-pub-3940256099942544/6300978111",
|
56
|
-
position = "bottom-center",
|
57
|
-
size = "BANNER",
|
58
|
-
collapsible = "bottom", // (BETA) enable in globalSettings
|
59
|
-
adaptive_Width = 320, // Ignored
|
60
|
-
autoShow = true // boolean
|
61
|
-
|
62
|
-
]
|
63
|
-
|
64
|
-
|
65
|
-
// load banner ad
|
66
|
-
let loadBannerAd = () => {
|
67
|
-
cordova.plugins.emiAdmobPlugin.loadBannerAd(bannerConfig);
|
68
|
-
// call loadBannerAd();
|
69
|
-
}
|
70
|
-
|
71
|
-
// show Banner Ad
|
72
|
-
let showBannerAd = () => {
|
73
|
-
|
74
|
-
cordova.plugins.emiAdmobPlugin.showBannerAd((info) => {
|
75
|
-
document.body.style.height= '93vh';
|
76
|
-
document.body.style.background= 'black';
|
77
|
-
// event name: on.banner.revenue
|
78
|
-
event.value += "\n Micros: " + info.micros;
|
79
|
-
event.value += "\n Currency: " + info.currency;
|
80
|
-
event.value += "\n Precision: " + info.precision;
|
81
|
-
event.value += "\n AdUnitId: " + info.adUnitId;
|
82
|
-
|
83
|
-
},
|
84
|
-
(error) => {
|
85
|
-
|
86
|
-
event.value += "\n Error: " + error
|
87
|
-
|
88
|
-
});
|
89
|
-
// call showBannerAd();
|
90
|
-
}
|
91
|
-
|
92
|
-
// Hide Banner Ad
|
93
|
-
let hideBannerAd = () => {
|
94
|
-
cordova.plugins.emiAdmobPlugin.hideBannerAd();
|
95
|
-
// call hideBannerAd();
|
96
|
-
}
|
97
|
-
|
98
|
-
// Remove Banner
|
99
|
-
let removeBannerAd = () => {
|
100
|
-
cordova.plugins.emiAdmobPlugin.removeBannerAd();
|
101
|
-
// call removeBannerAd();
|
102
|
-
}
|
103
|
-
|
104
|
-
|
105
|
-
///// >>>>>> Device Ready <<<<<<
|
106
|
-
|
107
|
-
|
108
|
-
document.addEventListener("deviceready", function(){
|
109
|
-
|
110
|
-
|
111
|
-
const config_globalSettings = [
|
112
|
-
|
113
|
-
|
114
|
-
// DEPRECATED enableSameAppKey
|
115
|
-
setAppMuted = false, // Type Boolean default: false
|
116
|
-
setAppVolume = 1.0, // Type float default: 1
|
117
|
-
publisherFirstPartyIdEnabled = true, // Type Boolean default: true // enableSameAppKey
|
118
|
-
npa = "1", // string "0" | "1" // DEPRECATED Beginning January 16, 2024
|
119
|
-
enableCollapsible = true, // (BETA) activate the collapsible banner ads
|
120
|
-
responseInfo = false, // For debugging and logging purposes
|
121
|
-
|
122
|
-
]
|
123
|
-
|
124
|
-
cordova.plugins.emiAdmobPlugin.globalSettings(config_globalSettings);
|
125
|
-
|
126
|
-
|
127
|
-
// Must be under globalSetting and targeting
|
128
|
-
cordova.plugins.emiAdmobPlugin.initialize();
|
129
|
-
|
130
|
-
|
131
|
-
|
132
|
-
|
133
|
-
// SDK EVENT Initialization
|
134
|
-
// Optional
|
135
|
-
document.addEventListener('on.sdkInitialization', () => {
|
136
|
-
|
137
|
-
event.value += ("\n On Sdk Initialization");
|
138
|
-
|
139
|
-
});
|
140
|
-
|
141
|
-
|
142
|
-
|
143
|
-
|
144
|
-
document.addEventListener('on.banner.load', () => {
|
145
|
-
|
146
|
-
event.value += ("\n on.banner.load");
|
147
|
-
|
148
|
-
});
|
149
|
-
|
150
|
-
document.addEventListener('on.banner.failed.load', () => {
|
151
|
-
|
152
|
-
event.value += ("\n on.banner.failed.load");
|
153
|
-
|
154
|
-
});
|
155
|
-
|
156
|
-
document.addEventListener('on.banner.click', () => {
|
157
|
-
|
158
|
-
event.value += ("\n on.banner.click");
|
159
|
-
|
160
|
-
});
|
161
|
-
|
162
|
-
document.addEventListener('on.banner.close', () => {
|
163
|
-
|
164
|
-
event.value += ("\n on.banner.close");
|
165
|
-
|
166
|
-
});
|
167
|
-
|
168
|
-
document.addEventListener('on.banner.impression', () => {
|
169
|
-
|
170
|
-
event.value += ("\n on.banner.impression");
|
171
|
-
|
172
|
-
});
|
173
|
-
|
174
|
-
document.addEventListener('on.banner.open', () => {
|
175
|
-
|
176
|
-
event.value += ("\n on.banner.open");
|
177
|
-
|
178
|
-
});
|
179
|
-
|
180
|
-
document.addEventListener('on.banner.revenue', () => {
|
181
|
-
|
182
|
-
event.value += ("\n on.banner.revenue");
|
183
|
-
|
184
|
-
});
|
185
|
-
|
186
|
-
document.addEventListener('on.banner.remove', () => {
|
187
|
-
|
188
|
-
event.value += ("\n on.banner.remove");
|
189
|
-
|
190
|
-
});
|
191
|
-
|
192
|
-
|
193
|
-
|
194
|
-
}, false);
|
195
|
-
|
196
|
-
</script>
|
197
|
-
|
198
|
-
|
199
|
-
|
200
|
-
<p> <button onclick="loadBannerAd();">load Banner Ad</button></p>
|
201
|
-
<p> <button onclick="showBannerAd();">show Banner Ad</button></p>
|
202
|
-
<p> <button onclick="hideBannerAd();">hide Banner Ad</button></p>
|
203
|
-
<p> <button onclick="removeBannerAd();">remove Banner Ad</button></p>
|
204
|
-
<p> <button onclick="hideBannerAd();">hide Banner Ad</button></p>
|
205
|
-
|
206
|
-
|
207
|
-
|
208
|
-
<p> <button onclick="cleanText();">Clean response Text</button></p>
|
209
|
-
|
210
|
-
|
211
|
-
|
212
|
-
</body>
|
213
|
-
</html>
|
@@ -1,150 +0,0 @@
|
|
1
|
-
<html>
|
2
|
-
<head>
|
3
|
-
<script type="text/javascript" src="cordova.js"></script>
|
4
|
-
</head>
|
5
|
-
<body>
|
6
|
-
|
7
|
-
<label for="event">Debug Event All response :</label>
|
8
|
-
<textarea id="event" name="event" rows="5" cols="40"></textarea>
|
9
|
-
|
10
|
-
<script>
|
11
|
-
|
12
|
-
let event = document.getElementById('event');
|
13
|
-
|
14
|
-
let cleanText = () => { event.value = '' };
|
15
|
-
|
16
|
-
|
17
|
-
// WARNING config must be an array[] not an object{}
|
18
|
-
const config_Interstitial = [
|
19
|
-
|
20
|
-
adUnitId = "ca-app-pub-3940256099942544/1033173712",
|
21
|
-
autoShow = true
|
22
|
-
|
23
|
-
]
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
// Load Interstitial Ad
|
28
|
-
let loadInterstitialAd = () => {
|
29
|
-
cordova.plugins.emiAdmobPlugin.loadInterstitialAd(config_Interstitial);
|
30
|
-
// Or like this
|
31
|
-
// cordova.plugins.emiAdmobPlugin.loadInterstitialAd([adUnitId = "ca-app-pub-3940256099942544/1033173712", autoShow = false ]);
|
32
|
-
// call loadInterstitialAd();
|
33
|
-
}
|
34
|
-
|
35
|
-
// Show Interstitial Ad
|
36
|
-
let showInterstitialAd = () => {
|
37
|
-
cordova.plugins.emiAdmobPlugin.showInterstitialAd();
|
38
|
-
// call showInterstitialAd();
|
39
|
-
}
|
40
|
-
|
41
|
-
|
42
|
-
///// >>>>>> Device Ready <<<<<<
|
43
|
-
|
44
|
-
|
45
|
-
document.addEventListener("deviceready", function(){
|
46
|
-
// WARNING config must be an array[] not an object{}
|
47
|
-
const config_globalSettings = [
|
48
|
-
|
49
|
-
// DEPRECATED enableSameAppKey
|
50
|
-
setAppMuted = false, // Type Boolean default: false
|
51
|
-
setAppVolume = 1.0, // Type float default: 1
|
52
|
-
publisherFirstPartyIdEnabled = true, // Type Boolean default: true // enableSameAppKey
|
53
|
-
npa = "1", // string "0" | "1" // DEPRECATED Beginning January 16, 2024
|
54
|
-
enableCollapsible = true, // (BETA) activate the collapsible banner ads
|
55
|
-
responseInfo = false, // For debugging and logging purposes
|
56
|
-
|
57
|
-
]
|
58
|
-
|
59
|
-
cordova.plugins.emiAdmobPlugin.globalSettings(config_globalSettings);
|
60
|
-
|
61
|
-
|
62
|
-
// Must be under globalSetting and targeting
|
63
|
-
cordova.plugins.emiAdmobPlugin.initialize();
|
64
|
-
|
65
|
-
// SDK EVENT Initialization
|
66
|
-
|
67
|
-
document.addEventListener('on.sdkInitialization', () => {
|
68
|
-
|
69
|
-
event.value += ("\n On Sdk Initialization");
|
70
|
-
|
71
|
-
|
72
|
-
});
|
73
|
-
|
74
|
-
|
75
|
-
// interstitial Ad EVENT
|
76
|
-
|
77
|
-
/*
|
78
|
-
on.interstitial.loaded
|
79
|
-
on.interstitial.failed.load
|
80
|
-
on.interstitial.click
|
81
|
-
on.interstitial.dismissed
|
82
|
-
on.interstitial.failed.show
|
83
|
-
on.interstitial.impression
|
84
|
-
on.interstitial.show
|
85
|
-
on.interstitial.revenue
|
86
|
-
*/
|
87
|
-
|
88
|
-
|
89
|
-
document.addEventListener('on.interstitial.loaded', () => {
|
90
|
-
|
91
|
-
event.value += ("\n on.interstitial.loaded");
|
92
|
-
|
93
|
-
});
|
94
|
-
|
95
|
-
document.addEventListener('on.interstitial.failed.load', () => {
|
96
|
-
|
97
|
-
event.value += ("\n on.interstitial.failed.load");
|
98
|
-
|
99
|
-
});
|
100
|
-
|
101
|
-
document.addEventListener('on.interstitial.click', () => {
|
102
|
-
|
103
|
-
event.value += ("\n on.interstitial.click");
|
104
|
-
|
105
|
-
});
|
106
|
-
|
107
|
-
document.addEventListener('on.interstitial.dismissed', () => {
|
108
|
-
|
109
|
-
event.value += ("\n on.interstitial.dismissed");
|
110
|
-
|
111
|
-
});
|
112
|
-
|
113
|
-
document.addEventListener('on.interstitial.failed.show', () => {
|
114
|
-
|
115
|
-
event.value += ("\n on.interstitial.failed.show");
|
116
|
-
|
117
|
-
});
|
118
|
-
|
119
|
-
document.addEventListener('on.interstitial.impression', () => {
|
120
|
-
|
121
|
-
event.value += ("\n on.interstitial.impression");
|
122
|
-
|
123
|
-
});
|
124
|
-
|
125
|
-
document.addEventListener('on.interstitial.show', () => {
|
126
|
-
|
127
|
-
event.value += ("\n on.interstitial.show");
|
128
|
-
|
129
|
-
});
|
130
|
-
|
131
|
-
document.addEventListener('on.interstitial.revenue', () => {
|
132
|
-
|
133
|
-
event.value += ("\n on.interstitial.revenue");
|
134
|
-
|
135
|
-
});
|
136
|
-
|
137
|
-
|
138
|
-
}, false);
|
139
|
-
|
140
|
-
</script>
|
141
|
-
|
142
|
-
<p> <button onclick="loadInterstitialAd();">Load Interstitial Ad</button></p>
|
143
|
-
<p> <button onclick="showInterstitialAd();">Show Interstitial Ad</button></p>
|
144
|
-
|
145
|
-
|
146
|
-
<p> <button onclick="cleanText();">Clean response Text</button></p>
|
147
|
-
|
148
|
-
|
149
|
-
</body>
|
150
|
-
</html>
|
@@ -1,169 +0,0 @@
|
|
1
|
-
<html>
|
2
|
-
<head>
|
3
|
-
<script type="text/javascript" src="cordova.js"></script>
|
4
|
-
</head>
|
5
|
-
<body>
|
6
|
-
|
7
|
-
<label for="event">Debug Event All response :</label>
|
8
|
-
<textarea id="event" name="event" rows="5" cols="40"></textarea>
|
9
|
-
|
10
|
-
<script>
|
11
|
-
|
12
|
-
let event = document.getElementById('event');
|
13
|
-
|
14
|
-
let cleanText = () => { event.value = '' };
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
// WARNING config must be an array[] not an object{}
|
20
|
-
const config_rewarded = [
|
21
|
-
|
22
|
-
adUnitId = "ca-app-pub-3940256099942544/5224354917",
|
23
|
-
autoShow = true
|
24
|
-
|
25
|
-
]
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
// Load Rewarded Ad
|
30
|
-
let loadRewardedAd = () => {
|
31
|
-
cordova.plugins.emiAdmobPlugin.loadRewardedAd(config_rewarded);
|
32
|
-
// Or like this
|
33
|
-
// cordova.plugins.emiAdmobPlugin.loadRewardedAd([adUnitId = "ca-app-pub-3940256099942544/5224354917", autoShow = false ]);
|
34
|
-
// call loadRewardedAd();
|
35
|
-
}
|
36
|
-
|
37
|
-
// Show Rewarded Ad
|
38
|
-
let showRewardedAd = () => {
|
39
|
-
cordova.plugins.emiAdmobPlugin.showRewardedAd();
|
40
|
-
// call showRewardedAd();
|
41
|
-
}
|
42
|
-
|
43
|
-
|
44
|
-
///// >>>>>> Device Ready <<<<<<
|
45
|
-
|
46
|
-
|
47
|
-
document.addEventListener("deviceready", function(){
|
48
|
-
|
49
|
-
// WARNING config must be an array[] not an object{}
|
50
|
-
const config_globalSettings = [
|
51
|
-
|
52
|
-
// DEPRECATED enableSameAppKey
|
53
|
-
setAppMuted = false, // Type Boolean default: false
|
54
|
-
setAppVolume = 1.0, // Type float default: 1
|
55
|
-
publisherFirstPartyIdEnabled = true, // Type Boolean default: true // enableSameAppKey
|
56
|
-
npa = "1", // string "0" | "1" // DEPRECATED Beginning January 16, 2024
|
57
|
-
enableCollapsible = true, // (BETA) activate the collapsible banner ads
|
58
|
-
responseInfo = false, // For debugging and logging purposes
|
59
|
-
|
60
|
-
]
|
61
|
-
|
62
|
-
cordova.plugins.emiAdmobPlugin.globalSettings(config_globalSettings);
|
63
|
-
|
64
|
-
|
65
|
-
// Must be under globalSetting and targeting
|
66
|
-
cordova.plugins.emiAdmobPlugin.initialize();
|
67
|
-
|
68
|
-
// SDK EVENT Initialization
|
69
|
-
|
70
|
-
document.addEventListener('on.sdkInitialization', () => {
|
71
|
-
|
72
|
-
event.value += ("\n On Sdk Initialization");
|
73
|
-
|
74
|
-
|
75
|
-
});
|
76
|
-
|
77
|
-
|
78
|
-
// Rewarded Ad EVENT
|
79
|
-
|
80
|
-
/*
|
81
|
-
on.rewarded.loaded
|
82
|
-
on.rewarded.failed.load
|
83
|
-
on.rewarded.click
|
84
|
-
on.rewarded.dismissed
|
85
|
-
on.rewarded.failed.show
|
86
|
-
on.rewarded.impression
|
87
|
-
on.rewarded.show
|
88
|
-
on.rewarded.revenue
|
89
|
-
on.rewarded.ad.skip
|
90
|
-
on.reward.userEarnedReward
|
91
|
-
*/
|
92
|
-
|
93
|
-
|
94
|
-
document.addEventListener('on.rewarded.loaded', () => {
|
95
|
-
|
96
|
-
event.value += ("\n on.rewarded.loaded");
|
97
|
-
|
98
|
-
});
|
99
|
-
|
100
|
-
document.addEventListener('on.rewarded.failed.load', () => {
|
101
|
-
|
102
|
-
event.value += ("\n on.rewarded.failed.load");
|
103
|
-
|
104
|
-
});
|
105
|
-
|
106
|
-
document.addEventListener('on.rewarded.click', () => {
|
107
|
-
|
108
|
-
event.value += ("\n on.rewarded.click");
|
109
|
-
|
110
|
-
});
|
111
|
-
|
112
|
-
document.addEventListener('on.rewarded.dismissed', () => {
|
113
|
-
|
114
|
-
event.value += ("\n on.rewarded.dismissed");
|
115
|
-
|
116
|
-
});
|
117
|
-
|
118
|
-
document.addEventListener('on.rewarded.failed.show', () => {
|
119
|
-
|
120
|
-
event.value += ("\n on.rewarded.failed.show");
|
121
|
-
|
122
|
-
});
|
123
|
-
|
124
|
-
document.addEventListener('on.rewarded.impression', () => {
|
125
|
-
|
126
|
-
event.value += ("\n on.rewarded.impression");
|
127
|
-
|
128
|
-
});
|
129
|
-
|
130
|
-
document.addEventListener('on.rewarded.show', () => {
|
131
|
-
|
132
|
-
event.value += ("\n on.rewarded.show");
|
133
|
-
|
134
|
-
});
|
135
|
-
|
136
|
-
document.addEventListener('on.rewarded.revenue', () => {
|
137
|
-
|
138
|
-
event.value += ("\n on.rewarded.revenue");
|
139
|
-
|
140
|
-
});
|
141
|
-
|
142
|
-
document.addEventListener('on.rewarded.ad.skip', () => {
|
143
|
-
|
144
|
-
event.value += ("\n on.rewarded.ad.skip");
|
145
|
-
|
146
|
-
});
|
147
|
-
|
148
|
-
|
149
|
-
document.addEventListener('on.reward.userEarnedReward', () => {
|
150
|
-
|
151
|
-
event.value += ("\n on.reward.userEarnedReward");
|
152
|
-
|
153
|
-
});
|
154
|
-
|
155
|
-
|
156
|
-
|
157
|
-
}, false);
|
158
|
-
|
159
|
-
</script>
|
160
|
-
|
161
|
-
<p> <button onclick="loadRewardedAd();">Load Rewarded Ad</button></p>
|
162
|
-
<p> <button onclick="showRewardedAd();">Show Rewarded Ad</button></p>
|
163
|
-
|
164
|
-
|
165
|
-
<p> <button onclick="cleanText();">Clean response Text</button></p>
|
166
|
-
|
167
|
-
|
168
|
-
</body>
|
169
|
-
</html>
|