Skip to content

Instantly share code, notes, and snippets.

@yoshifuji
Created August 21, 2017 06:22
Show Gist options
  • Save yoshifuji/11945bba9f92b119d7f7ad2f49c61d29 to your computer and use it in GitHub Desktop.
Save yoshifuji/11945bba9f92b119d7f7ad2f49c61d29 to your computer and use it in GitHub Desktop.
<?php
date_default_timezone_set('Asia/Tokyo');
$loginId = isset($_POST['loginId']) ? htmlspecialchars($_POST["loginId"], ENT_QUOTES) : null;
$password = isset($_POST['password']) ? htmlspecialchars($_POST["password"], ENT_QUOTES) : null;
$memberId = "000001";
//Auth logic
//JSON dataset
$json_array = array(
'memberId' => $memberId,
);
header("Content-Type: application/json; charset=utf-8");
echo json_encode($json_array);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment