Welcome to Questionaries, where you can ask questions and receive answers from other members of the community.

Let us know at info@questionaries.org

GEOIP Script Help.

7 like 0 dislike
Hey, I got this error;
=======================
Parse error: syntax error, unexpected T_CLASS in /home/c*****pt/public_html/Domain/ccr.php on line
========================
Code:
==========================
<?php
    // ccr.php - country code redirect
    require_once(’/geo/geoplugin.class.php’);
    $geoplugin = new geoPlugin();
    $geoplugin->locate();
    $country_code = $geoplugin->countryCode;
    switch($country_code) {
    case ‘US’:
    header(’Location: http://www.yourdomain.com/usoffer.php’);
    exit;
    case ‘CA’:
    header(’Location: http://www.yourdomain.com/caoffer.php’);
    exit;
    case ‘GB’:
    header(’Location: http://www.yourdomain.com/gboffer.php’);
    exit;
    case ‘IE’:
    header(’Location: http://www.yourdomain.com/irelandoffer.php’);
    exit;
    case ‘AU’:
    header(’Location: http://www.yourdomain.com/australiaoffer.php’);
    exit;
    case ‘NZ’:
    header(’Location: http://www.yourdomain.com/newzealandoffer.php’);
    exit;
    default: // exceptions
    header(’Location: http://www.yourdomain.com/allelseoffer.php’);
    exit;
    }
    ?>
=====================================
I have the geoplugin.class.php in the geo folder and I keep getting the same error.

Any help?
asked 2 years ago by eagle09 (95,490 points)

Your answer

Email me at this address if my answer is selected or commented on:
Privacy: Your email address will only be used for sending these notifications.

0 Answers

Related questions

10 like 0 dislike
0 answers
11 like 0 dislike
1 answer
asked 2 years ago by eagle09 (95,490 points)
7 like 0 dislike
3 answers
asked 2 years ago by eagle09 (95,490 points)
7 like 0 dislike
1 answer
asked 2 years ago by eagle09 (95,490 points)
7 like 0 dislike
0 answers
asked 2 years ago by eagle09 (95,490 points)