risan/ktp 问题修复 & 功能扩展

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

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

risan/ktp

Composer 安装命令:

composer require risan/ktp

包简介

HTTP client library for finding 2014 Indonesian presidential election voter's data based on it's NIK

README 文档

README

Build Status HHVM Status StyleCI Scrutinizer Code Quality Code Coverage SensioLabs Insight Latest Stable Version License

PHP HTTP client library for finding 2014 Indonesian presidential election voter's data based on it's NIK. The data is directly scraped from KPU website website.

Table of Contents

Dependencies

This package powered by the following awesome libraries:

Installation

The recommended way to install this package is through Composer. With the Composer installed on your machine, simply run the following command inside your project directory:

composer require risan/ktp

You may also add risan\ktp package directly into your composer.json file:

"require": {
  "risan/ktp": "~1.1"
}

Once your composer.json file is updated, run the following command to install it:

composer install

How to Use

Here's some example about how to use this package:

// Include composer autoloder file.
require 'vendor/autoload.php';

// Create a new instance Ktp\Finder.
$ktp = new Ktp\Finder();

// Find a voter's data by it's NIK.
$data = $ktp->findByNik(1122330108901234);

// Voter's data is not found.
if (is_null($data)) {
    die('Not found!');
}

print_r($data);

If the given NIK is not found, the findByNik() method will return a null value.

If the given NIK is found, the findByNik() will return an array that holds the voter's data. The returned array will have the following structure:

Array
(
    [nik] => 1122330108901234
    [name] => RISAN BAGJA
    [jenis_kelamin] => LAKI-LAKI
    [kelurahan] => KAMPUNG BARU
    [kecamatan] => BANDA
    [kabupaten_kota] => MALUKU TENGAH
    [provinsi] => MALUKU UTARA
)

统计信息

  • 总下载量: 44
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 2
  • 点击次数: 6
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 2
  • Watchers: 1
  • Forks: 1
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2016-03-03

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固