Bạn đang truy cập vào hệ thống Cache

Xem demo tại Tài khoản TEST ại đây
<?php
include_once "cacheSDK.php";
$cache = cacheSDK(["api_key"=>"Test"]);
$cache->upload($file);
$cache->delete($file);
//
$cache->profile();
?> 

Bạn có thể dùng GET

<?php
$apikey = "TEST";
$domain = $_SERVER['HTTP_HOST'];
$url = "https://{$domain}/tmp/test.jpg";
$res =  json_decode(file_get_contents("https://cache.donggiatri.com/post.php?domain={$domain}&api_key={$apikey}&url=".rawurlencode($url)));
print_r($res);
?> 
Bạn phải nhúng cnd <script src="https://cache.donggiatri.com/sdk.js"></script>
Media
<script> 
var cache = cacheSDK.init({"api_key":"Test"});
cache.upload(file).then(function(res){

});
 

cache.delete(file).then(function(res){

});
 
var imgurl = cache.file("image.jpg",{fired:1000});

</script>  
              
Profile
<script> 
var cache = cacheSDK.init({"api_key":"Test"});
 
cache.profile().then(function(res){

});
</script>  
              
Model
<script> 
var cache = cacheSDK.init({"api_key":"Test"});
 
var model = cache.model(tablename);
///////////////////////CRUD/////////////////
model.create({}).then(function(res){

});

model.delete({}).then(function(res){

});

model.modify({}).then(function(res){

});

///////////////////////END CRUD/////////////////
//filter by key and value and pagation
model.filter({}).then(function(res){

});

//list and pagation
model.get({}).then(function(res){

});

//list by date and pagation
model.date("2026-12-21").then(function(res){

});

//search
model.search("").then(function(res){

});
</script>  
              
Bạn có thể dùng UI Picker
<script> 
var cache = cacheSDK.init({"api_key":"Test"}); 
cache.picker().then(function(res){

});
 
</script>