Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8863149
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 14, 20262026-06-14T15:54:16+00:00 2026-06-14T15:54:16+00:00

This is a random address I have found doesn’t work and yet the address

  • 0

This is a random address I have found doesn’t work and yet the address exists fine.

“Team Valley Trading Estate, Gateshead, Tyne and Wear NE92 1DG, UK”

Can you guys try geocoding that and tell me if it works for you, I have 13 addresses, 12 work, this 1 doesn’t?

This is the code I am running to make the geocode request:

class geocoder{
    static private $url = "http://maps.google.com/maps/api/geocode/json?sensor=true&address=";

    static public function getLocation($address){
        $url = self::$url.urlencode($address);

        $resp_json = self::curl_file_get_contents($url);
        $resp = json_decode($resp_json, true);

        if($resp['status']='OK'){
            return $resp['results'][0]['geometry']['location'];
        }else{
            return false;
        }
    }

    static private function curl_file_get_contents($URL){
        $c = curl_init();
        curl_setopt($c, CURLOPT_RETURNTRANSFER, 1);
        curl_setopt($c, CURLOPT_URL, $URL);
        $contents = curl_exec($c);
        curl_close($c);

        if ($contents) return $contents;
            else return FALSE;
    }
}    


$address = urlencode("Team Valley Trading Estate, Gateshead, Tyne and Wear NE92 1DG, UK");
$loc = geocoder::getLocation($address);

This is proof the address exists:
http://maps.google.co.uk/maps?q=%22Team+Valley+Trading+Estate,+Gateshead,+Tyne+and+Wear+NE92+1DG,+UK%22&hl=en&sll=53.103814,-2.278518&sspn=10.722701,33.815918&t=h&hnear=NE92+1DG,+United+Kingdom&z=16

This is proof that the geocoding class should be returning data:

http://maps.google.com/maps/api/geocode/json?sensor=true&address=Team%20Valley%20Trading%20Estate,%20Gateshead,%20Tyne%20and%20Wear%20NE92%201DG,%20UK

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-14T15:54:17+00:00Added an answer on June 14, 2026 at 3:54 pm

    you are urlencod‘ing the address twice so change:

    $address = urlencode("Team Valley Trading Estate, Gateshead, Tyne and Wear NE92 1DG, UK");
    

    to

    $address = "Team Valley Trading Estate, Gateshead, Tyne and Wear NE92 1DG, UK";
    

    as you have urlencod‘ed the address in your getLocation function

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I found this random page script which is in PHP file. I'm a bit
Hi I have this basic random quote script, but I would like it to
I have a string: 'This is some random text so you don't get upset
I have to parse this JSON in PHP so that for each address, I
i have this jQuery function: $(#text).load(test3.php?id=+ Math.random()); And this code is in page: user.php
I have a problem with this function public function getCoords($address){ $coordinatesSplit=array(0=>0,1=>0); $request_url = $this->_baseUrl
I would like to initialize boost::random::discrete_distribution with a double[] like this: boost::random::discrete_distribution<>* distribution(double* _distr)
I saw this in a random doxygen example for C#, and all attempts at
I'm using this to get random char from the string pool: $charset=str_shuffle('./ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789'); $charsetLength=strlen($charset)-1; $chosen=$charset[rand(0,$charsetLength)];
how does one use code to do this: produce 15 random numbers [EDIT: from

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.