AJAX requests to sub-GET functions

Does requesting (per AJAX)

test.php?whattodo=delete
test.php?whattodo=download
test.php?whattodo=edit

Request 3 entirely new files, or is it cached somewhere for better use?

Does it go through test.php 3 same times and waste a lot of resources?
Or it reads it once and executes according to code, what whattodo is programmed to do.

This would really help me indicate progress to user. Could I use it? Or is it real harm towards server?

(I know how $_GET works, I just need to know whether I could use it in AJAX in order to process just a part)

All GET calls are cached for future use on the assumption that they don’t make changes to anything and therefore can return the same thing every time they are called.

If you want to make changes with a call you need to use POST.

This topic was automatically closed 91 days after the last reply. New replies are no longer allowed.