0

I am using Google Maps for ExpressionEngine field type with Zoo Visitor update member entry form. But I couldn't make this field type as Required.

I tried by having "Is this a required field?" as "Yes" from field setting and/or validation rule rules:field_name="required" but no luck.

Could anyone please suggest how can I validate Google Map field.

Thanks,

0

Have you tried setting "minimum points" to something other than 0? You can find it in the field settings of your Google Maps channel field.

3
  • Thanks Isabel, I 'll try it but not sure if its related to validation Google Map filed as required. Jul 23 '14 at 8:26
  • In theory, if you instruct the fieldtype that the minimum number of points is 1 (or more), when you submit the channel form with 0 points it should give you an error, which should be the behavior you want to have when you set a field to required.
    – Isabel
    Jul 24 '14 at 10:59
  • It doesn't seem working. Jul 28 '14 at 19:58
0

I've been working on something very similar, but instead of using a map fieldtype I chose to just make the native EE grid custom field to hold the address. This way you can easily make the fields required. See example below.

{my_address}
    {my_address:street_address_1} 
    {my_address:street_address_2} 
    {my_address:city} 
    {my_address:state} 
    {my_address:zip}
{/my_address}

I'm using Zoo Visitor, but for maps I'm using Gmaps. In my template I can use this information within the gmaps tag to bring in the address. I'm sure that Google Maps for ExpressionEngine has a similar tag.

Cheers! jules

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.