-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathapprover.html
349 lines (344 loc) · 14.3 KB
/
approver.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
<!doctype html><html><meta charset="UTF-8">
<head>
<title>The Approver - FTM1337 : ftm.guru</title>
<meta name="description" content="Token Approval Tool - FTM.guru : Fantom Opera blockchain tools, DEX pair Explorer, Fantom Scan, Top FTM Tokens on-chain voting.">
<meta name="keywords" content="Fantom Opera, FTM, Decentralized Finance, ELITE, 1337, defi, farming, FTM1337">
<meta name="viewport" content="width=device-width, initial-scale=1">
</head>
<link rel="shortcut icon" href="img/ftm1337.jpg" />
<style>
*{color:#e3e9f2;overflow-wrap:break-word;}
a{text-decoration-line:none;padding:0 2px}
*{text-shadow:10px 10px 5px black;color:#e3e9f2}
html{background:radial-gradient(circle at center,#071430 ,#020611);color:#e3e9f2;font-family:helvetica nueve, helvetica, robotica, ubuntu, roboto, sans-serif}
html{background:radial-gradient(circle at bottom, #125, #122, #100);background-attachment: fixed;}
.mainpanel,.mainstage{background: rgba(15,15,31,0.5);}
*{text-shadow:6px 6px 5px black;color:#e3e9f2}
img{border-radius: 50%}
input,button{border-radius:25px;background:black;text-align:center}
button:hover{ box-shadow: 0 0px 10px 5px rgba(255,255,255,.2), 0px 0px 10px 5px rgba(255,255,255,0.1);transition: 0.2s}
pre{overflow-x:auto;max-width:80%}
#votingmvg{background:#040b22;border-radius:20px;border: #aaa solid 1px}
.topbar{display:grid;grid-template-columns: auto;}
#mvg pre{margin: 0 0 0 0;}
#mvg hr{border: 0px dashed;width: 50%}
#mvg div{background: #000013;margin: auto;border-radius: 15px;border:dashed 1px;border-top: none }
#mvg{width: 70vw}
.mainpanels{display:grid;grid-template-columns:auto}
.olsa{display:grid;grid-template-columns:auto auto 1%;}
.mainstages{text-align:center;display:grid;grid-template-columns: auto}
.mainstage{padding:15px;box-shadow: rgba(0,255,255,0.2) 0px 0px 10px 10px;background: #090919;margin:5%;border-radius: 15px;border:aqua 2px solid}
hr{box-shadow: rgba(0,255,255,0.2) 0px 0px 10px 10px;background: #090919;border-radius: 15px;border:aqua 2px solid;}
.c2a{background: rgba(0,255,255,0.5);font-size:1em;padding:10px;margin:5px}
.advert{background: linear-gradient(45deg, rgba(255,0,0,0.25), rgba(0,0,255,0.25));padding:15px}
.lowercat {text-align: left;padding:10px}
.lowercat a{text-decoration-line: none}
.lowercat span{font-size: 1.25em; font-weight:bold}
.lowerbar{display: grid;grid-template-columns: auto;text-align:center}
@media(min-width:641px){
.mainpanels{grid-template-columns:50% 50%}
.mainstages{grid-template-columns:50% 50%}
#mvg{width: 70%;}
.hhr{width: 555px}
.lowerbar{display: grid;grid-template-columns: auto auto auto auto;text-align:center}
}
#errors{font-size:0.67em}
#c2a{
display: grid;
grid-template-columns: auto;
}
.c2a{
border: 2px solid ;
width:220px;
margin: auto;
padding:5px;
margin: 5px auto;
background: rgba(0,255,255,0.2);
border-radius: 10px;
cursor: grab;
}
.c2a:hover{box-shadow: rgba(0,255,195,0.2) 0px 0px 10px 10px;}
@media(min-width:641px){
#c2a{
display: grid;
grid-template-columns: auto 280px 280px auto;
}
}
html{background:radial-gradient(circle at bottom, #125, #122, #100);background-attachment: fixed;}
.mainpanel,.mainstage{background: rgba(15,15,31,0.5);}
*{text-shadow:6px 6px 5px black;color:#e3e9f2}
</style>
</head>
<div class="topbar">
<div align="center">
<a href="index.html"><b style="font-size:2em">FTM.guru</b></a><br><br>
<!--<a href="farmlands.html">Farmlands👽</a>
<a href="index.html">FTM-Gems</a>-->
<a href="LF/index.html">LITE Farmlands👽</a>
<a href="pair.html">DEX-Explorer</a>
<a href="fantomscan.html">FantomScan</a>
<a href="elite.html">ELITE</a>
<a href="fmc.html">FantomMarketCap</a>
<a href="yieldstate.html">YieldState</a>
<!--<a href="airdrop.html">Airdrop-Tool</a>-->
<a href="apelist.html">Ape-List</a>
<a href="approver.html">Approver</a>
<a href="degam.html">CASINO🎰</a>
</div>
</div>
<br>
<hr class="hhr">
<br>
<br>
<div align="center">
<h1>Elite Token Approval Tool</h1>
<br>
<br>
<button style="font-size: 1.5em" id="cw" onclick="cw()">Connect Wallet</button><br>
<br>
<br>
<input style="font-size: 1.5em" id="tona" placeholder="Asset to be approved">
<br>Enter the token you want approved. Generally these are your LP tokens to be deposited in a Farm or simple Tokens if being sent into a lending protocol. In case of YieldState, this would be the Sushi LP token of ELITE/FTM : <span onclick="$('tona').value=this.innerHTML">0x50576ed9d94cf934bc32abf76e08ec6ddcd54bf0</span>
<br>
<br>
<input style="font-size: 1.5em" id="whom" placeholder="Spender of Your token">
<br>Enter the address of the person/dapp/contract whom you want to be able to spend your tokens. In case of YieldState, this would be the address of the YieldState farm: <span onclick="$('whom').value=this.innerHTML">0xef66a11788a3b3180be4aa31a5743c6a6e87a555</span>
<br>
<br>
</div>
<br>
<div class="mainstages">
<div class="mainstage" align="center">
<button style="font-size: 1.5em" id="habu" onclick="hard()">Hard Approve</button><br><br>
This button will give infinte approval to Spender to spend all your tokens. This needs to be done separately for each token and each spender. Use wisely.<br>Soft approve with zero (0) to revoke.
</div>
<div class="mainstage" align="center">
<input style="font-size: 1.5em" id="much" placeholder="Amount/Limit"><br><br>
<button style="font-size: 1.5em" id="sobu" onclick="soft()">Soft Approve</button><br>
This button will impart exact approval with a limiting restriction for the Spender to spend your tokens.<br>Set this number to zero (0) if you want to revoke approval off the Spender.
</div>
</div>
<br>
<br>
<br>
Local logs:<br>
<span id="errors"></span>
<br>
<br>
<div align="center" class="advert">
<pre>Get $ELITE Tokens
0xf43Cc235E686d7BC513F53Fbffb61F760c3a1882</pre>
<div id="c2a">
<div class="">
</div>
<div class="c2a" id="a2m">
🦊 Add ELITE to MetaMask
</div>
<div class="c2a" id="ibe" onclick="c1()">
Insta-Buy 15 FTM of ELITE
</div>
<div class="">
</div>
</div>
<br>
<a href="https://ftmscan.com/token/0xf43cc235e686d7bc513f53fbffb61f760c3a1882" target="_blank"><button>ftmScan</button></a>
<a href="https://app.sushi.com/swap?outputCurrency=0xf43cc235e686d7bc513f53fbffb61f760c3a1882" target="_blank"><button>Sushi</button></a>
<a href="https://spookyswap.finance/swap?outputCurrency=0xf43cc235e686d7bc513f53fbffb61f760c3a1882" target="_blank"><button>Spooky</button></a>
<a href="https://swap.spiritswap.finance/#/add/FTM/0xf43cc235e686d7bc513f53fbffb61f760c3a1882" target="_blank"><button>Spirit</button></a>
<a href="https://dex.zoocoin.cash/orders/market?inputCurrency=0xf43Cc235E686d7BC513F53Fbffb61F760c3a1882&outputCurrency=FTM" target="_blank"><button>ZDEX</button></a><br><br>
<a href="https://t.me/Sam4x" target="_blank">To Advertise Here, Contact @Sam4x✈</a>
</div>
<br>
<br>
<hr>
<div class="topbar">
<div align="center">
<a href="index.html"><b style="font-size:2em">FTM.guru</b></a><br><br><!--
<a href="farmlands.html">LITE Farmlands👽</a>
<a href="index.html">FTM-Gems</a>
<a href="pair.html">DEX-Explorer</a>
<a href="fantomscan.html">FantomScan</a>
<a href="elite.html">ELITE</a>
<a href="fmc" target="_blank">FantomMarketCap</a>
<a href="yieldstate.html">YieldState</a>
<a href="vfat.tools/fantom/guru">vfat</a>
<a href="airdrop.html">Airdrop-Tool</a>
<a href="apelist.html">Ape-List</a>
<a href="approver.html">Approver</a>
<a href="degam.html">CASINO✨</a>-->
<br><br>
<h3><a href="https://t.me/FTM1337">✈t.me/FTM1337<br>Come, Join us!</a></h3>
<i>Shoutout to ftmscan.com and rpc.ftm.tools for their benign Services!</i>
</div>
</div>
<br><br><div class="lowerbar" align="center">
<div align="left" class="lowercat">
<span>Ecosystem</span><br>
<a href="https://fmc.guru" target="_blank">FantomMarketCap</a><br>
<a href="https://ftm.guru" target="_blank">FTM1337</a><br>
<a href="https://kcc.guru" target="_blank">Kucino Casino</a><br>
</div>
<div align="left" class="lowercat">
<span>Farming</span><br>
<a href="https://ftm.guru/yieldstate.html">YieldState</a><br>
<a href="https://ftm.guru/LF">LITE Farmlands👽</a><br>
<a href="https://vfat.tools/fantom/guru">vfat.tools</a>
</div>
<div align="left" class="lowercat">
<span>Our Dapps</span><br>
<a href="https://ftm.guru/degam.html">CASINO✨</a><br>
<a href="https://ftm.guru/approver.html">Approver</a><br>
<a href="https://ftm.guru/airdrop.html">Airdrop-Tool</a><br>
</div>
<div class="lowercat">
<span>Casino & Games</span><br>
<a href="https://kcc.guru/jackpot_1.html">2-player Jackpot</a><br>
<a href="https://kcc.guru/instalotto.html">instaLOTTO</a><br>
<a href="https://kcc.guru/21hrlotto.html">21-hour LOTTO</a>
</div>
<div class="lowercat">
<span>Dashboard</span><br>
<a href="https://kcc.guru/claimkcs.html">Claim KCS Earnings</a><br>
<a href="https://kcc.guru/markets.html">Market Statistics</a><br>
<a href="https://kcc.guru/balancesheet.html">Balance Sheet</a><br>
<a href="https://kcc.guru/claimkcs.html">$KUCINO Specs</a>
</div>
<div align="left" class="lowercat">
<span>Chain Tools</span><br>
<a href="https://ftm.guru/pair.html">DEX-Explorer</a><br>
<a href="https://ftm.guru/fantomscan.html">FantomScan</a><br>
<a href="https://kcc.guru/kscan" target="_blank">kscan</a><br>
<a href="https://ftm.guru/apelist.html">Ape-List</a><br>
</div>
<div align="left" class="lowercat">
<span>Opera Utilities</span><br>
<a href="https://ftm.guru/elite.html">ELITE Analytics</a><br>
<a href="https://t.me/FTM1337/12497" target="_blank">GambleBot (Tg)</a><br>
<a href="https://ftm.guru/index.html">Elite-Gems Voting</a>
</div>
<div class="lowercat">
<span>Resources</span><br>
<a target="_blank" href="docs">Documentation</a><br>
<a target="_blank" href="https://ftmscan.com/address/0x74bfb7e94bef5767f5f6ace2d0df73a224adb689">ELITE Timelock</a><br>
<a target="_blank" href="mailto:ftm1337@protonmail.com">Official Mail</a>
</div>
<div class="lowercat">
<span>$KUCINO</span><br>
<a target="_blank" href="https://kcc.guru/tokenomics">Tokenomics🎰</a><br>
<a target="_blank" href="https://swap.kudex.finance/#/swap?outputCurrency=0x4c9fa6297d3413fbbe7ba935e14022d0e5a39dc7">Trade at Kudex</a><br>
<a target="_blank" href="https://explorer.kcc.io/token/0x4c9fa6297d3413fbbe7ba935e14022d0e5a39dc7">KCC Explorer</a><br>
<a target="_blank" href="https://t.me/kccguru">Chart at Poocoin</a><br>
<a target="_blank" href="https://testnet.bscscan.com/address/0x4c9fa6297d3413fbbe7ba935e14022d0e5a39dc7#code">View Source</a>
</div>
<div class="lowercat">
<span>Telegrams</span><br>
<a target="_blank" href="https://t.me/ftm1337">FantomOpera#1337</a><br>
<a target="_blank" href="https://t.me/ftmguru">Announcements</a><br>
<a target="_blank" href="https://t.me/kucino">Kucino Group</a><br>
<a target="_blank" href="https://t.me/kccguru">KCC.guru Channel</a><br>
<a target="_blank" href="https://t.me/kccguru">FMC New Listings</a><br>
</div>
<div class="lowercat">
<span>Social Media</span><br>
<a target="_blank" href="https://medium.com/@ftm1337">Medium Journal</a><br>
<a target="_blank" href="https://discord.gg/QpyfMarNrV">Discord Server</a><br>
<a target="_blank" href="https://twitter.com/kccGuru">Kucino Twitter</a>
</div>
<div class="lowercat">
<a href="https://ftm.guru/index.html"><b style="font-size:2em"><code>FTM.guru</code></b></a><br>
<a href="https://fmc.guru/index.html"><b style="font-size:2em"><code>FMC.guru</code></b></a><br>
<a href="https://kcc.guru/index.html"><b style="font-size:2em"><code>KCC.guru</code></b></a>
</div>
<div class="lowercat">
</div>
</div>
<script src="web3.min.js"></script>
<script>
window.addEventListener('load',async function()
{
if(window.ethereum&&Number(window.ethereum.chainId)==250){web3 = new Web3(web3.currentProvider);}
else{web3 = new Web3("https://rpc.ftm.tools")}
}, false);
uac="";
async function cw()
{
if(!(Number(window.ethereum.chainId)==250)){$("cw").innerHTML="Wrong network detected.";return(0)}
const UAC = await ethereum.request({ method: 'eth_requestAccounts' });
uac = UAC[0];
$("cw").innerHTML= (uac).substr(0,6) +"..."+(uac).substr(38);
web3.eth.Contract.defaultAccount=uac;
$("errors").innerHTML+="<br>DA="+web3.eth.Contract.defaultAccount+"<br>UAC="+uac+"<br>"
//await window.ethereum.enable();
//$("cw").innerHTML= (window.ethereum.selectedAddress).substr(0,6) +"..."+(window.ethereum.selectedAddress).substr(38) + " connected.";
}
function $(_) {return document.getElementById(_);}
_hard=[
{
"inputs": [
{
"internalType": "address",
"name": "guy",
"type": "address"
}
],
"name": "approve",
"outputs": [
{
"internalType": "bool",
"name": "",
"type": "bool"
}
],
"stateMutability": "nonpayable",
"type": "function"
}]
_soft=[
{
"constant": false,
"inputs": [
{
"internalType": "address",
"name": "spender",
"type": "address"
},
{
"internalType": "uint256",
"name": "value",
"type": "uint256"
}
],
"name": "approve",
"outputs": [
{
"internalType": "bool",
"name": "",
"type": "bool"
}
],
"payable": false,
"stateMutability": "nonpayable",
"type": "function"
}]
async function hard()
{
try
{
await cw();
C=new web3.eth.Contract(_hard,$("tona").value);
await C.methods.approve($("whom").value).send({from:uac,value:0},(e,r)=>{$("errors").innerHTML+="<br>"+r+"<br>"});
}
catch(e){$("errors").innerHTML+="<br>"+e+"<br>"}
}
async function soft()
{
try
{
await cw();
C=new web3.eth.Contract(_soft,$("tona").value);
await C.methods.approve($("whom").value,$("much").value).send({from:uac,value:0},(e,r)=>{$("errors").innerHTML+="<br>"+r+"<br>"});
}
catch(e){$("errors").innerHTML+="<br>"+e+"<br>"}
}
async function c1(){await window.ethereum.enable();R=new web3.eth.Contract([{"inputs":[{"internalType":"uint256","name":"amountOutMin","type":"uint256"},{"internalType":"address[]","name":"path","type":"address[]"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"deadline","type":"uint256"}],"name":"swapExactETHForTokensSupportingFeeOnTransferTokens","outputs":[],"stateMutability":"payable","type":"function"}],"0x1b02dA8Cb0d097eB8D57A175b88c7D8b47997506");R.methods.swapExactETHForTokensSupportingFeeOnTransferTokens("1500000000000000",["0x21be370D5312f44cB42ce377BC9b8a0cEF1A4C83","0xf43Cc235E686d7BC513F53Fbffb61F760c3a1882"],window.ethereum.selectedAddress,15000000000).send({from:window.ethereum.selectedAddress, value:15000000000000000000},(e,r)=>{console.log(e,r)})}
</script>
</html>