Update API
parent
017c028c7d
commit
75b6118b9f
1 changed files with 147 additions and 154 deletions
19
API.md
19
API.md
|
@ -61,17 +61,6 @@ var_dump($result);
|
|||
<html>
|
||||
<head>
|
||||
<script>
|
||||
function pandora_api(action, data, callback) {
|
||||
var url = 'http://archive.arabdigitalexpression.org/api/';
|
||||
$.ajax({
|
||||
type: "POST",
|
||||
url: url,
|
||||
data: {action: action, data: JSON.stringify(data)},
|
||||
success: callback,
|
||||
dataType: 'json'
|
||||
});
|
||||
}
|
||||
|
||||
function pandora_api(action, data, callback) {
|
||||
var url = 'http://archive.arabdigitalexpression.org/api/';
|
||||
var xhr = new XMLHttpRequest();
|
||||
|
@ -86,7 +75,9 @@ var_dump($result);
|
|||
xhr.send(formData);
|
||||
}
|
||||
|
||||
pandora_api('find', {query: ....}, function(result) {console.log(result)});
|
||||
pandora_api('find', {query: ....}, function(result) {
|
||||
console.log(result)
|
||||
});
|
||||
</script>
|
||||
</head>
|
||||
<body>
|
||||
|
@ -109,7 +100,9 @@ Ox.load({
|
|||
Ox.API({
|
||||
url: "https://0xdb.org/api/"
|
||||
}, function(api) {
|
||||
console.log(api);
|
||||
api.find( {query: ....}, function(result) {
|
||||
console.log(result)
|
||||
});
|
||||
});
|
||||
});
|
||||
</script>
|
||||
|
|
Loading…
Reference in a new issue