I have created a simple API service for my login page which posts data to my API using cURL and that works but in my API index I keep getting an error:
undefined index username
<?php
  header('Content-Type: application/x-www-form-urlencoded');
  $username = $_GET['username'];
  $password = $_GET['password'];
but when i hard code it into the url http://www.example.com/LoginApi/index.php?username=gerald&password=4321 it works
