will a script in html's script tag with extension php be cached?
Some browsers are more agressive with default caching than others. However, there are cache control headers you can send to indicate when to reload the code.
Is a code-snippet I've been known to use.
You can use more fancy stuff like If-Not-Modified headers and ETags, but Expire times are the only ones that eliminate extra server calls.