This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// SPDX-License-Identifier: UNLICENSED | |
pragma solidity 0.6.12; | |
pragma experimental ABIEncoderV2; | |
import {FlashLoanReceiverBase} from "@aave/protocol-v2/contracts/flashloan/base/FlashLoanReceiverBase.sol"; | |
import {SafeERC20} from "@aave/protocol-v2/contracts/dependencies/openzeppelin/contracts/SafeERC20.sol"; | |
import "@aave/protocol-v2/contracts/interfaces/ILendingPool.sol"; | |
import "@aave/protocol-v2/contracts/interfaces/ILendingPoolAddressesProvider.sol"; | |
import {IBentoBoxV1} from "@sushiswap/bentobox-sdk/contracts/IBentoBoxV1.sol"; | |
import {IERC20 as IBentoERC20} from "@boringcrypto/boring-solidity/contracts/interfaces/IERC20.sol"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$('.btn-pinterest').click(function() { | |
var url = $(this).attr('href'); | |
var media = $(this).attr('data-image'); | |
var desc = $(this).attr('data-desc'); | |
window.open( | |
"//www.pinterest.com/pin/create/button/"+ | |
"?url="+url+ | |
"&media="+media+ | |
"&description="+desc, | |
'popupwindow', |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<script type="text/javascript"> | |
(function(d){ | |
var f = d.getElementsByTagName('SCRIPT')[0], p = d.createElement('SCRIPT'); | |
p.type = 'text/javascript'; | |
p.async = true; | |
p.src = '//assets.pinterest.com/js/pinit.js'; | |
f.parentNode.insertBefore(p, f); | |
}(document)); | |
</script> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function gPlus(url){ | |
window.open( | |
'https://plus.google.com/share?url='+url, | |
'popupwindow', | |
'scrollbars=yes,width=800,height=400' | |
).focus(); | |
return false; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function postToFeed(title, desc, url, image) { | |
var obj = {method: 'feed', link: url, picture: image, name: title, description: desc}; | |
function callback(response){} | |
FB.ui(obj, callback); | |
} | |
$('.btn-facebook').click(function(e) { | |
var elem = $(this); | |
postToFeed(elem.data('title'), elem.data('desc'), elem.prop('href'), elem.data('image')); | |
return false; | |
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<div class="row shareContainer"> | |
<div class="col-sm-12"> | |
<h4>Share on social networks</h4> | |
<div class="col-xs-6 col-sm-6 col-md-3 col-lg-3 shareItem"> | |
<a href="https://url.to.share.com" data-image="https://full.path.to/image.png" data-title="title" data-desc="description" title="Share <title> on Facebook!" class="btn btn-sm btn-share btn-facebook"> | |
<span class="fa fa-facebook"></span> Facebook | |
</a> | |
</div> | |
<div class="col-xs-6 col-sm-6 col-md-3 col-lg-3 shareItem"> | |
<a href="https://twitter.com/intent/tweet?url=<url>;text=<text>;size=l&count=none" title="Share <title> on Twitter!" target="_blank" class="btn btn-sm btn-share btn-twitter"><span class="fa fa-twitter"></span> Twitter</a> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<script> | |
window.fbAsyncInit = function() { | |
FB.init({ | |
appId: 'your-fb-app-id', xfbml: true, version: 'v2.1' | |
}); | |
}; | |
(function(d, s, id){ | |
var js, fjs = d.getElementsByTagName(s)[0]; | |
if (d.getElementById(id)) {return;} | |
js = d.createElement(s); js.id = id; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
function get_html_contents($full_url) { | |
return str_get_html($full_url); // simplehtmldom's function | |
} | |
function get_full_result_block($html) { | |
return $html->find('div#center_col', 0); | |
} | |
function get_topstuff($whole_result) { |