Jump to content
gloryous666

Caut programator php

Recommended Posts

Posted

Am nevoie de un programator PHP care imi poate face un sistem functionand in felul urmator: Exista un cod html care apare doar la anumite tari (gen US,UK) iar la celelalte nu apare nimic in acel loc, e ca si cum n-ar exista nimic.

 

Contact Y!M: gloryous2013

Posted
<?php
$ip = $_SERVER['REMOTE_ADDR']; 
$query = @unserialize(file_get_contents('http://ip-api.com/php/'.$ip));
if($query['regionName'] == 'England') {
echo ' <b>you are from England</b> ';
} else {
echo '<b>you are from somewhere else</b>';
}
?>

Se poate dezvolta foarte usor..

  • Upvote 2
Posted
48 minutes ago, Church said:

<?php
$ip = $_SERVER['REMOTE_ADDR']; 
$query = @unserialize(file_get_contents('http://ip-api.com/php/'.$ip));
if($query['regionName'] == 'England') {
echo ' <b>you are from England</b> ';
} else {
echo '<b>you are from somewhere else</b>';
}
?>

Se poate dezvolta foarte usor..

Am adaugat Romania in loc de England si scrie "you are from somewhere else".....

Posted

 

<?php
$ip = $_SERVER['REMOTE_ADDR']; 
$query = @unserialize(file_get_contents('http://ip-api.com/php/'.$ip));
if($query['country'] == 'Romania') {
echo ' <b>you are from England</b> ';
} else {
echo '<b>you are from somewhere else</b>';
}
?>

 

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.



×
×
  • Create New...