acf-location-field
acf-location-field copied to clipboard
No Location displayed in field type After ACF-location-field-add-on is installed
Sorry for my ignorance I am new to this let me clear about myself
My ACF Version is 4.2.2
I installed Advanced Custom Fields - Location Field add-on and activated it In functions.php i included the file location-field.php like below
include_once( WP_PLUGIN_DIR . '/advanced-custom-fields-location-field-add-on/location-field.php' );
even tried below one also
include_once( rtrim( dirname( FILE ), '/' ) . '/advanced-custom-fields-location-field-add-on/location-field.php' );
Sorry I have changed acf-location-field to advanced-custom-fields-location-field-add-on which was given the site because i don't find such directory in plugin directory.
When i try to add New Field in Custom Fields i don't find any location field in the Drop down of Field Type*. like it has shown on website
but when i i try to add new field no Location in Field type
Do i need to make some changes or need to add any extra files to make the Location field appear in the dropdown of Field Type?
Please help me
Thanks in advance
I am also having this issue.
Me too, thinking it might be an update clash as I've had this one working fine previously?
Hi I spent quite a time also trying to figure out why the LOCATION field type wasn't showing on ACF field type dropbox. In the "acf-location" [readme.txt] file , if you choose the =include= method (insert the code your functions.php file), this is what they say:
1. Copy the 'acf-location' folder into your theme folder (can use sub folders)I found it quite confusing because actually they are calling the PLUGIN file in the include_once statement. For this example (depending of the ACF version you are using), they should write the following:
* You can place the folder anywhere inside the 'wp-content' directory
2. Edit your functions.php file and add the following code to include the field:
add_action('acf/register_fields', 'my_register_fields');
function my_register_fields()
{
include_once('acf-location/acf-location.php');
}
3. Make sure the path is correct to include the acf-location.php file
...
include_once('acf-location/location-v4.php');
OR
include_once('acf-location/location-v3.php');
These are the real field type files. In my case, it has solved the problem.
Very helpful! Thanks @funkyphenix