Giter Site home page Giter Site logo

simple-php-api-for-android-and-ios-'s Introduction

simple-php-api-for-android-and-ios

method is post

database Minium must like this table user (password,key) //user table must require 'user_id' and 'key' Fild. Other table dosent matters.

#1.type = login

var string type = login;

var where = where; // for datafild name such like username, email or mobile, it will replace where;

var username = username; // it will filter from datafild name given

var password = password; //Password

The query will like

SELECT * FROM user WHERE <where> LIKE '' AND password LIKE ''

On Success it will return JSON string

{['error' => 0, 'result' => ['id' => '1', 'key' => 'key3k4ji45kj3hi4yhrf90']]} on error it will return JSON

{['error' => 1, 'result' => 0]}

#2.type = GET

var string type = GET;

var key = key; // Key form login function;

var sql = Query; // A valide SQL query.

On Success it will return JSON string

{['error' => 0, 'result' => 'JSON STRING OF DATA'} on error it will return JSON

{['error' => 1, 'result' => 'Mysql Error']}

#3.type = SET

var string type = SET;

var key = key; // Key form login function;

var sql = Query; // A valide SQL query.

On Success it will return JSON string

{['error' => 0, 'result' => 'success'} on error it will return JSON

{['error' => 1, 'result' => 'Mysql Error']}

#4. type = upload

var string type = uplead;

var key = key; // Key form login function;

var path= path; // folder name where file will store such as userid or username.

var file= file; // File to Upload.

On Success it will return JSON string

{['error' => 0, 'result' => 'file link'} on error it will return JSON

{['error' => 1, 'result' => 'Error To Upload File']}

#5. type = delete

var string type = uplead;

var key = key; // Key form login function;

var path= path; //Link Of file which to be deleted

.

On Success it will return JSON string

{['error' => 0, 'result' => 'Deleted'} on error it will return JSON

{['error' => 1, 'result' => 'Error To Delete File']}

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.