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
var useragent = navigator.userAgent; | |
useragent = useragent.toLowerCase(); | |
if (useragent.indexOf('iphone') != -1 || useragent.indexOf('symbianos') != -1 || useragent.indexOf('ipad') != -1 || useragent.indexOf('ipod') != -1 || useragent.indexOf('android') != -1 || useragent.indexOf('blackberry') != -1 || useragent.indexOf('samsung') != -1 || useragent.indexOf('nokia') != -1 || useragent.indexOf('windows ce') != -1 || useragent.indexOf('sonyericsson') != -1 || useragent.indexOf('webos') != -1 || useragent.indexOf('wap') != -1 || useragent.indexOf('motor') != -1 || useragent.indexOf('symbian') != -1 ) { | |
document.location = "http://www.fabioandrezo.com.br/portfolio-assinaturas-visuais-mobile.html"; | |
} |
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 | |
if (!current_user_can('manage_options')) { | |
add_filter('show_admin_bar', '__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
if(location.href!=parent.location) { | |
alert("tá dentro do iframe") | |
} else { | |
alert("tá fora do iframe") | |
} |
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
<link rel="apple-touch-icon-precomposed" href="images/apple-touch-icon.png"> | |
<link rel="apple-touch-icon-precomposed" sizes="72x72" href="images/apple-touch-icon-72x72.png"> | |
<link rel="apple-touch-icon-precomposed" sizes="114x114" href="images/apple-touch-icon-114x114.png"> |
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 checkCard(num){ | |
var msg = Array(); | |
var tipo = null; | |
if(num.length > 16 || num[0]==0){ | |
msg.push("Número de cartão inválido"); | |
} else { | |
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 cleanInput($input) { | |
$search = array( | |
'@<script[^>]*?>.*?</script>@si', // Strip out javascript | |
'@<[\/\!]*?[^<>]*?>@si', // Strip out HTML tags | |
'@<style[^>]*?>.*?</style>@siU', // Strip style tags properly | |
'@<![\s\S]*?--[ \t\n\r]*>@' // Strip multi-line comments | |
); |
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 getDistanceBetweenPointsNew($latitude1, $longitude1, $latitude2, $longitude2) { | |
$theta = $longitude1 - $longitude2; | |
$miles = (sin(deg2rad($latitude1)) * sin(deg2rad($latitude2))) + (cos(deg2rad($latitude1)) * cos(deg2rad($latitude2)) * cos(deg2rad($theta))); | |
$miles = acos($miles); | |
$miles = rad2deg($miles); | |
$miles = $miles * 60 * 1.1515; | |
$feet = $miles * 5280; | |
$yards = $feet / 3; |
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 getTweets($hash_tag) { | |
$url = 'http://search.twitter.com/search.atom?q='.urlencode($hash_tag) ; | |
echo "<p>Connecting to <strong>$url</strong> ...</p>"; | |
$ch = curl_init($url); | |
curl_setopt ($ch, CURLOPT_RETURNTRANSFER, TRUE); | |
$xml = curl_exec ($ch); | |
curl_close ($ch); |
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="example-class<?php echo ($xyz++%2); ?>"> |
OlderNewer