• 1

Read this first!

We do not monitor these forums. The forum is provided to exchange information and experience with other users ONLY. Forum responses are not guaranteed.

However, please submit a ticket if you have an active subscription and wish to receive support. Our ticketing system is the only way of getting in touch with RSJoomla! and receiving the official RSJoomla! Customer Support.

For more information, the Support Policy is located here.

Thank you!

TOPIC: Google maps api address field

Google maps api address field 9 years 1 week ago #30951

Hello,

Will I be able to add 'Google maps api address field' in the RSForm? This field will autocomplete the address.

Example source:
www.findsourcecode.com/google/how-to-mak...with-google-map-api/

Thanks
The administrator has disabled public write access.

Google maps api address field 9 years 1 week ago #30972

  • bogdan.tataru
  • bogdan.tataru's Avatar
  • OFFLINE
  • Gold Boarder
  • Posts: 174
  • Thank you received: 40
RSForm! PRO has already a Google Map Form Field which can be used in order to search for an adress. On Administration page go to Components >> RSForm! PRO >> Manage Forms and edit your form. Choose Google Map from left side and on the Attributes tab activate Geolocation search. This option will display an autocomplete address field on your form.
More on this here: www.rsjoomla.com/support/documentation/v.../908-google-map.html
My help is not official customer support. To receive assistance, submit a ticket by clicking here
The administrator has disabled public write access.

Google maps api address field 8 years 1 month ago #34329

Yes you can add an Autocomplete Address field set to an RSForm form.

There are a couple of steps:
1) get a maps API key from the Google developers console;
2) read this example and understand it - developers.google.com/maps/documentation...complete-addressform
3) Create a new form with a field called 'autocomplete' this just make the example from google work painlessly;
4) on the "Attributes" tab for the autocomplete field type onFocus="geolocate()"
5) Create 6 fields (name them as per the google example) to store the address components returned by the function google supplies on the javascript tag at the end of the link.
6) Paste the google javascript in the javascript section of the Form Properties>CSS and Javascript tab for the form.

then test, test, test and test some more - I just did the above and now will experiment with jazzing it up to behave properly.
for example:
a) Don't want to store the address data twice so the autocomplete field is not stored
b) the address component fields appear only after you accept the address in the autocomplete field

I am sure there is more and I will update this as I experiement
The administrator has disabled public write access.

Google maps api address field 7 years 8 months ago #35519

Any idea why it works on our dev server and not the live site? It is complaining about the Google Maps API key being non-existent but there is no place to put this key?
The administrator has disabled public write access.

Google maps api address field 7 years 8 months ago #35537

  • dragos
  • dragos's Avatar
  • OFFLINE
  • Administrator
  • Posts: 559
  • Thank you received: 102
Hello,

Google has changed how the Maps API functions and you'll be needing an API key:

developers.google.com/maps/pricing-and-p...ard-plan-2016-update

Though a configuration area on this matter will be included in the upcoming RSForm!Pro version, in the meanwhile, you can try these steps:

- locate and open the following file:

\administrator\components\com_rsform\helpers\fields\textbox.php

- search for:
$this->addCustomTag('<script src="https://maps.google.com/maps/api/js" type="text/javascript"></script>');

- change it into:
$this->addCustomTag('<script src="https://maps.google.com/maps/api/js?key=INSERT_KEY_HERE" type="text/javascript"></script>');

- notice INSERT_KEY_HERE, you'll have to replace it with your exact Google Maps API key (which you can generate via Google Developer Console).
Last Edit: 7 years 8 months ago by dragos.
The administrator has disabled public write access.
The following user(s) said Thank You: Roberts, pablo_lopez, p30yaran

Google maps api address field 7 years 2 months ago #36388

Hi there - can I ask if this functionality has been added to later versions of RSForms?

As of 1.5.24 I don't see anyway to add your API key to the map?

The documentation mentioned above makes no reference to the inclusion of an API key which now seems a mandatory requirement.

Thanks,
The administrator has disabled public write access.

Google maps api address field 7 years 2 months ago #36389

  • adrianp
  • adrianp's Avatar
  • OFFLINE
  • RSJoomla! Official Staff
  • Posts: 631
  • Thank you received: 146
Hello,

This has been added for a while now and you should be able to find it via backend > Components > RSForm!Pro > Configuration > Settings > "Google API Key".
This is not official customer support. To receive your support, submit a support ticket here.
The administrator has disabled public write access.
The following user(s) said Thank You: Martin.Beaumont

Google maps api address field 7 years 2 months ago #36390

Thanks I found this out about 5mins after the above post. Too late to stop the post heading in your direction.
The administrator has disabled public write access.

Google maps api address field 7 years 3 weeks ago #36679

  • Roberts
  • Roberts's Avatar
  • OFFLINE
  • Senior Boarder
  • Posts: 54
  • Thank you received: 1
Thanks for the info @ stephen.holland2

Got the API key installed okay and autocomplete returns the address but I am not sure what to name the 6 address fields which will be auto-filled. For example, should there be something in the Attributes boxes for these 6 fields?

I tried naming the fields according to the labels on Google's address block, to no avail.

I am creating text box fields, is that correct?
The administrator has disabled public write access.

Google maps api address field 7 years 3 weeks ago #36681

Use text fields and name them exactly the same as the example.
The administrator has disabled public write access.

Google maps api address field 7 years 3 weeks ago #36682

  • Roberts
  • Roberts's Avatar
  • OFFLINE
  • Senior Boarder
  • Posts: 54
  • Thank you received: 1
Just to confirm, that's -

Street address
City
State
Zip code
Country

5 text fields ?
Last Edit: 7 years 3 weeks ago by Roberts.
The administrator has disabled public write access.

Google maps api address field 6 years 6 months ago #37385

  • migors
  • migors's Avatar
  • OFFLINE
  • Fresh Boarder
  • Posts: 6
HI Roberts, have you managed to do this? Does it work?
The administrator has disabled public write access.

Google maps api address field 6 years 3 months ago #37757

On the topic of showing the rest of the form after autocomplete.

Just create a multipage (pagebrake) form and add the onFocus="geolocate()" on that too. (attributes Tab > Additional Attributes)
The form gets filled if the visitor clicks "next"
The administrator has disabled public write access.

Google maps api address field 6 years 1 month ago #38026

  • p30yaran
  • p30yaran's Avatar
  • OFFLINE
  • Fresh Boarder
  • Posts: 3
hello,
please help me to resolved problem
problem is :
I have enabled Google Map Search Address
How can I restrict search to a specific city? Example: California
thanks
The administrator has disabled public write access.
  • 1

Read this first!

We do not monitor these forums. The forum is provided to exchange information and experience with other users ONLY. Forum responses are not guaranteed.

However, please submit a ticket if you have an active subscription and wish to receive support. Our ticketing system is the only way of getting in touch with RSJoomla! and receiving the official RSJoomla! Customer Support.

For more information, the Support Policy is located here.

Thank you!