{"id":30228523,"url":"https://github.com/studioespresso/craft-easyaddressfield","last_synced_at":"2025-08-14T19:55:02.860Z","repository":{"id":57060597,"uuid":"112918744","full_name":"studioespresso/craft-easyaddressfield","owner":"studioespresso","description":"Easy Address Field is the easiest way to add an address to your entries.  Enable the fields you want for the address, automatically get the coordinates for an address and place the marker exactly where you want it.  ","archived":false,"fork":false,"pushed_at":"2025-05-04T12:14:40.000Z","size":1478,"stargazers_count":3,"open_issues_count":0,"forks_count":3,"subscribers_count":3,"default_branch":"develop-v5","last_synced_at":"2025-05-04T13:23:41.069Z","etag":null,"topics":["craft-plugin","craftcms"],"latest_commit_sha":null,"homepage":"https://plugins.craftcms.com/easy-address-field","language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/studioespresso.png","metadata":{"files":{"readme":"README.MD","changelog":"CHANGELOG.MD","contributing":null,"funding":null,"license":"LICENSE.MD","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2017-12-03T10:31:04.000Z","updated_at":"2025-05-04T12:14:21.000Z","dependencies_parsed_at":"2023-12-20T13:05:22.607Z","dependency_job_id":"fda89aa5-76dd-4c30-91c0-4111e79c6716","html_url":"https://github.com/studioespresso/craft-easyaddressfield","commit_stats":{"total_commits":206,"total_committers":5,"mean_commits":41.2,"dds":0.2912621359223301,"last_synced_commit":"211797885a7a3037673fb77aac4b3a7097bd0d52"},"previous_names":["studioespresso/craft-easyaddressfield","studioespresso/craft3-easyaddressfield"],"tags_count":48,"template":false,"template_full_name":null,"purl":"pkg:github/studioespresso/craft-easyaddressfield","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/studioespresso%2Fcraft-easyaddressfield","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/studioespresso%2Fcraft-easyaddressfield/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/studioespresso%2Fcraft-easyaddressfield/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/studioespresso%2Fcraft-easyaddressfield/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/studioespresso","download_url":"https://codeload.github.com/studioespresso/craft-easyaddressfield/tar.gz/refs/heads/develop-v5","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/studioespresso%2Fcraft-easyaddressfield/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":270475433,"owners_count":24590076,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-08-14T02:00:10.309Z","response_time":75,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["craft-plugin","craftcms"],"created_at":"2025-08-14T19:55:01.453Z","updated_at":"2025-08-14T19:55:02.836Z","avatar_url":"https://github.com/studioespresso.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Easy Address Field plugin for Craft CMS 3.x\n\n![Easy Address Field](https://www.studioespresso.co/assets/Easy-Address-Field-Github-Banner.png)\n\n\nThe only address field you need\n\n## Requirements\n\nThis plugin requires Craft CMS 3.0.0-RC1 or later.\n\n## Installation\n\nTo install the plugin, follow these instructions.\n\n1. Open your terminal and go to your Craft project:\n\n        cd /path/to/project\n\n2. Then tell Composer to load the plugin:\n\n        composer require studioespresso/craft-easyaddressfield\n\n3. In the Control Panel, go to Settings → Plugins and click the “Install” button for \"Easy Address Field\".\n\n## Settings\n\nYou can choose which geocoding API the plugin will use when you have geocoding enabled for your fields.\nOptions are:\n- OpenStreetMap's Nominatim (default, no configuration, but very strict rate limits)\n- Google Maps (requires an API key, see below)\n\n### Google Maps API\nTo enable geolocating and custom marker placement, you need to provide a Google Maps API key.\n1) Sign in to [Google's developers console](http://console.developers.google.com/)\n2) Create a new project\n3) Enable the `Google Maps Geocoding API` and the `Google Static Maps API`\n\n**🚨 Important 🚨:**\n\nGoogle's Geocoding API does not support HTTP referrer restrictions. Make sure the API key you are using does not have these set.\n\n#### API Errors\nWhen `devMode` is enabled, any errors returned by Google's API will show an exception so you can clearly see what's going wrong. With `devMode` disabled, any errors will be logged to Craft's `web.log`.\n\n\n### GeoCoding for Craft Address elements\nSince Craft 5, Craft has a built-in element for Addresses, but no way to get coordinates for addresses out of the box.\nWhen you install Easy Address Field, you can enable GeoCoding for Craft Address elements.  This will add a `latitude` and `longitude` values to each Address element.\nYou can enable this feature in the plugin settings.\n\n## Template variables\n\n### Printing address values\nYou can access the values from your address field in Twig through the following variables:\n````twig\nfield.name\nfield.street\nfield.street2\nfield.postalCode\nfield.state\nfield.country // returns the country code\nfield.getCountryName(craft.app.locale) // returns the coutry's full name, in the country's locale\nfield.latitude\nfield.longitude\nfield.getDirectionsUrl() // get a directions link to the given address\n````\n\n\n## Custom GeoCoding services\nOut of the box, the plugin comes with support for geocoding with OpenStreetMap's Nominatim service and Google.\nIf you'd like to use a different service, you can create a custom service by creating a new class that implements the `studioespresso\\easyaddressfield\\services\\geocoders\\BaseGeoCoder` interface.\n\nOnce you created your geocoder, register it with the following event:\n\n````php\nuse studioespresso\\easyaddressfield\\events\\RegisterGeocoderEvent;\nuse studioespresso\\easyaddressfield\\services\\GeoLocationService;\n\nEvent::on(\n   GeoLocationService::class, \n   GeoLocationService::EVENT_REGISTER_GEOCODERS, \n   function (RegisterGeocoderEvent $event) {\n       $event-\u003egeoCoders['your-service'] = YourGeoCoder::class;\n});\n````\n\n## Upgrading from Craft 4 to Craft 5\n### getDirectionsUrl()\nIf you're using the ``getDirectionsUrl()`` function on `craft.address`, you'll now need to call the function on the field itself instead of the on the plugin's Twig variable.\n\n### getStaticMap() \u0026 getStaticMapRaw()\nThese functions have been removed from the plugin, you'll need to replace these yourself.\n\n---\n\n###### Brought to you by [Studio Espresso](https://studioespresso.co)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstudioespresso%2Fcraft-easyaddressfield","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fstudioespresso%2Fcraft-easyaddressfield","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstudioespresso%2Fcraft-easyaddressfield/lists"}