Jump to content

Urlencode Help


savagenoob

Recommended Posts

I have an address in a variable, I pass this address to a google maps page/function that geocodes it and returns the street view.

Heres an example of a link:

<a href="mapget.php?address=<?php echo urlencode(strip_tags($comaddress));?>" name="mapit">Map It</a>

 

The address' come from either a curl or dom request so I have been trying to strip and trim them as much as possible but the urls come out looking like...

 

www.mysite.com/mapget.php?address=7855+N+SOMESTREET+AVE+SOMECITY++++++++++++++++++++++%2C+CA+11111

My maps only seem to be getting the street... I am using urldecode($address) on the receiving page and when I echo $address on the receiving page it looks completely correct.

Any ideas?

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

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.   Restore formatting

  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...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.