//clever script to uncover the browser
function getBrowser()
{
$u_agent = $_SERVER['HTTP_USER_AGENT'];
$bname = 'Unknown';
$platform = 'Unknown';
$version= "";
//First get the platform?
if (preg_match('/linux/i', $u_agent)) {
$platform = 'linux';
}
elseif (preg_match('/macintosh|mac os x/i', $u_agent)) {
$platform = 'mac';
}
elseif (preg_match('/windows|win32/i', $u_agent)) {
$platform = 'windows';
}
// Next get the name of the useragent yes seperately and for good reason
if(preg_match('/MSIE/i',$u_agent) && !preg_match('/Opera/i',$u_agent))
{
$bname = 'Internet Explorer';
$ub = "MSIE";
}
elseif(preg_match('/Firefox/i',$u_agent))
{
$bname = 'Mozilla Firefox';
$ub = "Firefox";
}
elseif(preg_match('/OPR/i',$u_agent))
{
$bname = 'Opera';
$ub = "Opera";
}
elseif(preg_match('/Chrome/i',$u_agent))
{
$bname = 'Google Chrome';
$ub = "Chrome";
}
elseif(preg_match('/Safari/i',$u_agent))
{
$bname = 'Apple Safari';
$ub = "Safari";
}
elseif(preg_match('/Netscape/i',$u_agent))
{
$bname = 'Netscape';
$ub = "Netscape";
}
//steve add 2021 to set value if blank
if (!isset($ub) || $ub == ""){$ub = "unknown"; }
// finally get the correct version number
$known = array('Version', $ub, 'other');
$pattern = '#(?' . join('|', $known) .
')[/ ]+(?[0-9.|a-zA-Z.]*)#';
if (!preg_match_all($pattern, $u_agent, $matches)) {
// we have no matching number just continue
}
// see how many we have
$i = count($matches['browser']);
if ($i != 1) {
//we will have two since we are not using 'other' argument yet
//see if version is before or after the name
if (strripos($u_agent,"Version") < strripos($u_agent,$ub)){
$version= $matches['version'][0];
}
else {
$version= $matches['version'][1];
}
}
else {
$version= $matches['version'][0];
}
// check if we have a number
if ($version==null || $version=="") {$version="?";}
return array(
'userAgent' => $u_agent,
'name' => $bname,
'version' => $version,
'platform' => $platform,
'pattern' => $pattern
);
}
// now try it
$ua=getBrowser();
$yourbrowser= "Your browser: " . $ua['name'] . " " . $ua['version'] . " on " .$ua['platform'] . " reports: " . $ua['userAgent'];
$browser_name = $ua['name'] ;
$browser_version =$ua['version'] ;
$computer_system =$ua['platform'] ;
$user_agent = $ua['userAgent'];
//echo $browser_name."+".$browser_version."+".$computer_system."+".$user_agent;
//print_r($yourbrowser);
//STEVE you are limited to 120 geo lookups per minute. This stops bots from counting for geo location
function is_bot($user_agent) {
$botRegexPattern = "(googlebot\/|Googlebot\-Mobile|Googlebot\-Image|Google favicon|Mediapartners\-Google|bingbot|slurp|java|wget|curl|Commons\-HttpClient|Python\-urllib|libwww|httpunit|nutch|phpcrawl|msnbot|jyxobot|FAST\-WebCrawler|FAST Enterprise Crawler|biglotron|teoma|convera|seekbot|gigablast|exabot|ngbot|ia_archiver|GingerCrawler|webmon |httrack|webcrawler|grub\.org|UsineNouvelleCrawler|antibot|netresearchserver|speedy|fluffy|bibnum\.bnf|findlink|msrbot|panscient|yacybot|AISearchBot|IOI|ips\-agent|tagoobot|MJ12bot|dotbot|woriobot|yanga|buzzbot|mlbot|yandexbot|purebot|Linguee Bot|Voyager|CyberPatrol|voilabot|baiduspider|citeseerxbot|spbot|twengabot|postrank|turnitinbot|scribdbot|page2rss|sitebot|linkdex|Adidxbot|blekkobot|ezooms|dotbot|Mail\.RU_Bot|discobot|heritrix|findthatfile|europarchive\.org|NerdByNature\.Bot|sistrix crawler|ahrefsbot|Aboundex|domaincrawler|wbsearchbot|summify|ccbot|edisterbot|seznambot|ec2linkfinder|gslfbot|aihitbot|intelium_bot|facebookexternalhit|yeti|RetrevoPageAnalyzer|lb\-spider|sogou|lssbot|careerbot|wotbox|wocbot|ichiro|DuckDuckBot|lssrocketcrawler|drupact|webcompanycrawler|acoonbot|openindexspider|gnam gnam spider|web\-archive\-net\.com\.bot|backlinkcrawler|coccoc|integromedb|content crawler spider|toplistbot|seokicks\-robot|it2media\-domain\-crawler|ip\-web\-crawler\.com|siteexplorer\.info|elisabot|proximic|changedetection|blexbot|arabot|WeSEE:Search|niki\-bot|CrystalSemanticsBot|rogerbot|360Spider|psbot|InterfaxScanBot|Lipperhey SEO Service|CC Metadata Scaper|g00g1e\.net|GrapeshotCrawler|urlappendbot|brainobot|fr\-crawler|binlar|SimpleCrawler|Livelapbot|Twitterbot|cXensebot|smtbot|bnf\.fr_bot|A6\-Indexer|ADmantX|Facebot|Twitterbot|OrangeBot|memorybot|AdvBot|MegaIndex|SemanticScholarBot|ltx71|nerdybot|xovibot|BUbiNG|Qwantify|archive\.org_bot|Applebot|TweetmemeBot|crawler4j|findxbot|SemrushBot|yoozBot|lipperhey|y!j\-asr|Domain Re\-Animator Bot|AddThis)";
return preg_match("/{$botRegexPattern}/", $user_agent);
}
//if it's a bot then label it
if ( is_bot($_SERVER['HTTP_USER_AGENT']) ) {
$BotAlert = "Bot [".$user_agent."]"; }else{ $BotAlert = "Not Bot]"; }
if ( !is_bot($_SERVER['HTTP_USER_AGENT']) ) {
//STEVE genius code to get the address of a site visitor and their geo location geolocation
function ip_info($ip = NULL, $purpose = "location", $deep_detect = TRUE) {
$output = NULL;
if (filter_var($ip, FILTER_VALIDATE_IP) === FALSE) {
$ip = $_SERVER["REMOTE_ADDR"];
if ($deep_detect) {
if (filter_var(@$_SERVER['HTTP_X_FORWARDED_FOR'], FILTER_VALIDATE_IP))
$ip = $_SERVER['HTTP_X_FORWARDED_FOR'];
if (filter_var(@$_SERVER['HTTP_CLIENT_IP'], FILTER_VALIDATE_IP))
$ip = $_SERVER['HTTP_CLIENT_IP'];
}
}
$purpose = str_replace(array("name", "\n", "\t", " ", "-", "_"), NULL, strtolower(trim($purpose)));
$support = array("country", "countrycode", "state", "region", "city", "location", "address");
$continents = array(
"AF" => "Africa",
"AN" => "Antarctica",
"AS" => "Asia",
"EU" => "Europe",
"OC" => "Australia (Oceania)",
"NA" => "North America",
"SA" => "South America"
);
if (filter_var($ip, FILTER_VALIDATE_IP) && in_array($purpose, $support)) {
$ipdat = @json_decode(file_get_contents("http://www.geoplugin.net/json.gp?ip=" . $ip));
if (@strlen(trim($ipdat->geoplugin_countryCode)) == 2) {
switch ($purpose) {
case "location":
$output = array(
"city" => @$ipdat->geoplugin_city,
"state" => @$ipdat->geoplugin_regionName,
"country" => @$ipdat->geoplugin_countryName,
"country_code" => @$ipdat->geoplugin_countryCode,
"continent" => @$continents[strtoupper($ipdat->geoplugin_continentCode)],
"continent_code" => @$ipdat->geoplugin_continentCode
);
break;
case "address":
$address = array($ipdat->geoplugin_countryName);
if (@strlen($ipdat->geoplugin_regionName) >= 1)
$address[] = $ipdat->geoplugin_regionName;
if (@strlen($ipdat->geoplugin_city) >= 1)
$address[] = $ipdat->geoplugin_city;
$output = implode(", ", array_reverse($address));
break;
case "city":
$output = @$ipdat->geoplugin_city;
break;
case "state":
$output = @$ipdat->geoplugin_regionName;
break;
case "region":
$output = @$ipdat->geoplugin_regionName;
break;
case "country":
$output = @$ipdat->geoplugin_countryName;
break;
case "countrycode":
$output = @$ipdat->geoplugin_countryCode;
break;
}
}
}
return $output;
}
//echo ip_info("Visitor", "Country"); // India
//echo ip_info("Visitor", "Country Code"); // IN
//echo ip_info("Visitor", "State"); // Andhra Pradesh
//echo ip_info("Visitor", "City"); // Proddatur
//echo ip_info("Visitor", "Address"); // Proddatur, Andhra Pradesh, India
$country_code = ip_info("Visitor", "Country Code");
$state = ip_info("Visitor", "State");
$city = ip_info("Visitor", "City"); // Proddatur
$origincountry = ip_info("Visitor", "Country");
$geolocation = ip_info("Visitor", "Address");
//print_r(ip_info("Visitor", "Location")); // Array ( [city] => Proddatur [state] => Andhra Pradesh [country] => India [country_code] => IN [continent] => Asia [continent_code] => AS )
}
//end geo bot check
if (isSet($_SERVER)) {
if (isSet($_SERVER["HTTP_X_FORWARDED_FOR"])) {
$ipaddress = $_SERVER["HTTP_X_FORWARDED_FOR"];
} elseif (isSet($_SERVER["HTTP_CLIENT_IP"])) {
$ipaddress = $_SERVER["HTTP_CLIENT_IP"];
} else {
$ipaddress = $_SERVER["REMOTE_ADDR"];
}
} else {
if ( getenv( 'HTTP_X_FORWARDED_FOR' ) ) {
$ipaddress = getenv( 'HTTP_X_FORWARDED_FOR' );
} elseif ( getenv( 'HTTP_CLIENT_IP' ) ) {
$ipaddress = getenv( 'HTTP_CLIENT_IP' );
} else {
$ipaddress = getenv( 'REMOTE_ADDR' );
}
}
// if ($ipaddress =="178.2.22.196")
//test for my ip if ($ipaddress =="68.192.223.134")
//{
//echo("
Du gehst mir voll auf den Sack!
die Drecksau!
");
//COOKIE HANDLER - CHECK IF RETURN VISITOR!
if (isset($_COOKIE["SPVisitor"])) {
//auto refresh to human view
//header("location: http://www.shurikenproductions.com?human=VIP");
//exit;
$returnVisitor = "Return Site Visitor";
$vCOOKIE = $_COOKIE["SPVisitor"];
//echo "on".$vCOOKIE;
$boundaryid = uniqid("msg_id_");
} else {
$vCOOKIE = "";
$boundaryid = uniqid("msg_id_");
$returnVisitor = "New Site Visitor";
setcookie("SPVisitor",$boundaryid."-".$ipaddress, time()+60*60*24*30*6);
}
//Test to see if human or robot. If Human, will click View Site button and usually allow cookie. Robots wont.
if (isset($vCOOKIE)) {
//echo $_POST['view'];
$humanview = "human";
} else {
$humanview = "robot";
}
//if they havent pressed enter but they have a cookie as a return visitor, send to main page
if (isset($_COOKIE["SPVisitor"])) {
$vCOOKIE = $_COOKIE["SPVisitor"];
//header("location: http://www.shurikenproductions.com?s=$vCOOKIE");
}
//check if from FACEBOOK
if (isset($_GET["fbclid"])) {
$FBCOOKIE = $_GET["fbclid"];
$FBHIT = "Fakebook Hit";
//?fbclid=;
}else{$FBCOOKIE = "";
$FBHIT = "Organic";}
$strMsg = "ShurikenProductions.com got a ".$humanview." ".$FBHIT." - ".$returnVisitor." site hit!
Hello and thank you for visiting my site. Can I help you with something specific?
EMAIL ME
No thanks, I want to continue browsing...
X
Hi! Glad you like my content. Text or call me at (508) 534-8722 for more information on my Real Property Media services.
CLOSE
VIEW PRICES
Privacy
Policy
We
created this privacy policy to demonstrate
our firm commitment to
the protection of your information.
How
we protect your privacy We use security measures to protect against the loss, misuse and alteration
of data used by our system.
Sharing
and Usage We will never share, sell, or rent individual
personal information with anyone without
your advance permission or unless ordered
by a court of law. Information submitted
to us is only available to employees managing
this information for purposes of contacting
you or sending you emails based on your request
for information.
Did you receive an email from us? If you received a mailing from us, (a) your email address is either listed
with us as someone who has expressly shared this address for the purpose of receiving
information in the future ("opt-in"), or (b) you have requested more
information from us, are an authorized affiliate of our client or otherwise
have an existing relationship with us.
We make every effort to respect your time and attention by
controlling the frequency of our mailings.
How
can you stop receiving email from us? Each email sent contains an easy, automated way for you to cease receiving email from us, or to change your expressed interests. If you wish to do this, simply follow the instructions at the end of any email.
If you have received unwanted, unsolicited
email sent via this system or purporting to
be sent via this system, please forward a copy
of that email with your comments to support
@ shurikenproductions . com for
review.
Privacy
Policy Changes This policy was updated on April 2,
2021.