Skip to content

A simple PHP script with database backend to cache API responses.

License

Notifications You must be signed in to change notification settings

batnom/apicache

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 

Repository files navigation

apicache

A simple PHP script with database backend to cache API responses.

Notes

  • A simple PHP script with database backend to cache API responses
  • Slot in your own database handler

Usage

$data = GetDataCacheOrLive("URLHERE","1 HOUR"); // set cache time

$data = GetDataCacheOrLive("URLHERE"); // uses $default_cache

Database Structure

CREATE TABLE `data_dump` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`url` longtext NOT NULL,
`data` longtext NOT NULL,
`updated` datetime NOT NULL,
)

About

A simple PHP script with database backend to cache API responses.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages