Home  >  Article  >  Backend Development  >  ajax2—solve cache problems—php (28), ajax2 cache_PHP tutorial

ajax2—solve cache problems—php (28), ajax2 cache_PHP tutorial

WBOY
WBOYOriginal
2016-07-13 09:53:21729browse

ajax2—solve caching problem—php (28), ajax2 cache

5. ajax quick start

ajax code:

ajax2—solve cache problems—php (28), ajax2 cache_PHP tutorialPhp program:

ajax2—solve cache problems—php (28), ajax2 cache_PHP tutorialPhp code:

ajax2—solve cache problems—php (28), ajax2 cache_PHP tutorialajax calculates the sum of two numbers

ajax2—solve cache problems—php (28), ajax2 cache_PHP tutorial7. Solving cache problems

Questions above:

Change addition in php to subtraction

If the previous request parameter is used, it is still found to be addition. If it is a new request parameter, it is subtraction.

Solution 1: Random number

Math.random();

ajax2—solve cache problems—php (28), ajax2 cache_PHP tutorialSolution 3. Set request header

setRequestHeader("If-Modified-Since","0");

ajax2—solve cache problems—php (28), ajax2 cache_PHP tutorialSolution4. Set response header

header("Cache-Control: no-cache, must-revalidate");

ajax2—solve cache problems—php (28), ajax2 cache_PHP tutorial

www.bkjia.comtruehttp: //www.bkjia.com/PHPjc/1001468.htmlTechArticleajax2—solve the cache problem—php (28), ajax2 cache 5. ajax quick start ajax code: Php program: Php code: ajax calculates the sum of two numbers 7. Solving the cache problem The above problems...
Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn