首页 商标信息 商标信息示例代码 商标详情[PHP]

商标详情示例代码[PHP]

作者: 阅读数:1382 上传时间:2018-08-13

商标详情

<?php

require_once 'curl.func.php';

$appkey = 'your_appkey_here';
$regno = '4952050';
$classid = '42';
$url = "https://api.jisuapi.com/trademark/detail?appkey=$appkey®no=$regno&classid=$classid";

$result = curlOpen($url, ['ssl'=>true]);
$jsonarr = json_decode($result, true);
//exit(var_dump($jsonarr));

if($jsonarr['status'] != 0)
{
    echo $jsonarr['msg'];
    exit();
}

$result = $jsonarr['result'];
echo $result['regno'].' '.$result['classid'].' '.$result['appdate'].' '.$result['firsttrialno'].' '.$result['firsttrialdate'].' '.$result['announceno'].' '.$result['announcedate'].' '.$result['startdate'].' '.$result['enddate'].' '.$result['iscommon'].' '.$result['type'].' '.$result['pic'].' '.$result['agent'].' '.$result['status'].' '.$result['name'].' '.$result['registrant'].' '.$result['idcard'].' '.$result['address'].'
'; foreach ($result['productlist'] as $val){ echo $val['classid'].' '.$val['name'].'
'; } foreach ($result['processlist'] as $val){ echo $val['name'].' '.$val['date'].'
'; }