api-postcode/api-postcode-bundle 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

api-postcode/api-postcode-bundle

最新稳定版本:1.0.7

Composer 安装命令:

composer require api-postcode/api-postcode-bundle

包简介

Symfony Api Postcode bundle

README 文档

README

This bundle can be useed to fetch Address details from zipcode with number.

See: https://api-postcode.nl for more information.

Installation

Installation is a quick 3 step process:

  1. Download api-postcode-bundle using composer
  2. Enable the Bundle in AppKernel.php
  3. Configure Api Postcode credentials

Step 1: Download postcode-bundle using composer

Add ApiPostcodeBundle by running the command:

$ composer require api-postcode/api-postcode-bundle

Step 2: Enable the Bundle in AppKernel.php

<?php
// app/AppKernel.php

public function registerBundles()
{
    $bundles = array(
        // ...
        new ApiPostcode\PostcodeBundle\ApiPostcodeBundle(),
    );
}

Step 3: Configure Api Postcode credentials

# app/config/config.yml

# Api Postcode Token
api_postcode:
    token: secret-token

Usage Services

$address = $this->get('api.postcode')->fetchAddress('1012JS', 1);
	
$address->getStreet();      // Dam
$address->getCity();        // Amsterdam
$address->getHouseNumber(); // 1
$address->getZipCode();     // 1012JS
$address->getLongitude();   // 4.4584
$address->getLatitude();    // 52.2296

Usage from API

Or try the API response:

http://127.0.0.1:8000/api/postcode?postcode=2011WD&nummer=2

统计信息

  • 总下载量: 3.66k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 1
  • 点击次数: 0
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 1
  • Watchers: 0
  • Forks: 3
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2017-06-05

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固